|
D.2.8.4 defring
Procedure from library ring.lib (see ring_lib).
- Usage:
- defring(ch,n,va,or); ch,va,or=strings, n=integer
- Return:
- ring R with characteristic 'ch', ordering 'or' and n variables with
names derived from va.
If va is a single letter, say va="a", and if n<=26 then a and the
following n-1 letters from the alphabet (cyclic order) are taken as
variables. If n>26 or if va is a single letter followed by a bracket,
say va="T(", the variables are T(1),...,T(n).
- Note:
- This proc is useful for defining a ring in a procedure.
This proc uses 'execute' or calls a procedure using 'execute'.
Example:
| LIB "ring.lib";
def r=defring("0",5,"u","ls"); r; setring r;"";
==> // characteristic : 0
==> // number of vars : 5
==> // block 1 : ordering ls
==> // : names u v w x y
==> // block 2 : ordering C
==>
def R=defring("2,A",10,"x(","dp(3),ws(1,2,3),ds"); R; setring R;
==> // characteristic : 2
==> // 1 parameter : A
==> // minpoly : 0
==> // number of vars : 10
==> // block 1 : ordering dp
==> // : names x(1) x(2) x(3)
==> // block 2 : ordering ws
==> // : names x(4) x(5) x(6)
==> // : weights 1 2 3
==> // block 3 : ordering ds
==> // : names x(7) x(8) x(9) x(10)
==> // block 4 : ordering C
kill R,r;
|
|