5

This is going to be hard to explain so I'll just give an example

Let's say we have a standard arithmetic sequence that goes up by 1 each time

1, 2, 3, 4, 5, 6, 7, 8, 9, 10

The last number (in this case, 10) is n

Scenario z:

Pick 2 numbers in the sequence and multiply them. The product should be equal to the rest of the numbers added together. For example, 6 and 7 (let's call 6 and 7 x and y for now) are between 1 and 10 and if multiplied together, we get 42. Add 1+2+3+4+5+8+9+10 (don't count the numbers that were multiplied together) and we also get 42.

n can only be an integer, no decimals involved here.

x and y has to be an integer between 0 and and n, and x cannot be equal to y

The question is, is there a mathematical way for figuring out the different numbers that can represent n that satisfies scenario z? And if n does satisfy the given scenario, is there a way to figure out x and y without having to try every possible combination?

$n^2+1$ numbers seems to always work (10, 17, 26, 37 etc), and I have no clue why.

I know I explained this pretty badly, feel free to ask any questions regarding this.

ACB
  • 3,713
fdj13
  • 51

2 Answers2

5

Choose any number $n$, calculate $m = \frac{n(n+1)}{2}+1$. There will be a solution if and only if you are able to factor $m$ as $u\times v$ with $2\le u<v \le n+1$, then the numbers $x$ and $y$ you're looking for are $u-1$ and $v-1$.

The case of $n = k^2+1$ with $k\ge 3$ is always soluble since in that case $m = \frac{n(n+1)}{2}+1 = \frac{(k^2+1)(k^2+2)}{2}+1 = (\frac{k(k+1)}{2}+1)(k^2-k+2)$, so you may take $x = \frac{k(k+1)}{2}$ and $y = k^2-k+1$

jjagmath
  • 18,214
4

$\left(n^2 + n + 2\right) \times \left(n^2 - n + 1\right) = n^4 + 2n^2 - n + 2.$

Therefore

$$\left[\frac{n^4 + 3n^2 + 2}{2} - \frac{n^2 + n}{2}\right] \div \frac{n^2 + n + 2}{2} = (n^2 - n + 1).$$

$$S = \sum_{i=1}^{n^2 + 1} i = \frac{(n^2 + 1)(n^2 + 2)}{2} = \frac{n^4 + 3n^2 + 2}{2}.$$

So, for a particular value of $n$, you take $~\displaystyle y = \sum_{i=1}^n i = \frac{n^2 + n}{2}.$

Then,

$$\frac{S - y}{y+1} = \frac{n^4 + 2n^2 - n + 2}{n^2 + n + 2} = n^2 - n + 1.$$

Taking $n^2 - n + 1 = z$ you have that

$\displaystyle \frac{S - y}{y+1} = z \implies S - y = yz + z \implies S = y + z + yz.$

Note that both $~\displaystyle y = \frac{n^2 + n}{2}$ and $z = (n^2 - n + 1)$

will be elements in $\{1,2,\cdots, (n^2 + 1)\}.$

user2661923
  • 35,619
  • 3
  • 17
  • 39