Le 23/04/2020 à 18:53, Nils Bruin a écrit :
On Thursday, April 23, 2020 at 3:04:46 AM UTC-7, vdelecroix wrote:
I think that it would be good to implement this directly of the level of
multivariate polynomials. I opened
What would the uptake of such a method be? If I needed to test if a
polynomial is symmetric, I would probably end up rolling my own because:
- I wouldn't know or expect such a method to exist on symmetric polynomials
- I wouldn't know what the particular conditions and assumptions on the
input would be (and whether the author silently had different definitions
in mind than I had).
Because it's so easy to program myself, I would probably decide that's
faster than figuring out if the library version is appropriate (if I knew
if it existed in the first place).
In terms of use: I think it's very rare in a computational setting to want
to know if a polynomial is symmetric and not want it expressed in
(elementary) symmetric polynomials. That's a routine I'd look for --
although surprisingly, this is something that routinely gets done poorly in
computer algebra systems (including magma!), so I'd probably end up
implementing elimination anyway.
(in this case, it's clear the code is needed in at least one place of the
library, so it's not really a loss to put it somewhere, but for code
maintainability, I'd keep it closer to where it's used and then perhaps
refactor if it shows the demand is there to have it in a more accessible
spot)
I agree that if you have a symmetric polynomial at hand you most
probably don't want it expanded (or you are probably doing something
wrong).
But first of all, to make it fast there is no other option than
making it at the level of polynomials themselves (and even then
the generic version it is quite slow because I believe conversion
back and forth between Singular and Sage). Secondly, as a developer,
if I am looking whether such feature is implemented I would never
look into sage/combinat/sf/monomial.py. To my mind, there is more
risk of duplication by implementing it close to its usage rather
than close to the data structure it concerns. And finally, I
implemented the latter in ticket #29553.
--
You received this message because you are subscribed to the Google Groups
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/sage-devel/e6e2bba5-bf99-6439-3b78-74c12a62c7d5%40gmail.com.