#4102: make bessel_J symbolic
----------------------------------+-----------------------------------------
Reporter: jwmerrill | Owner: burcin
Type: enhancement | Status: new
Priority: major | Milestone: sage-5.6
Component: calculus | Resolution:
Keywords: | Work issues:
Report Upstream: N/A | Reviewers:
Authors: Benjamin Jones | Merged in:
Dependencies: | Stopgaps:
----------------------------------+-----------------------------------------
Comment (by benjaminfjones):
Replying to [comment:13 kcrisman]:
Thanks for the comments. I finally found some time to get back to this
ticket :)
> Nice! A few comments of the type you solicited:
> * Why `typ` and not `type`? Some Python reserved thing, maybe? But it
looks like a typ-o to the (quickly reading) end user.
That was intentional, I was trying not to shadow the builtin name.
> * I'd like to be able to plot `f(x) = Bessel(0)` but maybe that doesn't
make sense? I guess a variable is necessary... anyway, just throwing it
out there.
I think `f(x) = Bessel(0,x)` is better, I don't like `x` being implicit on
the right hand side.
> * `f = maxima(Bessel(typ='K')(x,y))` turns out great, but does it
convert back? Like `f.derivative('y')` is
`-(bessel_k(x+1,y)+bessel_k(x-1,y))/2`, but does it then (when put in the
`_sage_` method) go back to "our" uppercase Bessel functions?
Good question, I haven't tested it out. I think I'm going to rewrite most
of the code anyway so I'll keep this in mind.
> * Maybe Python 3 string formatting? Though I am not sure how to mix
that with LaTeX braces.
???
> * At least some of the error messages should be in doctests, maybe the
ones with the wrong type and a non-implemented system.
Good point, I'll make sure to doctest the exceptions.
> * `class_attrs['_conversions'] = {} ` --- what do we do with this in
Maxima, then? Maybe it's better to raise an error; Maxima tends to
otherwise just take things as new variables, which could be dangerous.
I don't know about this. I had this in the case of the single parameter
functions like `Bessel(1,'K')` that Maxima doesn't have equivalents for
(it just has the two parameter functions). I think I'll scrap the idea of
having all infinitely many one-parameter Bessel functions registered as
their own symbolic functions (see Burcin's comments below).
> * How many of the currently-deleted doctests do you think would be
worth preserving in the long run? Any deprecation needed here?
Ideally all of them. Some will need to be modified because of the change
in numerical back-end.
> Anyway, clearly a lot of planning and looks very promising!
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/4102#comment:15>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
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-trac?hl=en.