Putting apples, pears and oranges into a box (combinatorics?)

235 Views Asked by At

Hi I'm not very sure about this question from SMO.

There are 674 apples, 674 oranges and 674 pears to be packed into 2 boxes such that both boxes contain 3 types of fruits and the products of the number of apples, oranges and pears in both boxes are the same. Determine the number of ways that this can be done.

So i just wrote abc=(674-a)(674-b)(674-c) and i tried to expand it out and got abc=337(ab + bc + ac), or something like that. Not really seeing how this is going. Can someone give me a hint on how to start this question at least? Thank you.

2

There are 2 best solutions below

2
On BEST ANSWER

By expanding the given equation you get $$2abc-674(ab+bc+ac)+674^2(a+b+c)-674^3=0$$ Note that there is no reason why $a+b+c$ would equal $674$.

Now after simplifying by $2$ you see that $abc$ is a multiple of $337$, which is a prime number. Therefore at least one of $a$, $b$ and $c$ has to be a multiple of $337$. But it can't be $674$ (or more), since there has to be at least one of each fruit in each box.

Therefore one of the numbers is $337$. Can you take it from here?

1
On

Suppose $a,b,c$ are integers with $0 < a,b,c < 674$.

From the equation $$abc=(674-a)(674-b)(674-c)$$ we get the congruence $$abc \equiv -abc\;(\text{mod}\;674)$$ or equivalently, $$abc \equiv 0\;(\text{mod}\;337)$$ hence, since $337$ is prime, at least one of $a,b,c$ must be divisible by $337$.

Suppose $337{\,\mid\,}c$.

Since $0 < c < 674$, it follows that $c=337$.

Replacing $c$ by $337$, the initial equation reduces to $$ab=(674-a)(674-b)$$ which simplifies to $$a+b=674$$ If $a < b$, we get $336$ pairs $(a,b)$, and $336$ triples $(a,b,337)$.

Noting that for these triples, all $6$ permutations are distinct, we need to multiply the count by $6$, so we get $(6)(336)=2016$ qualifying triples.

Finally, we need to include the triple $(337,337,337)$, so the final count is $2016+1 = 2017$.