For a positive integer n greater than 1 , define the s um o f a ll p airs: Soap ( n ) as the sum of all possible pair products, made of distinct integers from 1 to n .
For example, Soap ( 2 ) = ( 1 × 2 ) = 2 Soap ( 3 ) = ( 1 × 2 ) + ( 1 × 3 ) + ( 2 × 3 ) = 1 1
If the arithmetic mean of the products is an integer, then n is defined as "Soapy".
For example,
Are numbers of the form 1 0 k "Soapy", where k ∈ N ?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Note that Soap ( n ) = 1 ≤ a < b ≤ n ∑ a × b = 2 1 a = b 1 ≤ a , b ≤ n ∑ a × b = 2 1 ⎝ ⎛ 1 ≤ a , b ≤ n ∑ a × b − a = b 1 ≤ a , b ≤ n ∑ a × b ⎠ ⎞ = 2 1 ( a = 1 ∑ n a × b = 1 ∑ n b − a = 1 ∑ n a 2 ) = 2 1 ( ( 1 + 2 + 3 + ⋯ + n ) 2 − ( 1 2 + 2 2 + 3 2 + ⋯ + n 2 ) ) = 2 1 ( 4 n 2 ( n + 1 ) 2 − 6 n ( n + 1 ) ( 2 n + 1 ) ) = 2 4 n ( n − 1 ) ( n + 1 ) ( 3 n + 2 ) and the number of pairs is ( 2 n ) = 2 n ( n − 1 ) so the arithmetic mean of the products of pairs is Soap ( n ) × ( 2 n ) − 1 = ( 2 4 n ( n − 1 ) ( n + 1 ) ( 3 n + 2 ) ) × ( n ( n − 1 ) 2 ) = 1 2 ( n + 1 ) ( 3 n + 2 )
Now, n is Soapy if and only if this is an integer, which implies 4 × 1 2 ( n + 1 ) ( 3 n + 2 ) = 3 ( n + 1 ) ( 3 n + 2 ) = ( n + 1 ) 2 − 3 n + 1 is also an integer. That is, we have shown n is Soapy ⟹ n + 1 ≡ 0 ( m o d 3 )
Here, if we let n = 1 0 k , then 1 0 k + 1 ≡ 1 k + 1 = 2 ≡ 0 ( m o d 3 ) so numbers of the form 1 0 k for k ∈ N are never Soapy.
Remark: It wasn't necessary for this problem, but if you look at the formula given for the arithmetic mean, it's not hard to show that the following is a valid definition of being Soapy: n > 1 is an integer ⟹ ( n is Soapy ⟺ n ≡ 2 or 1 1 ( m o d 1 2 ) )
Yes, the remark at the bottom is important if the logic needed to be traced backwards, as 2 and 11 are equal to 2 Mod 3, but so are 5 and 8 which aren't solutions. 1 0 k are always equal to 4 Mod 12. I did it that way.
Also, somewhat interestingly, 2018 is Soapy. This doesn't seem as special once you know that 2 in every 12 numbers are!
Problem Loading...
Note Loading...
Set Loading...
We note that soap ( n ) is defined as follows.
soap ( n ) = j = 1 ∑ n − 1 j k = j + 1 ∑ n k = j = 1 ∑ n − 1 j ( 2 ( n − j ) ( j + 1 + n ) ) = 2 1 j = 1 ∑ n − 1 j ( n 2 − j 2 + n − j ) = 2 1 j = 1 ∑ n − 1 ( ( n 2 + n ) j − j 2 − j 3 ) = 2 1 ( 2 ( n 2 + n ) n ( n − 1 ) − 6 n ( n − 1 ) ( 2 n − 1 ) − 4 n 2 ( n − 1 ) 2 ) = 2 4 n ( n − 1 ) ( 6 n 2 + 6 n − 4 n + 2 − 3 n 2 + 3 n ) = 2 4 n ( n − 1 ) ( 3 n 2 + 5 n + 2 ) = 2 4 n ( n − 1 ) ( n + 1 ) ( 3 n + 2 ) Sum of AP: S = 2 n ( a + l )
We also note that the number of product pairs of soap ( n ) is p ( n ) = T n − 1 = 2 n ( n − 1 ) , where T k is the triangular number. Then we have
p ( n ) soap ( n ) = 1 2 ( n + 1 ) ( 3 n + 2 ) = 1 2 ( 1 0 k + 1 ) ( 3 × 1 0 k + 2 ) For n = 1 0 k
The factor 1 0 k + 1 is always odd and has a sum of digits of 2. Therefore, it is not a multiple of 3. Therefore, for p ( n ) soap ( n ) to be an integer, 3 × 1 0 k + 2 must be divisible by 12. For k = 1 , 3 × 1 0 k + 2 = 3 2 m o d 1 2 = 8 = 0 . The factor is not divisible by 12. For k > 1 , 3 × 1 0 k + 2 m o d 1 2 = 2 = 0 . Therefore 1 0 k is never soapy.