AMC 10 Step by Step

2021 AMC Fall 10B Problem 22

P21-25~8 minPrint

For each integer n≥2n\geq 2 , let SnS_n be the sum of all products jkjk , where jj and kk are integers and 1≤j<k≤n1\leq j<k\leq n . What is the sum of the 10 least values of nn such that SnS_n is divisible by 33 ?

Log in to save your progress.
Show solution without answering

Key insight

Squaring 1 + 2 + ... + n gives each product twice, leading to a formula with 24 on the bottom. So the top needs a factor of 9.

Solution

Small case first. For n=3n = 3 the products are 1×21 \times 2, 1×31 \times 3, 2×32 \times 3, so S3=2+3+6=11S_3 = 2 + 3 + 6 = 11. Now square the sum 1+2+3=61 + 2 + 3 = 6:
(1+2+3)2=12+22+32+2(1×2+1×3+2×3)=14+2×11=36.(1 + 2 + 3)^2 = 1^2 + 2^2 + 3^2 + 2(1 \times 2 + 1 \times 3 + 2 \times 3) = 14 + 2 \times 11 = 36.
Squaring the sum gives each square once and each product twice. That is the key to a formula.

1. Formula. In general,
Sn=(1+2+⋯+n)2−(12+22+⋯+n2)2.S_n = \frac{(1 + 2 + \cdots + n)^2 - (1^2 + 2^2 + \cdots + n^2)}{2}.
Using 1+⋯+n=n(n+1)21 + \cdots + n = \frac{n(n+1)}{2} and 12+⋯+n2=n(n+1)(2n+1)61^2 + \cdots + n^2 = \frac{n(n+1)(2n+1)}{6}, then pulling out the common factor n(n+1)24\frac{n(n+1)}{24}:
Sn=n(n+1)24[3n(n+1)−2(2n+1)]=n(n+1)(3n2−n−2)24=(n−1) n (n+1) (3n+2)24.S_n = \frac{n(n+1)}{24}\bigl[3n(n+1) - 2(2n+1)\bigr] = \frac{n(n+1)(3n^2 - n - 2)}{24} = \frac{(n-1)\,n\,(n+1)\,(3n+2)}{24}.
Check with n=3n = 3: 2×3×4×1124=11\frac{2 \times 3 \times 4 \times 11}{24} = 11. Good.
2. When is SnS_n a multiple of 3? The bottom is 24=8×324 = 8 \times 3. For SnS_n to still have a factor of 33 after dividing, the top needs two factors of 33, that is, it must be a multiple of 99.
3. Where can the factors of 3 come from? Not from 3n+23n + 2: it always leaves remainder 22 when divided by 33. So (n−1)×n×(n+1)(n-1) \times n \times (n+1) must be a multiple of 99. Among three numbers in a row, exactly one is a multiple of 33, so that one must be a multiple of 99.
4. So one of n−1n - 1, nn, n+1n + 1 is a multiple of 99. In other words, nn is one less than a multiple of 99, a multiple of 99, or one more than a multiple of 99. Listing from the smallest (nn starts at 22):
8,9,10,17,18,19,26,27,28,35.8, 9, 10,\quad 17, 18, 19,\quad 26, 27, 28,\quad 35.
5. Add them. Each group of three adds to three times its middle number: 27+54+81+35=19727 + 54 + 81 + 35 = 197.

The answer is (B) 197\boxed{\textbf{(B)}\ 197}.

Why this works

"Add up all products of two different numbers from a list" always equals (sum squared minus sum of squares) divided by 22. After that, the problem is about factors of 33. The subtle point is that a 33 on the bottom of the fraction raises the bar: the top needs a factor of 99, not just 33.

Alternative approach

Build SnS_n one step at a time and track only the remainder when dividing by 33. Going from n−1n - 1 to nn adds the new products 1×n,2×n,…,(n−1)×n1 \times n, 2 \times n, \ldots, (n-1) \times n, which total n×(n−1)n2n \times \frac{(n-1)n}{2}.

nn2345678910111213
SnS_n21135851753225468701320192527173731
remainder222111000222

The remainders repeat every 99 steps, with 00 at n=8,9,10n = 8, 9, 10, then 17,18,1917, 18, 19, and so on. This matches the list above.

Concise solution

A shorter write-up, the way contest solutions are usually written. It may take a different route from the solution above.

Expanding (1+2+⋯+n)2(1 + 2 + \cdots + n)^2 gives every j2j^2 once and every product jkjk with j≠kj \ne k twice, so
Sn=(1+⋯+n)2−(12+⋯+n2)2=12[n2(n+1)24−n(n+1)(2n+1)6].S_n = \frac{(1 + \cdots + n)^2 - (1^2 + \cdots + n^2)}{2} = \frac12\left[\frac{n^2(n+1)^2}{4} - \frac{n(n+1)(2n+1)}{6}\right].
Factor out n(n+1)12\frac{n(n+1)}{12} inside the bracket: n(n+1)12[3n(n+1)−2(2n+1)]=n(n+1)(3n2−n−2)12\frac{n(n+1)}{12}\left[3n(n+1) - 2(2n+1)\right] = \frac{n(n+1)(3n^2 - n - 2)}{12}, and 3n2−n−2=(n−1)(3n+2)3n^2 - n - 2 = (n-1)(3n+2). Hence
Sn=(n−1) n (n+1) (3n+2)24.S_n = \frac{(n-1)\,n\,(n+1)\,(3n+2)}{24}.

Since 24=8⋅324 = 8 \cdot 3, SnS_n is divisible by 33 exactly when the numerator is divisible by 99. The factor 3n+23n + 2 is never a multiple of 33, so we need 9∣(n−1)n(n+1)9 \mid (n-1)n(n+1). At most one of three consecutive integers is a multiple of 33, so one of them must be a multiple of 99: n≡0,1,n \equiv 0, 1, or 8(mod9)8 \pmod 9.

The ten smallest such n≥2n \ge 2 are 8,9,10,17,18,19,26,27,28,358, 9, 10, 17, 18, 19, 26, 27, 28, 35, with sum
27+54+81+35=197.27 + 54 + 81 + 35 = 197.

The answer is (B) 197\boxed{\textbf{(B)}\ 197}.

Review in the AoPS books

Similar problems

Problem © Mathematical Association of America (MAA), American Mathematics Competitions. Reproduced for non-commercial educational use. Solution and commentary are original to this site.