Ask Your Question
0

Efficient reduction to elementary symmetric polynomials

asked 2024-02-19 08:50:54 +0200

kejv2 gravatar image

When using the resolvent method for solving polynomial equations, there's a step to express the coefficients of a polynomial (so-called resolvent) in elementary symmetric polynomials. For instance, for the general quintic one gets a resolvent of degree six, and one of its simpler coefficients is:

15*e[1, 1, 1, 1, 1, 1, 1, 1] - 160*e[2, 1, 1, 1, 1, 1, 1] + 528*e[2, 2, 1, 1, 1, 1] - 448*e[2, 2, 2, 1, 1] - 160*e[2, 2, 2, 2] + 336*e[3, 1, 1, 1, 1, 1] - 2208*e[3, 2, 1, 1, 1] + 2752*e[3, 2, 2, 1] + 2368*e[3, 3, 1, 1] - 3328*e[3, 3, 2] - 96*e[4, 1, 1, 1, 1] + 512*e[4, 2, 1, 1] + 2304*e[4, 2, 2] - 8960*e[4, 3, 1] + 17920*e[4, 4] - 1136*e[5, 1, 1, 1] + 5456*e[5, 2, 1] - 14144*e[5, 3] + 2736*e[6, 1, 1] - 6464*e[6, 2] + 1248*e[7, 1] + 1664*e[8]

The problem is that the reduction of the more complicated coefficients takes quite long even for this small degree polynomial. There are, however, two special properties of my polynomial that I think could be utilized here:

  • My input polynomial is in the depressed form, meaning that $e_1$ is 0. Therefore I can ignore all terms where $e_1$ appears.
  • I know that I'm working with symmetric expressions of 5 roots, therefore I can also ignore all terms with $e_i$ for $i > 5$.

Is there any way how to utilize those properties to help Sage simplify the computation? I'm using the from_polynomial function from the SymmetricFunctions class.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2024-02-19 17:31:34 +0200

Max Alekseyev gravatar image

updated 2024-02-19 18:42:00 +0200

You can use the function like

def myreduce(f):
    return f.parent()._from_dict( {d:c for d,c in f if d[0]<=5 and d[-1]>=2} )

then myreduce(f), where f is your polynomial, gives

-160*e[2, 2, 2, 2] - 3328*e[3, 3, 2] + 2304*e[4, 2, 2] + 17920*e[4, 4] - 14144*e[5, 3]

See also this answer.

edit flag offensive delete link more

Comments

I wasn't asking how to reduce the expression in elementary symmetric polynomials, but rather how to speed up the computation of SymmetricFunctions.from_polynomial given the special conditions I have. That is my input is some polynomial in the roots (which I know is symmetric) and I want to express it in $e_i$. But I guess there really isn't a way other than writing the reduction algorithm myself.

kejv2 gravatar imagekejv2 ( 2024-02-19 18:59:00 +0200 )edit

It's unclear what is your set up. If you work with symmetric expressions of 5 roots only, how do you get $e_i$ with $i>5$ in the result of from_polynomial? In general you can reduce your polynomial in the ideal generated by polynomials like $e_1$ (known to be zero) before converting to a symmetric one.

Max Alekseyev gravatar imageMax Alekseyev ( 2024-02-19 20:46:37 +0200 )edit

If you work with symmetric expressions of 5 roots only, how do you get ei with i>5 in the result of from_polynomial

The same as in your question you linked: My polynomial is of higher degree than the number of variables (which in my case is the hypothetical roots of a (different) polynomial to be solved)

kejv2 gravatar imagekejv2 ( 2024-02-19 22:18:17 +0200 )edit

you can reduce your polynomial in the ideal generated by polynomials like e1 (known to be zero) before converting to a symmetric one.

Yeah, that's what I tried at first but the reduce operation breaks the symmetry (quite naturally). E.g. (a^2 + b^2 + c^2 + d^2).reduce([a+b+c+d]) is no longer symmetric because the a is eliminated by the division algorithm,

kejv2 gravatar imagekejv2 ( 2024-02-19 22:35:50 +0200 )edit

I do not follow. (a^2 + b^2 + c^2 + d^2).reduce([a+b+c+d])is symmetric in the remaining three variables. E.g. see https://sagecell.sagemath.org/?q=jxrjub

Max Alekseyev gravatar imageMax Alekseyev ( 2024-02-20 02:36:44 +0200 )edit

Ok. It is symmetric but is there any relation between this new polynomial in 3 variables to the original one? In particular, can the original $e_i$ be recovered from the new $e_i$? To repeat my goal, given a symmetric polynomial I would like to express it in elementary symmetric polynomials while somehow utilizing the fact that $e_1$ is zero during the computation. I.e. my goal is to speed up the computation given the special properties.

kejv2 gravatar imagekejv2 ( 2024-02-20 21:42:42 +0200 )edit

If $e_i, e'_i$ are "old" and "new" polynomials, respectively, then $e_i = e'_i - e'_1e'_{i-1}$. So, you can work with new polynomials and then switch back to old one when needed.

Max Alekseyev gravatar imageMax Alekseyev ( 2024-02-20 21:59:24 +0200 )edit

Now I don't follow :-) To recover $e_i$ you surely need some original (non-primed) $e$ on the right hand side. Otherwise you are missing a. Perhaps just a typo? But anyway, looking at the simple cases https://sagecell.sagemath.org/?q=mxzabp I don't see any simple recovering relation.

kejv2 gravatar imagekejv2 ( 2024-02-21 22:19:23 +0200 )edit

No. Here are a bit ugly but working (back and force) conversion functions: https://sagecell.sagemath.org/?q=khljrd

Max Alekseyev gravatar imageMax Alekseyev ( 2024-02-22 00:14:23 +0200 )edit

Thank you for your time and effort but I still don't see what you mean. I must be missing some piece of theory you could perhaps point me to.

Anyway, just to restate my goal on a concrete example, I want to express f = a^3 + b^3 + c^3 in ESym, i.e. e[1, 1, 1] - 3*e[2, 1] + 3*e[3]. I also know beforehand that e[1] = a + b + c is zero, therefore the result I'm after is 3*e[3]. The whole question is whether there's a way to get this result without converting f to ESym first.

kejv2 gravatar imagekejv2 ( 2024-02-22 22:26:25 +0200 )edit

One of the possible options I tried was to first reduce by e[1]: e.from_polynomial(f).reduce([a+b+c]).specialization({a:0}). As you pointed out, this gives a symmetric polynomial in b, c although that's not at all clear why this should be the case. Is it a special property of the Grobner basis algorithm that is (probably) used here? Because another valid value of course would also be 3*e[3] = 3*a*b*c which is what I originally hoped I would get after the reduction.

Anyway, when I plug in this reduced polynomial to your to_old function I get 9*e[3], i.e. not the correct result.

kejv2 gravatar imagekejv2 ( 2024-02-22 22:31:43 +0200 )edit

My point is that you can perform computations with symmetric ("primed") functions of one fewer variables, which will take care of $e_1=0$ automatically. Then you can get the result transformed back to a symmetric ("non-primed") function of original variables. I've provided conversion functions in the last link to Sagecell.

This way, you first eliminate one variable from f and then convert it into a symmetric polynomial of the remaining variables to get the ball running.

Max Alekseyev gravatar imageMax Alekseyev ( 2024-02-22 22:37:02 +0200 )edit

Can you provide a complete example? Also, it should be e.from_polynomial( f.reduce([a+b+c]).specialization({a:0}) ), not e.from_polynomial(f).reduce([a+b+c]).specialization({a:0}).

Max Alekseyev gravatar imageMax Alekseyev ( 2024-02-22 22:42:05 +0200 )edit

Sorry, I made a copy&paste error probably but my computations were correct, i.e. this to_old( e.from_polynomial( (a^3 + b^3 + c^3).reduce([a+b+c]).specialization({a:0}) ) ) gives (using your conversion function) 9*e[3] which is not 3*e[3] (the only e[1]-less term of e.from_polynomial(a^3 + b^3 + c^3)

kejv2 gravatar imagekejv2 ( 2024-02-23 08:11:11 +0200 )edit

Anyway, I realize now that this whole exercise (while interesting in itself) is probably pointless since it seems that calling from_polynomial on the reduced input isn't significantly faster after all :-( I start doubting that there actually is a useful optimization for the e[1] == 0 case.

kejv2 gravatar imagekejv2 ( 2024-02-23 13:11:01 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2024-02-19 08:50:54 +0200

Seen: 117 times

Last updated: Feb 19