Solution:
Concept: Use the identities (a+b)2=a2+2ab+b2 and (a−b)2=a2−2ab+b2, or multiply out the brackets term by term. The x2 terms cancel, so the equation that is left is linear.
Step 1 — Expand the squares.
We use (a−b)2=a2−2ab+b2 and (a+b)2=a2+2ab+b2.
(x−5)2=x2−10x+25
(x+2)2=x2+4x+4
Step 2 — Subtract.
The minus sign in front of the second square changes the sign of all three of its terms, and the x2 terms cancel.
x2−10x+25−x2−4x−4−14x+21=−2=−2
Step 3 — Solve.
We move 21 to the right side and then divide both sides by −14.
−14x−14xx=−2−21=−23=1423
Step 4 — Check.
We put x=1423 into the left side.
(1423−5)2−(1423+2)2=1962209−1962601=−196392=−2
Watch out: −(x+2)2 is −x2−4x−4; the minus sign changes the sign of every term.
Therefore, x=1423 (or 1149).