This data structure is basically a collection of N matrices, representing the generators of the algebra.
A matrix representation is created with MrAlloc(). If the generators are available, they can be passed to MrAlloc(). Generators can also be added to a matrix representation with MrAddGenerator(). In both cases the user can choose if a copy of the matrices or only a reference to the matrices is stored in the representation. In either case, deleting the representation with MrFree() will also delete the generators. For example, after the following code has been executed:
Matrix_t *mat = MatLoad("matrix"); Rep = MrAlloc(1,&mat,0); MrFree(Rep);the
matpointer is no longer valid, because the matrix representation has been by MrFree(). However, after
Matrix_t *mat = MatLoad("matrix"); Rep = MrAlloc(1,&mat,MR_COPY_GENERATORS); MrFree(Rep);
matis still valid because a copy of the matrix was created.