Problem: A sequence {an} of real numbers is defined by a1=1 and for all integers n≥1, an+1=n2+n+2an2ann2+n Compute the sum of all positive integers n<1000 for which an is a rational number.
Solution
Solution: First, note that for k≥1, ak+12=k(k+1)+2ak2k(k+1)ak2⟺ak+121−ak21=k(k+1)2=k2−k+12 and summing the second equation from k=1 to k=n−1 with n≥2, we get an21−a121=k=1∑n−1(ak+121−ak21)=k=1∑n−1(k2−k+12)=2−n2 Since a1=1, we see that an21=3−n2⟺an=3n−2n for all integers n≥1 and we wish to find the sum of all positive integers n<1000 such that 3n−2n is a square of some rational number. To help us look for such integers n, we use the following lemma that provides integer solutions to the generalized Pell equation.
Lemma. 1 Let d be a squarefree positive integer, and let a and b be positive integers such that a2−db2=1. Set u=a+bd. Then for each nonzero integer n, every solution of x2−dy2=n is a power of u times x+yd where (x,y) is an integer solution of x2−dy2=n with ∣x∣≤∣n∣(u+1)/2 and ∣y∣≤∣n∣(u+1)/(2d).
We now let g=gcd(n,3n−2). Then g∈{1,2} since g∣3n−(3n−2)=2. We now consider the following cases:
- Suppose g=1. Then n=y2 and 3n−2=x2 for some relatively prime positive integers x and y. This leads us to the generalized Pell equation x2−3y2=−2. Set u=2+3, with (2,1) being a solution of x2−3y2=1 in positive integers. We now look for the positive integer solutions (x,y) of x2−3y2=−2 with x≤2(u+1)/2≈2.07 and y≤2(u+1)/(23)≈1.2. We obtain (x,y)=(1,1) as the only such integer solution, so by the above lemma, we see that all positive integer solutions (xk,yk) of x2−3y2=−2 are given by xk+yk3=(1+3)(2+3)k for all integers k≥0. We now compute this product for small values of k :
k
0
1
2
3
xk+yk3
1+3
5+33
19+113
71+413
As n<1000, we require that yk≤31, so the positive integer solutions (xk,yk) of x2−3y2= -2 with yk≤31 are (xk,yk)=(1,1),(5,3),(19,11) (which indeed have relatively prime coordinates). These correspond to the values of n:n=1,9,121.
- Suppose g=2. Then n=2y2 and 3n−2=2x2 for some relatively prime positive integers x and y. This leads us to the generalized Pell equation x2−3y2=−1. Again, we set u=2+3. We now look for the positive integer solutions (x,y) of x2−3y2=−1 with x≤(u+1)/2≈1.47 and y≤(u+1)/(23)≈0.85. It turns out that there are no such solutions on these bounds, so by the above lemma, we conclude that x2−3y2=−1 has no solutions in positive integers.
Hence, the only positive integers n<1000 for which an is a rational number are n=1,9,121 and the sum is 1+9+121=131.
[^0]: 1 For proof, see Theorem 3.3 from https://kconrad.math.uconn.edu/blurbs/ugradnumthy/pelleqn2.pdf.
Want a route through all this instead of an archive? The track
puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.
Source: MathNet,
licensed CC-BY-4.0.
Statement reproduced verbatim; metadata (topic, difficulty) added by this project.