#16812: use FLINT to speed up Chebyshev T polynomial creation
-------------------------------------+-------------------------------------
Reporter: rws | Owner:
Type: enhancement | Status: needs_work
Priority: major | Milestone: sage-6.4
Component: symbolics | Resolution:
Keywords: flint, speedup | Merged in:
Authors: Ralf Stephan | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
u/rws/use_flint_to_speed_up_chebyshev_t_polynomial_creation|
100622a45e0de7a891ac2cb579c5935571edf49a
Dependencies: | Stopgaps:
-------------------------------------+-------------------------------------
Comment (by rws):
Replying to [comment:5 jdemeyer]:
> I think the conditions `n>10 and is_PolynomialRing(P) and P.base() == ZZ
and P.ngens() == 1 and x == P.gen()` should be generalized:
>
> 1. It should work for any `n`, at least negative `n` should be
supported.
>
> 2. It should work for any ring of characteristic 0, not just `ZZ`.
>
> 3. Ideally, it should work for any kind of non-constant polynomial, not
just generators of univariate polynomial rings.
>
> Point 2 and 3 could be supported by first computing the polynomial in
`ZZ[x]` and then substituting and/or changing the base ring as needed. I'm
not saying this is needed on this ticket, but it would be the right thing
to do.
I have implemented this now and see no reason for the restriction in (2)
to characteristic 0, as it seems to me that changing the base ring to,
e.g., a finite field works nicely too.
In the process I uncovered at least two bugs.
I have removed the padics doctest for the moment because it was evaluated
using the new FLINT code and the subsequent substitution was a bit too
much. In this case the recursive evaulation is actually faster. But I have
no idea at the moment when to select which algorithm, in order to not to
fall in this trap.
--
Ticket URL: <http://trac.sagemath.org/ticket/16812#comment:12>
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 unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.