# 1997 AHSME Problems/Problem 28

## Problem

How many ordered triples of integers $(a,b,c)$ satisfy $|a+b|+c = 19$ and $ab+|c| = 97$? $\textbf{(A)}\ 0\qquad\textbf{(B)}\ 4\qquad\textbf{(C)}\ 6\qquad\textbf{(D)}\ 10\qquad\textbf{(E)}\ 12$

## Solution

WLOG, let $a \ge 0$, and let $a \ge b$. We can say this because if we have one solution $(a,b) = (a_0, b_0)$ with $a_0 \ge 0$ and $a_0 > b_0$, we really have the four solutions $(a_0, b_0), (-a_0, -b_0), (b_0, a_0), (-b_0, -a_0)$ by the symmetry of the original problem.

Furthermore, we assert that these four solutions are distinct. We can say that $a > b$, since if $a=b$, we have $c = 19 - 2a$ for the first equation and either $c = 97 - a^2$ or $c = a^2 - 97$ for the second equation. Equating $19 - 2a = 97 - a^2$ gives no integer solution, while equating $19 - 2a = a^2 - 97$ also gives no integer solution.

Thus, we can now assume WLOG that $a \ge 0$ and $a > b$, and each pair of $(a_0,b_0)$ that we get will generate four unique solutions: $(a_0, b_0), (b_0, a_0), (-a_0, -b_0), (-b_0, -a_0)$.

We now divide the problem into $c \ge 0$ and $c < 0$:

If $c \ge 0$, we have $|a + b| + c = 19$ and $ab + c = 97$.

Solving both equations for $c$ and equating them, we get that $ab - |a + b| = 78$. Splitting these up, we find that either $ab - a - b = 78$ or $ab + a+ b = 78$. Factoring both with SFFT gives $(a-1)(b-1) = 79$ or $(a +1)(b+1) = 79$. We factor with the restrctions that $a \ge 0$ and $a > b$. Since $79$ is prime, we have: $a - 1 = 79$ and $b - 1 = 1$, which leads to $(80,2)$. $a + 1 = 79$ and $b + 1 = 1$, which leads to $(78, 0)$.

Each of those solutions could generate $3$ more solutions, giving a total of $8$ potential solutions. However, in each the first set of four solutions, we have $|a + b| = 82$, which from the original first equation $|a + b| + c = 19$ gives $c = 19 - 82$, which contradicts our initial assumption that $c\ge 0$. Similarly, for the second set of four solutions, we have $|a + b| = 78$, which leads to $c = 19 - 78$, also contradicting $c \ge 0$.

If $c < 0$, we have $|a + b| + c = 19$ and $ab - c = 97$. We note that $19 - c$ must be positive whenever $c$ is negative, and thus $|a + b| = a + b$.

Solving both equations for $c$ and using SFFT as above gives $(a+1)(b+1) = 117$. Since $117 = 3^2\cdot 13$, we factor with the restriction that $a\ge 0$ and $a > b$. Thus, we can let $a+1 \in \{117, 39, 13\}$, which means $a \in \{116, 38, 12\}$. These give corresponding $b+1\in \{1, 3, 9\}$, which leads to corresponding $b \in \{0, 2, 8\}$. Combining the solutions, we have $(a,b) = (116, 0), (38, 2), (12, 8)$.

Each of these three solutions permutes, negates, and permute-negates into $4$ solutions as described in the start of the solution, for a total of $12$ solutions.

Checking our solutions to ensure $c < 0$, we find in the first set of four solutions, $|a + b| = 116$, and thus $c = 19 - 116$, which is indeed negative.

In the second set of four solutions, $|a + b| = 40$, which leads to $c = 19 - 40$, which is also negative.

Finally, in the third set of four solutoins, $|a + b| = 20$, which leads to $c = 19 - 20$, which is negative.

Thus, there are $12$ ordered triples, and the answer is $\boxed{E}$.

The problems on this page are copyrighted by the Mathematical Association of America's American Mathematics Competitions. 