#12174: modular resultants for multivariate polynomials over QQ
------------------------+---------------------------------------------------
Reporter: saraedum | Owner: AlexGhitza
Type: task | Status: new
Priority: minor | Milestone: sage-4.8
Component: algebra | Keywords: resultant, discriminant, polynomial,
multivariate
Work_issues: | Upstream: N/A
Reviewer: | Author:
Merged: | Dependencies:
------------------------+---------------------------------------------------
Sage is somewhat slow when computing discriminants of multivariate
polynomials:
{{{
sage: R.<a0,a1,a2,a3,d,t> = QQ[]
sage:
f=(16/27)*(a3+d)^2*3*a2^2*t^7*d^2+12*a1*t^7*d^3+4*a2^3*a3*t^6-2*a2^3*t^6*d+
18*a1*a2*a3*t^6*d-*a1*a2*t^6*d^2+12*a0*t^6*d^3+3*a2^4*t^5+
6*a1*a2^2*a3*t^5-9*a1^2*a3^2*t^5+12*a1*a2^2*t^5*d+18*a1^2*a3*t^5*d+
18*a0*a2*a3*t^5*d+3*a1^2*t^5*d^2-6*a0*a2*t^5*d^2+6*a1*a2^3*t^4-
6*a1^2*a2*a3*t^4+6*a0*a2^2*a3*t^4-18*a0*a1*a3^2*t^4+
18*a1^2*a2*t^4*d+12*a0*a2^2*t^4*d+36*a0*a1*a3*t^4*d+
6*a0*a1*t^4*d^2+3*a1^2*a2^2*t^3+6*a0*a2^3*t^3-4*a1^3*a3*t^3-
12*a0*a1*a2*a3*t^3-9*a0^2*a3^2*t^3+8*a1^3*t^3*d+36*a0*a1*a2*t^3*d+
18*a0^2*a3*t^3*d+3*a0^2*t^3*d^2+6*a0*a1*a2^2*t^2-12*a0*a1^2*a3*t^2-
6*a0^2*a2*a3*t^2+24*a0*a1^2*t^2*d+18*a0^2*a2*t^2*d+3*a0^2*a2^2*t-
12*a0^2*a1*a3*t+24*a0^2*a1*t*d-4*a0^3*a3+8*a0^3*d)
sage: time d=f.discriminant(t)
Time: CPU 3101.66 s, Wall: 3101.78 s
}}}
Sage is relying on singular to compute the resultant of f and the
derivative of f. Alternatively, one can compute the determinant of the
Sylvester matrix; doing this mod p and using chinese remaindering then is
much faster in this example:
{{{
sage: time dm=modular_discriminant(f,t)
Time: CPU 42.55 s, Wall: 42.55 s
sage: d==dm
True
}}}
I attached the implementation of {{{modular_discriminant()}}}. This should
not go into sage like this, it's just some experiments I did. I haven't
tested it or thought about it too carefully.
Btw. Maple 9.5 needs about 4s to compute this; a recent version of Maple
was even faster, but I don't have the data here right now.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12174>
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.