Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

[ Not really an answer, but a complement to Serge's answer, in order too pinpoint the answer ]

A quick check:


def tst1(alg="maxima"):
    ad=f(x).integrate(x, algorithm=alg)
    did=f(x).integrate(x,1,4, algorithm=alg)
    # return [ad, check_ad, lb, ub, di, did, check_di, ndi]
    return [alg, check_ad, di, did, check_di]

T=table(rows=[tst1(alg=u) for u in ["maxima", "sympy", "giac", "fricas"]],
        header_row=["Algorithm", " AD checks", "Def. int. through AD",
                    "Def. int. directly", "Def. int. checks"])

shows that the antiderivative (aka primitive, AD) is correct (i.e. derivates back to f(x)) in all cases (and that its limits are correctly evaluated at each bound), but that the direct computation of the definite integral is wrong in Maxima :

 Algorithm    AD checks   Def. int. through AD      Def. int. directly          Def. int. checks
  maxima      True         6*log(3) - 4*log(2) - 2   4*log(3) + 2*log(4/3) - 2   False
  sympy       True         6*log(3) - 4*log(2) - 2   6*log(3) - 4*log(2) - 2     True
  giac        True         6*log(3) - 4*log(2) - 2   6*log(3) - 4*log(2) - 2     True
  fricas      True         6*log(3) - 4*log(2) - 2   6*log(3) - 4*log(2) - 2     True

This problem has been encountered more than once, is known to upstream, but does not seem to have been formally reported per se.