Is integration and differentiation code sepparate?
Subject: Is integration and differentiation code sepparate?
From: Stavros Macrakis
Date: Fri, 12 Nov 2010 11:26:16 -0500
For polynomials, it is highly unlikely that random-coefficient tests will
find any problems.
By the way, you mention complex powers in your polynomials. Fractional and
complex powers are not normally considered polynomials (for lots of good
reasons).
For non-polynomials, it should of course be true that
Differentiate(Integrate(f)) = f. However, that does not mean that the
*form* of Differentiate(Integrate(f)) is the same as f. And determining
whether two expressions represent the same function is often difficult (in
fact unsolvable in
general<http://books.google.com/books?id=B9tC7DOX_oUC&pg=PA81&lpg=PA81&dq=zero-equivalence+unsolvable&source=bl&ots=rhQBOJvapS&sig=hGndNQi1tohzn7VBGidMeojpv64&hl=en&ei=7WndTJKPO4P58Aa9v8jxDw&sa=X&oi=book_result&ct=result&resnum=5&ved=0CDgQ6AEwBA#v=onepage&q=zero-equivalence%20unsolvable&f=false>
).
-s
On Fri, Nov 12, 2010 at 09:53, Dr. David Kirkby <david.kirkby at onetel.net>wrote:
> I've been trying to automatically develop a large number of tests for Sage.
> Hopefully millions of them.
>
> Some of those tests actually test Maxima. I've only just started this, but
> the approach I've taken to date is:
>
> 1) Generate a "random" polynomial using a pseudo random number generator.
> 2) Simplify the polynomail, so the output is in a form that's reproducible.
> 3) Integrate the polynomial.
> 4) Differentiate the result from (3)
> 5) Simplify the result from (4)
> 6) Compare the results from (2) and (5).
>
> All being well, steps (2) and (5) should be equal.
>
> For simple polynomails, this does indeed seem to be the case. I've
> generated many thousands of them, sometimes with complex coefficients and
> complex powers, and all seems to be ok.
>
> I'm just wondering if there's any common code, which might actually mean
> the such tests are meaningless.
>
>
>
> I've found more complex cases (using sin, sinh, tan arctan etc) where the
> results of integrating a function, then differentiating it do NOT lead to
> back to the original function using Maxima.
>
> But I've tried the same equations in Mathematica too, and that also has
> problems, with the result appearing to be much more complicated than what I
> started with. Perhaps I'm just expecting too much. Perhaps this approach is
> not mathematically valid - I'm not a mathematician.
>
>
> Dave
>
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>