On 10/4/11 11:14 PM, Mike Hansen wrote:
On Tue, Oct 4, 2011 at 9:09 PM, Dan Drake<[email protected]> wrote:
It seems unreasonably annoying to plot a bunch of Bessel functions
together. How can I work around this?
This is due to the way binding works in list comprehensions. For a
good explanation and workaround, see
http://stackoverflow.com/questions/139819/why-results-of-map-and-list-comprehension-are-different
In particular, this is one way to do it:
sage: f0, f1 = [lambda x,n=n: bessel_J(n, x) for n in [0,1]]
sage: f0(0)
1.00000000000000
Jason
--
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org