Opened 3 years ago
Last modified 3 years ago
#23338 closed enhancement
Clean up polynomial constructor — at Version 8
Reported by:  jdemeyer  Owned by:  

Priority:  major  Milestone:  sage8.0 
Component:  algebra  Keywords:  
Cc:  tscrim  Merged in:  
Authors:  Jeroen Demeyer  Reviewers:  
Report Upstream:  N/A  Work issues:  
Branch:  u/jdemeyer/clean_up_polynomial_constructor (Commits)  Commit:  883d50709298487518d7d0a2771045483adb0cf9 
Dependencies:  Stopgaps: 
Description (last modified by )
This ticket cleans up the PolynomialRing()
function in many ways. Mainly:
 Use
normalize_names()
as much as possible to deal with variable names.
 Fix indentation in docstring.
 Pass arguments like
sparse
andimplementation
as**kwds
to the singlevariate or multivariate polynomial constructor.
 Make the code easier to understand.
 Add a new keyword argument
multivariate
to force a multivariate polynomial ring, even if there is only 1 variable.
 Check more error conditions, for example currently we have
sage: PolynomialRing(QQ, name="x", names="y") Univariate Polynomial Ring in y over Rational Field
 Change some arguments of
PolynomialRing()
to keywordonly arguments. This does break some existing uses ofPolynomialRing()
(some even wrong: some Singular code was passingsparse="lex"
instead ororder="lex"
)
Apart from items 6 and 7, no existing functionality is changed.
Change History (8)
comment:1 Changed 3 years ago by
 Cc tscrim added
comment:2 Changed 3 years ago by
 Branch set to u/jdemeyer/clean_up_polynomial_constructor
comment:3 Changed 3 years ago by
 Commit set to 883d50709298487518d7d0a2771045483adb0cf9
First version, not finished or tested yet. But feel free to comment...
New commits:
883d507  Clean up PolynomialRing() constructor

comment:4 Changed 3 years ago by
 Description modified (diff)
comment:5 Changed 3 years ago by
 Description modified (diff)
comment:6 Changed 3 years ago by
 Description modified (diff)
comment:7 Changed 3 years ago by
 Description modified (diff)
comment:8 Changed 3 years ago by
 Description modified (diff)
Note: See
TracTickets for help on using
tickets.
+1