]> www.ginac.de Git - ginac.git/blobdiff - ginsh/ginsh.1.in
- degree(), ldegree(), coeff(), lcoeff(), tcoeff() and collect() work with
[ginac.git] / ginsh / ginsh.1.in
index 7857f662788093f3b57f5fd68316eaf786ef7a62..97c0bbbcd508cbb32dc1801e496f0b1060d68d2b 100644 (file)
@@ -229,16 +229,19 @@ detail here. Please refer to the GiNaC documentation.
 .BI charpoly( matrix ", " symbol )
 \- characteristic polynomial of a matrix
 .br
 .BI charpoly( matrix ", " symbol )
 \- characteristic polynomial of a matrix
 .br
-.BI coeff( expression ", " symbol ", " number )
-\- extracts coefficient of symbol^number from a polynomial
+.BI coeff( expression ", " object ", " number )
+\- extracts coefficient of object^number from a polynomial
 .br
 .br
-.BI collect( expression ", " symbol )
-\- collects coefficients of like powers
+.BI collect( expression ", " object-or-list )
+\- collects coefficients of like powers (result in recursive form)
+.br
+.BI collect_distributed( expression ", " list )
+\- collects coefficients of like powers (result in distributed form)
 .br
 .BI content( expression ", " symbol )
 \- content part of a polynomial
 .br
 .br
 .BI content( expression ", " symbol )
 \- content part of a polynomial
 .br
-.BI degree( expression ", " symbol )
+.BI degree( expression ", " object )
 \- degree of a polynomial
 .br
 .BI denom( expression )
 \- degree of a polynomial
 .br
 .BI denom( expression )
@@ -280,10 +283,10 @@ detail here. Please refer to the GiNaC documentation.
 .BI lcm( expression ", " expression )
 \- least common multiple
 .br
 .BI lcm( expression ", " expression )
 \- least common multiple
 .br
-.BI lcoeff( expression ", " symbol )
+.BI lcoeff( expression ", " object )
 \- leading coefficient of a polynomial
 .br
 \- leading coefficient of a polynomial
 .br
-.BI ldegree( expression ", " symbol )
+.BI ldegree( expression ", " object )
 \- low degree of a polynomial
 .br
 .BI lsolve( equation-list ", " symbol-list )
 \- low degree of a polynomial
 .br
 .BI lsolve( equation-list ", " symbol-list )
@@ -319,7 +322,7 @@ detail here. Please refer to the GiNaC documentation.
 .BI series( expression ", " relation-or-symbol ", " order )
 \- series expansion
 .br
 .BI series( expression ", " relation-or-symbol ", " order )
 \- series expansion
 .br
-.BI sqrfree( expression ", " symbol )
+.BI sqrfree( "expression [" ", " symbol-list] )
 \- square-free factorization of a polynomial
 .br
 .BI sqrt( expression )
 \- square-free factorization of a polynomial
 .br
 .BI sqrt( expression )
@@ -330,7 +333,7 @@ detail here. Please refer to the GiNaC documentation.
 .BI subs( expression ", " look-for-list ", " replace-by-list )
 \- substitute subexpressions
 .br
 .BI subs( expression ", " look-for-list ", " replace-by-list )
 \- substitute subexpressions
 .br
-.BI tcoeff( expression ", " symbol )
+.BI tcoeff( expression ", " object )
 \- trailing coefficient of a polynomial
 .br
 .BI time( expression )
 \- trailing coefficient of a polynomial
 .br
 .BI time( expression )
@@ -401,11 +404,11 @@ from within ginsh without having to quit.
 .SH EXAMPLES
 .nf
 > a = x^2\-x\-2;
 .SH EXAMPLES
 .nf
 > a = x^2\-x\-2;
-\-x+x^2\-2
+\-2\-x+x^2
 > b = (x+1)^2;
 (x+1)^2
 > s = a/b;
 > b = (x+1)^2;
 (x+1)^2
 > s = a/b;
-(x+1)^(\-2)*(\-x+x^2\-2)
+(x+1)^(\-2)*(\-2\-x+x^2)
 > diff(s, x);
 (2*x\-1)*(x+1)^(\-2)\-2*(x+1)^(\-3)*(\-x+x^2\-2)
 > normal(s);
 > diff(s, x);
 (2*x\-1)*(x+1)^(\-2)\-2*(x+1)^(\-3)*(\-x+x^2\-2)
 > normal(s);
@@ -417,11 +420,13 @@ from within ginsh without having to quit.
 > Digits = 40;
 40
 > evalf(s);
 > Digits = 40;
 40
 > evalf(s);
-0.999999999999999999999995821133292704384960990679L0
+0.999999999999999999999995821133292704384960990679
 > unassign('x');
 x
 > s;
 (x+1)^(\-2)*(\-x+x^2\-2)
 > unassign('x');
 x
 > s;
 (x+1)^(\-2)*(\-x+x^2\-2)
+> series(sin(x),x==0,6);
+1*x+(\-1/6)*x^3+1/120*x^5+Order(x^6)
 > lsolve([3*x+5*y == 7], [x, y]);
 [x==\-5/3*y+7/3,y==y]
 > lsolve([3*x+5*y == 7, \-2*x+10*y == \-5], [x, y]);
 > lsolve([3*x+5*y == 7], [x, y]);
 [x==\-5/3*y+7/3,y==y]
 > lsolve([3*x+5*y == 7, \-2*x+10*y == \-5], [x, y]);