# Is a combination of sum and product of any sequence unique?

Simple example in order to clarify what I mean:

Sequence - $\{2 , -1, 4, 2, 9 \}$ Sum and product combination: $\{ 16, -144 \}$

Question: Is a combination of sum and product unique for any* sequence?

• "any sequence" except that one which consists only of zeros.

UPD: The answer to my initial question is "no". Thanks. But what's the answer if we restrict ourselves to sequences of the same length and made of non-negative integers? Do two or more non-negative integer sequences exist, each of which has the same {sum,product} combination and the same length?

UPD: Both answers are "no". Thanks a lot.

-
{12, -12, (sixteen 1's)}. – kennytm Oct 28 '10 at 19:58
Wow, I haven't manage to come up with a good counterexample. Thanks! – gsap Oct 28 '10 at 20:05
Does {1,3,0} and {2,2,0} fit the bill? – Nate Eldredge Oct 28 '10 at 20:21
How about {2,4,6,6} and {3,3,4,8}? – Ross Millikan Oct 28 '10 at 20:22
@Nate Eldredge Yes. Thanks! Everybody here successfully ruined my theory :) – gsap Oct 28 '10 at 20:26

Not in general. Knowing the sum and product of a sequence $r_1, ... r_n$ only fixes two coefficients of the polynomial $(x - r_1)...(x - r_n) = x^n + a_{n-1} x^{n-1} + ... + a_0$, namely $a_0$ and $a_{n-1}$, and for $n > 2$ one can choose the other coefficients arbitrarily and solve for the complex roots of the resulting polynomial.

With certain restrictions, this might sometimes be possible, for example if you restrict the sequence to be integers.

-
Thanks for the answer. If we restrict ourselves to integers - it looks like sum and product combination won't be unique. KennyTM provided a nice counterexample above. – gsap Oct 28 '10 at 20:08
@gsap: it can be unique in some situations, e.g. if n = 3 and the product is of three distinct primes which are spaced sufficiently far apart. For a concrete example consider the product 1001 and the sum -9. Another example is if the product is 1. – Qiaochu Yuan Oct 28 '10 at 20:21

Let's say we have a finite tuple (not set) of positive integers, $A = (a_1,a_2,\dotsb,a_n)$, with $\sum a_i = s$, $\prod a_i = p$. Consider the simplest prime factorization $p = p_1^{n_1} \dotsb p_k^{n_k}$ and construct $B = (1,\dotsb,1,p_1,\dotsb,p_1,p_2,\dotsb,p_k,\dotsb,p_k)$ where each $p_i$ occurs $n_i$ times and we fill out with enough $1$s to make $\sum B = s$ (why can we do this?).

Proving that this produces a $B$ with different elements than $A$ in "most" cases is left as an exercise for the reader. As is extending it to the case where $A$ may contain negative integers. In that case you want to fill up with a clever combination of $1$s and $-1$s.

-
the way I interpreted the problem it is at least necessary to require that the length of the sequence is still n. I think the problem is slightly harder this way. – Qiaochu Yuan Oct 28 '10 at 20:37