#10716: Adding a weighted_degree function to Singular multivariate polynomials
-------------------------------------+-------------------------------------
Reporter: jsrn | Owner: AlexGhitza
Type: enhancement | Status: needs_review
Priority: minor | Milestone: sage-6.3
Component: algebraic | Resolution:
geometry | Merged in:
Keywords: multivariate | Reviewers: Marshall Hampton
polynomials,degree,Singular | Work issues:
Authors: Johan S. R. | Commit:
Nielsen, Luis Felipe Tabera | 811b79657358bcc6c1201715cd35ffab9a42e346
Alonso | Stopgaps:
Report Upstream: N/A |
Branch: |
u/lftabera/weighted_degree |
Dependencies: |
-------------------------------------+-------------------------------------
Comment (by lftabera):
I created another method substitutying the Integer with int. Then used the
following code. To get an idea.
{{{
sage: K1=QQ['x,y']
sage: K2=PolynomialRing(QQ,'a',5)
sage: K3=PolynomialRing(QQ,'b',30)
sage: f=K1.random_element()
sage: g=K2.random_element(degree=10,terms=24)
sage: h=K3.random_element(degree=100,terms=10**5) #quite long time
sage: vf=random_vector(ZZ,2)
sage: vg=random_vector(ZZ,20)
sage: vh=random_vector(ZZ,30)
sage: %timeit f.weighted_degree(vf)
sage: %timeit f.weighted_degree_int(vf)
sage: %timeit g.weighted_degree(vg)
sage: %timeit g.weighted_degree_int(vg)
sage: %timeit h.weighted_degree(vh)
sage: %timeit h.weighted_degree(vh)
}}}
I do not have a strong opinion. Integer does not overflow, but int is
faster (but also slow) and behaves like degree method (also returns int).
--
Ticket URL: <http://trac.sagemath.org/ticket/10716#comment:33>
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.