up previous next
NC.SetRules

Set the (rewriting) rules over monoid rings.
Syntax
          
NC.SetRules(Rules:LIST)

          

Description
Please set ring environment coefficient fieldK, alphabet (or set of indeterminates) X and ordering via the functions NC.SetFp, NC.SetX and NC.SetOrdering, respectively, before calling the function. The default coefficient field is Q. The default ordering is length-lexicographic ordering ("LLEX"). For more information, please check the relevant functions.

Example
NC.RingEnv();
Coefficient ring : Q
Ordering : LLEX
-------------------------------
NC.SetX("ab");
Rules:=[["ba",[[1,"ab"],[1,""]]]]; -- ba= ab+1
NC.SetRules(Rules);
NC.RingEnv();
Coefficient ring : Q
Alphabet : ab
Ordering : LLEX
Rules : [["ba", [[1, "ab"], [1, ""]]]] -- rewriting rules consists of ba=ab+1
-------------------------------


See Also