How to use the clifford.get_mult_function function in clifford

To help you get started, we’ve selected a few clifford examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pygae / clifford / clifford / _layout.py View on Github external
self.linear_map_to_bitmap[linear] = int(bitmap)

        self.gmt, imt_prod_mask, omt_prod_mask, lcmt_prod_mask = construct_tables(
            np.array(self.gradeList),
            self.linear_map_to_bitmap,
            self.bitmap_to_linear_map,
            self.sig
        )
        self.omt = sparse.where(omt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.imt = sparse.where(imt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.lcmt = sparse.where(lcmt_prod_mask, self.gmt, self.gmt.dtype.type(0))

        # This generates the functions that will perform the various products
        self.gmt_func = get_mult_function(self.gmt, self.gradeList)
        self.imt_func = get_mult_function(self.imt, self.gradeList)
        self.omt_func = get_mult_function(self.omt, self.gradeList)
        self.lcmt_func = get_mult_function(self.lcmt, self.gradeList)
        self.inv_func = get_leftLaInv(self.gmt, self.gradeList)

        # these are probably not useful, but someone might want them
        self.imt_prod_mask = imt_prod_mask
        self.omt_prod_mask = omt_prod_mask
        self.lcmt_prod_mask = lcmt_prod_mask
github pygae / clifford / clifford / _layout.py View on Github external
self.gmt, imt_prod_mask, omt_prod_mask, lcmt_prod_mask = construct_tables(
            np.array(self.gradeList),
            self.linear_map_to_bitmap,
            self.bitmap_to_linear_map,
            self.sig
        )
        self.omt = sparse.where(omt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.imt = sparse.where(imt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.lcmt = sparse.where(lcmt_prod_mask, self.gmt, self.gmt.dtype.type(0))

        # This generates the functions that will perform the various products
        self.gmt_func = get_mult_function(self.gmt, self.gradeList)
        self.imt_func = get_mult_function(self.imt, self.gradeList)
        self.omt_func = get_mult_function(self.omt, self.gradeList)
        self.lcmt_func = get_mult_function(self.lcmt, self.gradeList)
        self.inv_func = get_leftLaInv(self.gmt, self.gradeList)

        # these are probably not useful, but someone might want them
        self.imt_prod_mask = imt_prod_mask
        self.omt_prod_mask = omt_prod_mask
        self.lcmt_prod_mask = lcmt_prod_mask
github pygae / clifford / clifford / _layout.py View on Github external
for bitmap, linear in enumerate(self.bitmap_to_linear_map):
            self.linear_map_to_bitmap[linear] = int(bitmap)

        self.gmt, imt_prod_mask, omt_prod_mask, lcmt_prod_mask = construct_tables(
            np.array(self.gradeList),
            self.linear_map_to_bitmap,
            self.bitmap_to_linear_map,
            self.sig
        )
        self.omt = sparse.where(omt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.imt = sparse.where(imt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.lcmt = sparse.where(lcmt_prod_mask, self.gmt, self.gmt.dtype.type(0))

        # This generates the functions that will perform the various products
        self.gmt_func = get_mult_function(self.gmt, self.gradeList)
        self.imt_func = get_mult_function(self.imt, self.gradeList)
        self.omt_func = get_mult_function(self.omt, self.gradeList)
        self.lcmt_func = get_mult_function(self.lcmt, self.gradeList)
        self.inv_func = get_leftLaInv(self.gmt, self.gradeList)

        # these are probably not useful, but someone might want them
        self.imt_prod_mask = imt_prod_mask
        self.omt_prod_mask = omt_prod_mask
        self.lcmt_prod_mask = lcmt_prod_mask
github pygae / clifford / clifford / _layout.py View on Github external
self.linear_map_to_bitmap = np.zeros(len(self.bladeTupMap), dtype=int)
        for bitmap, linear in enumerate(self.bitmap_to_linear_map):
            self.linear_map_to_bitmap[linear] = int(bitmap)

        self.gmt, imt_prod_mask, omt_prod_mask, lcmt_prod_mask = construct_tables(
            np.array(self.gradeList),
            self.linear_map_to_bitmap,
            self.bitmap_to_linear_map,
            self.sig
        )
        self.omt = sparse.where(omt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.imt = sparse.where(imt_prod_mask, self.gmt, self.gmt.dtype.type(0))
        self.lcmt = sparse.where(lcmt_prod_mask, self.gmt, self.gmt.dtype.type(0))

        # This generates the functions that will perform the various products
        self.gmt_func = get_mult_function(self.gmt, self.gradeList)
        self.imt_func = get_mult_function(self.imt, self.gradeList)
        self.omt_func = get_mult_function(self.omt, self.gradeList)
        self.lcmt_func = get_mult_function(self.lcmt, self.gradeList)
        self.inv_func = get_leftLaInv(self.gmt, self.gradeList)

        # these are probably not useful, but someone might want them
        self.imt_prod_mask = imt_prod_mask
        self.omt_prod_mask = omt_prod_mask
        self.lcmt_prod_mask = lcmt_prod_mask
github pygae / clifford / clifford / _layout.py View on Github external
def lcmt_func_generator(self, grades_a=None, grades_b=None, filter_mask=None):
        return get_mult_function(
            self.lcmt, self.gradeList,
            grades_a=grades_a, grades_b=grades_b, filter_mask=filter_mask
        )
github pygae / clifford / clifford / _layout.py View on Github external
def omt_func_generator(self, grades_a=None, grades_b=None, filter_mask=None):
        return get_mult_function(
            self.omt, self.gradeList,
            grades_a=grades_a, grades_b=grades_b, filter_mask=filter_mask
        )
github pygae / clifford / clifford / _layout.py View on Github external
def gmt_func_generator(self, grades_a=None, grades_b=None, filter_mask=None):
        return get_mult_function(
            self.gmt, self.gradeList,
            grades_a=grades_a, grades_b=grades_b, filter_mask=filter_mask
        )
github pygae / clifford / clifford / _layout.py View on Github external
def imt_func_generator(self, grades_a=None, grades_b=None, filter_mask=None):
        return get_mult_function(
            self.imt, self.gradeList,
            grades_a=grades_a, grades_b=grades_b, filter_mask=filter_mask
        )