#5519: Irreducibility test is slow for polynomials over GF(2)
-------------------------+--------------------------------------------------
Reporter: rhinton | Owner: rhinton
Type: enhancement | Status: new
Priority: major | Milestone:
Component: algebra | Keywords:
-------------------------+--------------------------------------------------
Comment(by malb):
I think your timings are off since you time the {{{random_element()}}}
call.
== BEFORE ==
{{{
sage: P.<x> = GF(2)[]
sage: f = P.random_element(1000)
sage: %timeit f.is_irreducible()
10 loops, best of 3: 948 ms per loop
sage: f = P.random_element(10000)
sage: %time f.is_irreducible()
# gave up because it took minutes!
}}}
== AFTER ==
{{{
sage: P.<x> = GF(2)[]
sage: f = P.random_element(1000)
sage: %timeit f.is_irreducible()
10000 loops, best of 3: 22.7 µs per loop
sage: f = P.random_element(10000)
sage: %timeit f.is_irreducible()
1000 loops, best of 3: 394 µs per loop
sage: f = P.random_element(100000)
sage: %timeit f.is_irreducible()
100 loops, best of 3: 10.4 ms per loop
}}}
So we have 948*ms* vs. 22.3*micros* => {{{948*1000/22.3 =
42511.2107623318}}}
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/5519#comment:3>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of
Reinventing the Wheel
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---