sage devel re factoring questions factoringbusinesssite com
On Mon, Aug 17, 2009 at 2:26 AM, William Stein wrote:
>
factoring business
> On Mon, Aug 17, 2009 at 1:14 AM, Ondrej Certik wrote:
>>
factoring business
>> Hi,
>>
>> at the scipy 09 conference I am going to compare Sage and sympy
>> approaches to factoring (and timings) and longer term approaches, so I
factoring business
>> have a few questions about it, so that I understand things correctly.
>> If I do:
>>
>> sage: var("x y z")
factoring business
>> (x, y, z)
>> sage: a = (x+y+z)**20
>> sage: b = a.expand()
factoring business
>> sage: %time c = factor(b)
>> CPU times: user 0.14 s, sys: 0.00 s, total: 0.factoring business 15 s
>> Wall time: 0.15 s
>>
>>
>> 1) it uses pari,factoring business right?
>
> NO. Pari has no functionality at all for doing anything nontrivial
> with multivariate polynomials. Do b.factoring business factor?? to see the source.
> Sage tries to convert b to a poly over QQ, this works, then it calls
> SINGULAR to factor that.factoring business If conversion doesn't work, it falls back to
> Maxima right now.
Thanks for all the clarifications, this answers all my questions.factoring business I
was looking into the function couple days ago and I don't know how I
got the impression that it uses pari ¡ª when I looked now, it indeed
uses singular and spends most of the time in the conversion.
factoring business
We are now roughly on the level of maxima with our new not yet
reviewed poly patches to sympy:
http://code.google.com/p/sympy/issues/detail?id=1598
and with gmpy (but otherwise still pure python) it's only about 4x
factoring business
slower than sage + singular, but that's because Sage also is pure
python here, so after cythonizing the conversion in Sage it will
probably be 100x faster (as you suggested) ¡ª so I am curious how
fast sympy's factor will be after cythonizing it a bit too.factoring business
Essentially to make fair comparisons in the long term, I'll keep in
mind that singular is the potential top speed here (assuming you can
optimize the conversion back and forth). You also mentioned that
factoring business
singular itself can be sped up, but I have no idea how much, as I am
not an expert in this multivariate factoring business at all (Mateusz
Paprocki, who wrote the sympy patches,factoring business is).
Ondrej
¨C~¨C~¡ª¡ª¡ª~¨C~¡ª-~¡ª¡ª¡ª¡ª~¡ª¡ª-~¨C~¡ª-~
To post to this group, send an email to sage-devel@googlegroups.factoring business com
To unsubscribe from this group, send an email to sage-devel-unsubscribe@googlegroups.com
For more options, visit this group at http://groups.factoring business google.com/group/sage-devel
URLs: http://www.sagemath.org
-~¡ª¡ª¡ª-~¡ª-~¡ª-~¡ª-~¡ª¡ª~¡ª-~¡ª¡ª~¨C~¡ª.