Patch for discussion - integrating special functions



Am Mittwoch, den 21.10.2009, 22:17 +1100 schrieb David Billinghurst:
> I have been looking at the code for integrating special functions in 
> sin.lisp.  This patch is posted for discussion. Of course, I think it 
> improves the clarity of the code, but I don't want to make unnecessary 
> changes without discussion.
> 
> The main change is in function integrallookups.  The hard coded 
> integrals of elementary special functions are removed and  replaced by 
> 'integral forms on the function property lists.  To leave the testsuite 
> results unchanged, two further changes are required:
> 1) In function intform, mexpt and the trig functions are excluded from 
> calling partial-integration
> 2) In function partial-integration it is necessary to limit the 
> recursion depth.

Yes, I think it is a good idea to simplify the code and to cut out the
hard coded integrals. 

The code is easier to read and executes faster. The knowledge of the
function is part of its property list and not part of the routine which
does the integration. At the end the code is more general.

Perhaps it is a good idea to place the integral properties of the
functions at the place the function is defined. Unfortunately, a lot of
knowledge about the mathematical functions is distributed over many
files and sometimes difficult to find.

Dieter Kaiser