About simpson and traprule funcions



hello jaime,

about COERCE-FLOAT-FUN,

> That information is very useful, as I was attempting to
> reinvent that wheel to make a few programs work as the latest
> version of plot2d.

OK, just to be clear, COERCE-FLOAT-FUN constructs a
lisp function which evaluates a general maxima expression,
a maxima function, or a maxima lambda expression to a float value.

(CFF just returns $FOO if $FOO is a symbol associated
with a function defined by DEFUN or DEFMFUN.
functions defined by DEFMSPEC and simplifying functions
can't be handled by CFF at present, although it seems like
it should be possible to extend CFF to those cases.)

> (%i1) solve(lambda([x],2*x^2-3*x+4));
> (%o1) []
> (%i2) diff(lambda([x],2*x^2-3*x+4), x);
> (%o2) 'diff(lambda([x],2*x^2-3*x+4),x,1)
> (%i3) integrate(lambda([x],2*x^2-3*x+4), x);
> (%o3) x*lambda([x],2*x^2-3*x+4)

perhaps there could be a COERCE-SYMBOLIC-FUN
called by diff, integrate, etc.
(i guess COERCE-SYMBOLIC-EXPR would be more
easily wedged into the existing code, right?
i.e. construct a general expression from a function name
or lambda expression. although that probably leads
to problems with name collisions.)

for what it's worth,
robert dodier