Difference between revisions of "2004 OIM Problems/Problem 4"

(Created page with "== Problem == Find all pairs <math>(a, b)</math>, where <math>a</math> and <math>b</math> are positive integers of two digits each, such that <math>100a + b</math> and <math>2...")
 
(solution)
 
Line 5: Line 5:
  
 
== Solution ==
 
== Solution ==
{{solution}}
+
Let <math>100a+b=x^2</math> and <math>201a+b=y^2</math>; then, by subtracting, <math>y^2-x^2=101a</math>, so <math>(y+x)(y-x)=101a</math>. Notice that since <math>x^2</math> and <math>y^2</math> are four-digit, <math>x^2,y^2<10000</math>, so <math>x,y<100</math>. Thus <math>x+y<200</math>.
 +
 
 +
Clearly <math>y>x</math>, so both <math>y+x</math> and <math>y-x</math> are positive; however, as <math>y-x</math> cannot equal <math>101</math> due to <math>x,y<100</math>, we must have <math>101|(y+x)</math>. Since <math>x+y\ne0</math> and <math>x+y<200<202</math>, it is necessary that <math>x+y=101</math>. Then <math>y-x=a</math>. Solving for <math>x</math> and <math>y</math> results in
 +
<cmath>x=\frac{101-a}{2},y=\frac{101+a}{2}</cmath>
 +
Substituting back in:
 +
<cmath>100a+b=\left(\frac{101-a}{2}\right)^2</cmath>
 +
<cmath>201a+b=\left(\frac{101+a}{2}\right)^2</cmath>
 +
From the second equation, rearranging yields
 +
<cmath>a^2-602a+101^2-4b=0</cmath>
 +
Using the [[Quadratic Formula]]:
 +
\begin{align*}
 +
a&=\frac{602\pm\sqrt{602^2-4(101^2-4b)}}{2}\
 +
&=\frac{602\pm2\sqrt{301^2-(101^2-4b)}}{2}\
 +
&=\frac{602\pm2\sqrt{4b+301^2-101^2}}{2}\
 +
&=\frac{602\pm2\sqrt{4b+402\cdot200}}{2}\
 +
&=\frac{602\pm4\sqrt{b+402\cdot50}}{2}\
 +
&=\frac{602\pm4\sqrt{b+20100}}{2}\
 +
\end{align*}
 +
Clearly <math>b+20100</math> must be a perfect square, and the only perfect square that allows <math>b</math> to have two digits is <math>142^2=20164</math>. Thus <math>b=64</math>, and:
 +
\begin{align*}
 +
a&=\frac{602\pm4\sqrt{b+20100}}{2}\
 +
&=\frac{602\pm4\cdot142}{2}\
 +
&=\frac{602\pm568}{2}\
 +
&=\frac{602-568}{2}\
 +
&=\frac{34}{2}\
 +
&=17\
 +
\end{align*}
 +
Thus the only solution is <math>(a,b)=\boxed{(17,64)}</math>, which works (testing yields the two squares <math>42^2=1764</math> and <math>59^2=3481</math>).
 +
 
 +
~ [https://artofproblemsolving.com/wiki/index.php/User:Eevee9406 eevee9406]
  
 
== See also ==
 
== See also ==
 
[[OIM Problems and Solutions]]
 
[[OIM Problems and Solutions]]

Latest revision as of 22:53, 25 March 2025

Problem

Find all pairs $(a, b)$, where $a$ and $b$ are positive integers of two digits each, such that $100a + b$ and $201a + b$ are four-digit perfect squares.

~translated into English by Tomas Diaz. ~orders@tomasdiaz.com

Solution

Let $100a+b=x^2$ and $201a+b=y^2$; then, by subtracting, $y^2-x^2=101a$, so $(y+x)(y-x)=101a$. Notice that since $x^2$ and $y^2$ are four-digit, $x^2,y^2<10000$, so $x,y<100$. Thus $x+y<200$.

Clearly $y>x$, so both $y+x$ and $y-x$ are positive; however, as $y-x$ cannot equal $101$ due to $x,y<100$, we must have $101|(y+x)$. Since $x+y\ne0$ and $x+y<200<202$, it is necessary that $x+y=101$. Then $y-x=a$. Solving for $x$ and $y$ results in \[x=\frac{101-a}{2},y=\frac{101+a}{2}\] Substituting back in: \[100a+b=\left(\frac{101-a}{2}\right)^2\] \[201a+b=\left(\frac{101+a}{2}\right)^2\] From the second equation, rearranging yields \[a^2-602a+101^2-4b=0\] Using the Quadratic Formula: a=602±60224(10124b)2=602±23012(10124b)2=602±24b+301210122=602±24b+4022002=602±4b+402502=602±4b+201002 Clearly $b+20100$ must be a perfect square, and the only perfect square that allows $b$ to have two digits is $142^2=20164$. Thus $b=64$, and: a=602±4b+201002=602±41422=602±5682=6025682=342=17 Thus the only solution is $(a,b)=\boxed{(17,64)}$, which works (testing yields the two squares $42^2=1764$ and $59^2=3481$).

~ eevee9406

See also

OIM Problems and Solutions