On Tue, 08 Dec 2009 at 10:44PM -0300, Pablo De Napoli wrote: > I'm trying to do some computations with Bessel functions using Sage. > Unfortunately, they don't seem to behave like other functions. For example: > to get the plot of the sine function over the interval (0,100) > > plot(sin(x),(x,0,100)) > > works. However, > > plot(bessel_J(0,x),(x,0,100)) > > does not.
Part of the reason is that (I think) the Bessel functions are not implemented as fully symbolic functions; they are more numerical in nature under our current implementation. An effective workaround for your problems is to make anonymous functions: plot(lambda x: bessel_J(0, x), (0, 100)) which gives plot() a regular Python function of one variable that it can use. Dan -- --- Dan Drake ----- http://mathsci.kaist.ac.kr/~drake -------
signature.asc
Description: Digital signature