If a is an element in the set { 2 , 3 , 4 , … , 9 9 9 9 } , there are two values that a can take such that a 2 − a is divisible by 10000. Find the absolute difference between these two values.
As a bonus, can you find the number of such values of a for a general set { 2 , 3 , … , ( n 2 − 1 ) } , for any positive integer n ?
Note that I do not know the answer to the bonus question. I made a mistake in the exam hall.
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.
In the exam, they asked to justify or prove (I can't remember which) that the function gives the number of such values of a in the general set. And they asked to represent it in terms of n. But that isn't possible, is it?
I don't know CRT, but I'm going to read up on that. Thank you for the solution!
I tried to write a proof (technically it isn't much of a proof maybe) of your general result in the comments of OP's solution below (although I guess it isn't much rigorous). Would you be kind enough to verify it for me?
For 1 0 0 0 0 ∣ ( a 2 − a ) ⇒ 2 4 5 4 ∣ [ a ( a − 1 ) ] .
We note that a ( a − 1 ) is a product of two consecutive integers, one odd and the other even. The smallest possible odd integer would be 5 4 = 6 2 5 , and we note that 2 4 ∣ ( 6 2 5 − 1 ) = 1 6 ∣ 6 2 4 . Therefore, the first a 1 = 6 2 5 .
The following a s must be around odd multiple of 6 2 5 . Since 6 2 4 ≡ 0 ( m o d 1 6 ) , a 2 is around 1 5 × 6 2 5 because 1 5 × 6 2 5 = 1 5 ( 6 2 4 + 1 ) ≡ 1 5 ( m o d 1 6 ) ⇒ a 2 = 1 5 ( 6 2 5 ) + 1 = 9 3 7 6 .
⇒ a 2 − a 1 = 9 3 7 6 − 6 2 5 = 8 7 5 1
We note that a 3 is around 1 7 ( 6 2 5 ) = 1 7 ( 6 2 4 + 1 ) ≡ 1 ( m o d 1 6 ) ⇒ a 3 = 1 7 ( 6 2 5 ) .
Therefore,
a 1 = a 2 = a 3 = a 4 = a 5 = . . . 1 × 6 2 5 1 5 × 6 2 5 + 1 1 7 × 6 2 5 3 1 × 6 2 5 + 1 3 3 × 6 2 5 ⇒ a k = ⎩ ⎪ ⎨ ⎪ ⎧ [ 1 6 ( k − 1 ) + 1 ] × 6 2 5 [ 1 6 ( k − 1 ) + 1 ] × 6 2 5 + 1 if k is odd if k is even
Therefore, for n ≥ 9 3 7 5 the number k of such a is given by:
k = ⎢ ⎢ ⎢ ⎡ 1 6 ⌊ 6 2 5 n ⌋ ⎥ ⎥ ⎥ ⎤ + 1
Is there such a formula for a general set {2,3,4... n 2 − 1 }?
What's so special about numbers / a's greater than 10000? If you're going beyond the given set, even multiples of 625 or rather multiples of 16 and 625, i.e, 10000, should also be considered.
Log in to reply
Yes, you are right. Let me look at it again. I am using other solution to solve this one. Sorry.
Here's how I did it:
Through some reasoning, you can arrive at the conclusion that a has to end in either 5 or 6.
If a ends in 5, then a-1 ends in 4 and the factor of 16 lies entirely with a-1 and the factor of 625 lies entirely with a. And vice versa for the case when a ends in 6.
So we only need to hunt for odd multiples of 625. We find that 625 and 9376 are the two values of a by trial and error. So the difference is 8751.
There's an easier way to solve it and I know that. But this is how I did it in the exam hall. So please post a solution to this with the general case.
Well, this is a very nice coincidence. I answered this question just today about 6-7 hours ago on Math Stack Exchange. Didn't know that it was a CMI question though. It seems too easy to be a CMI question. Anyway, here 's the link to my answer there. Feel free to check it out, and maybe upvote it there too. :P
Log in to reply
Ya that guy also wrote the same test.
Do you know of any general method/formula for the bonus question set? I thought that because the formula would give a function of n through which the distribution of primes can be made out. Cause it would take value 0 whenever n is a prime.
Log in to reply
The problem can be generalized by considering the unique prime factorization of n but I can guarantee that it won't be pretty. One thing that can be observed is that the number of solutions probably increases with increase in prime factors of n . I'm saying that using pure intuition and no written work, so I might be wrong.
Log in to reply
@Prasun Biswas – What do you mean by number of solutions? Number of values of a? But should such a function of n exist, it will take the value 0 whenever n is a prime number, right? So won't you get a distribution of primes? If it's a polynomial, then it will have infinite real roots then.
Log in to reply
@Vishnu C – Yes, I'm talking about the number of values of a . But my thinking consists no polynomials in it for this problem. I'm thinking of a purely number-theoretic approach. Although, I'm unsure whether this is correct or not.
Consider the unique prime factorization of n , i.e., n = i = 1 ∏ q p i a i where p i 's are primes and a i 's are some positive integers corresponding to the value of n . So, n has q primes in its U.P.F. Now, we would have,
a ( a − 1 ) ≡ 0 ( m o d n ) ⟹ a ( a − 1 ) ≡ 0 ( m o d i = 1 ∏ q p i a i )
Since a and ( a − 1 ) are consecutive integers, they must be coprime (easily provable by Euclidean Algorithm). Our required modular congruences for solutions will be of the following form:
{ a ≡ 0 ( m o d x ) a ≡ 1 ( m o d y ) s.t. g cd ( x , y ) = 1 ∧ x y = n
This rules out the two separate congruence results a ≡ 0 ( m o d n ) and a ≡ 1 ( m o d n ) which don't give us solutions within given range { i } i = 2 i = ( n − 1 ) .
All the rest of the congruencies obviously gives us solutions and the number of the rest of congruences is simply the number of distinct products of primes possible (the primes being in the U.P.F of n ) excluding the two results that we said doesn't give us solutions. So, our number of solutions are:
n = 1 ∑ q − 1 ( n q ) = 2 q − 2 = 2 ( 2 q − 1 − 1 )
Hence, if n has q primes in its unique prime factorization, the number of values of a that are possible solutions in the given set is 2 ( 2 q − 1 − 1 ) . Note that it is ensured that we aren't counting the same solution more than once since each congruence system possible gives a unique solution guaranteed by CRT.
EDIT: I just noticed Patrick Corn's solution. His general solution agrees with mine, so the answer must be correct.
Log in to reply
@Prasun Biswas – Yes, the total number of congruences (including the two that lead to the "trivial" solutions) should be 2 q because each prime power is divisible by exactly one of a and a − 1 . There are q prime powers and 2 choices for which one it divides. (Of course your explanation is correct too.)
@Prasun Biswas – Your solution is in terms of the number of prime factors of n and not in terms of n. The question in CMI's paper asked for a function of n that can do this number of a counting.
@Prasun Biswas – I didn't understand most of your solution. But I'll come back to it as soon as I finish reading up on CRT.
Thanks for posting a solution!
Problem Loading...
Note Loading...
Set Loading...
This is just an application of the Chinese Remainder Theorem. We have 2 4 ⋅ 5 4 ∣ a ( a − 1 ) , and since a and a − 1 are relatively prime, there are four cases: 2 4 and 5 4 divide a , 2 4 and 5 4 divide a − 1 , 2 4 ∣ a and 5 4 ∣ a − 1 , and 2 4 ∣ a − 1 and 5 4 ∣ a .
The first two cases give a ≡ 0 and a ≡ 1 mod 1 0 0 0 0 , so there are no solutions in the given set, and the second two cases give a ≡ 9 3 7 6 and a ≡ 6 2 5 respectively via the Chinese Remainder Theorem (e.g. a ≡ 0 mod 1 6 and a ≡ 1 mod 6 2 5 if and only if a ≡ 9 3 7 6 mod 1 0 0 0 0 ).
For a general n the answer will depend on the number of primes dividing n . If there are k distinct primes dividing n , there will be 2 k − 2 such values of a (we subtract 2 because we are always excluding the solutions 0 and 1 ). The easiest way to see this is probably to ape the above argument in the case when n is divisible by three primes, and see how many possibilities there are. One can write out a proof, but it would be more illuminating to play with a couple of examples to see why this statement is true.