]> www.ginac.de Git - ginac.git/commitdiff
added decomp_rational()
authorChristian Bauer <Christian.Bauer@uni-mainz.de>
Tue, 19 Jun 2001 19:50:14 +0000 (19:50 +0000)
committerChristian Bauer <Christian.Bauer@uni-mainz.de>
Tue, 19 Jun 2001 19:50:14 +0000 (19:50 +0000)
ginsh/ginsh.1.in
ginsh/ginsh_parser.yy

index becefecf5b03aeb97e93abba06f1171ccc0c9a9b..e8c24a5040bb29a61c83c856fa3553bd25edc682 100644 (file)
@@ -246,6 +246,9 @@ detail here. Please refer to the GiNaC documentation.
 .BI content( expression ", " symbol )
 \- content part of a polynomial
 .br
 .BI content( expression ", " symbol )
 \- content part of a polynomial
 .br
+.BI decomp_rational( expression ", " symbol )
+\- decompose rational function into polynomial and proper rational function
+.br
 .BI degree( expression ", " object )
 \- degree of a polynomial
 .br
 .BI degree( expression ", " object )
 \- degree of a polynomial
 .br
index be3f6862d1dae63c3636c1b15d6886a41c1b5410..2e514778b27085a9d4db6f1bfbb30f86201f768a 100644 (file)
@@ -319,6 +319,12 @@ static ex f_content(const exprseq &e)
        return e[0].content(ex_to<symbol>(e[1]));
 }
 
        return e[0].content(ex_to<symbol>(e[1]));
 }
 
+static ex f_decomp_rational(const exprseq &e)
+{
+       CHECK_ARG(1, symbol, decomp_rational);
+       return decomp_rational(e[0], ex_to<symbol>(e[1]));
+}
+
 static ex f_determinant(const exprseq &e)
 {
        CHECK_ARG(0, matrix, determinant);
 static ex f_determinant(const exprseq &e)
 {
        CHECK_ARG(0, matrix, determinant);
@@ -489,6 +495,7 @@ static const fcn_init builtin_fcns[] = {
        {"collect", fcn_desc(f_collect, 2)},
        {"collect_distributed", fcn_desc(f_collect_distributed, 2)},
        {"content", fcn_desc(f_content, 2)},
        {"collect", fcn_desc(f_collect, 2)},
        {"collect_distributed", fcn_desc(f_collect_distributed, 2)},
        {"content", fcn_desc(f_content, 2)},
+       {"decomp_rational", fcn_desc(f_decomp_rational, 2)},
        {"degree", fcn_desc(f_degree, 2)},
        {"denom", fcn_desc(f_denom, 1)},
        {"determinant", fcn_desc(f_determinant, 1)},
        {"degree", fcn_desc(f_degree, 2)},
        {"denom", fcn_desc(f_denom, 1)},
        {"determinant", fcn_desc(f_determinant, 1)},