I wrote: > Martin Rubey wrote: > > root <[EMAIL PROTECTED]> writes: > > > Axiom has a closed form for 2 integrals where Schaums has series. > > > > But at least one of them seems to be wrong. Since it seems that my message > > was > > overlooked, I repeat it here: > > > > [EMAIL PROTECTED] writes: > > > > > 14:668 SCHAUMS AND AXIOM DIFFER (Axiom has closed form) > > > > But I'm not so sure that it is correct, at least not for a=1 and x in 0..1. > > > > draw(D(integrate(asech(x)/x,x),x)-asech(x)/x, x=0..1) > > > > Integral of 'asech(x)/x' is definitely wrong. I belive that the > error is in 'lfextendedint': > > lfextendedint(f, x, g) == > empty?(l := varselect(kernels f, x)) => [x::F * f, 0] > symbolIfCan(k := kmax(l)) > case SE => > map(multivariate(#1, k), extendedint(univariate(f, k), > univariate(g, k))) > ... > > AFAICS we need stronger condition than 'case SE' (and extra code > to handle remaining cases). >
For FriCAS I applied the following fix: Index: src/algebra/intef.spad.pamphlet =================================================================== --- src/algebra/intef.spad.pamphlet (wersja 274) +++ src/algebra/intef.spad.pamphlet (kopia robocza) @@ -232,8 +232,12 @@ empty?(l := varselect(kernels f, x)) => [x::F * f, 0] symbolIfCan(k := kmax(l)) case SE => + g1 := + empty?(l1 := varselect(kernels g, x)) => 0::F + kmax(l1) = k => g + 0::F map(multivariate(#1, k), extendedint(univariate(f, k), - univariate(g, k))) + univariate(g1, k))) is?(k, "exp"::SE) => expextint(f, x, k, g) prim?(k, x) => primextint(f, x, k, g) has?(operator k, ALGOP) => alglfextint(f, k, l, x, g) Index: src/input/bugs2008.input.pamphlet =================================================================== --- src/input/bugs2008.input.pamphlet (wersja 274) +++ src/input/bugs2008.input.pamphlet (kopia robocza) @@ -71,6 +71,15 @@ testEquals("gcd([67108859*67108859*x^2-1, 67108859*67108859*x^2+2*67108859*x +1])", "67108859*x+1") testEquals("gcd([0, 0, x^2-1, x^2+2*x+1])$HeuGcd(SparseUnivariatePolynomial Integer)", "(x+1)::(SparseUnivariatePolynomial Integer)") +testcase "Integral of asech(x)/x" +i1 := integrate(asech(x)/x, x) +isym := "integral"::Symbol +testTrue "is?(operator(kernels(i1).1), isym)" +i2 := integrate(log((sqrt(1-x^2)+1)/x)/x, x) +testTrue "is?(operator(kernels(i2).1), isym)" + +testEquals("integrate(log(sqrt(1-x^2)/x)/(x^2), x)", "(-log(sqrt(1-x^2)/x) -x*log(x+1)/2 + x*log(x-1)/2 + 1)/x") + )set output algebra on statistics() @ Index: ChangeLog.wh =================================================================== --- ChangeLog.wh (wersja 278) +++ ChangeLog.wh (kopia robocza) @@ -1,3 +1,9 @@ +2008-05-08 Waldek Hebisch <[EMAIL PROTECTED]> + + * src/algebra/intef.spad.pamphlet: lfextendedint(): + when integrating rational functions use only logarithms + of rational functions. + 2008-05-07 Waldek Hebisch <[EMAIL PROTECTED]> * src/etc/Makefile.in: stamp-databases: Avoid error -- Waldek Hebisch [EMAIL PROTECTED] _______________________________________________ Axiom-developer mailing list Axiom-developer@nongnu.org http://lists.nongnu.org/mailman/listinfo/axiom-developer