Tuesday, July 27, 2021

2021/056) Let S(n) be the sum of digits of a number. Find the number of 3 digits numbers whose $S(S(n)) = 2$

Sum of all the digits of a 3 digit number that is $S(n)$  shall be between 1 and 27.

because $(S(n)) = 2 $ and $S(n)$ is between 1 and 27 so we have $(n) \in \{ 2,11,20\}$ 

Now the number of 2 digit numbers(with leading zero)  sum = n is n+1 for n $<=9$

This is so because 1st digit can be 0 to n and 2nd digit can be 2-n ( n = 0 or 1) or 11 -n ( n= 2 to 9)

The number of 1/2 digit numbers sum = n is 19-n for 9 < n < 19 is 19-n. 

This is so because the 1st digit can go from  n -9 to 9 or 9-(n-9) 

One digit number is allowed ( that is 2 digit number with leading zero)  because we are considering the tens digit of the 3 digit number that can be zero.

Now we shall use the above 2 do the counting

The 3 digit numbers that have sum 3 are 101,110,200 that is 3 numbers

let us count the number of 3 digit that have a sum 11

1st digit is 1 so sum of other 2 digit 10 so number of numbers = 19-10 = 9

1st digit is 2 to 9  so sum of other 2 digit 9 down to 2  number of numbers = $10 + 9 + \cdots 3 = \frac{(10 + 3)*8}{2} = 52$


So the number of numbers that have sum 11 is 9 + 52 = 61


let us count the number of 3 digit that have a sum 20


1st digit can be from 2 to 9 and that shall give the sum of other 2 digits of the number can be from 18 down to 11. the number of numbers can be 19-k with k from 18 to 11


so the sum = $1+2 + \cdots 8 = \frac{8 * 9}{2} = 36$


So total number of numbers with sum 20 = 36


So total number of numbers  = 3 + 61+ 36 = 100

 

Sunday, July 25, 2021

2021/055) How many divisors of the number $30^{2003}$ are not divisor of $20^{2000}$?

 Let us factorise $30^{2003}$ and $20^{2000}$

$30^{2003}= 3^{2003} * 2 ^{2003} * 5^{2003}$

as 2,3,5 are pairwise co-primes and in factor each can come 0 to 2003 times that is 2004 ways 

so number of factors = $(2003+1) * (2003 + 1) * (2003 +1)= 2004^3$

Now

$20^{2000}= 2^{2000} * (2 * 5) ^{2000}= 2^ {4000} * 5^{2000}$

$GCD(30^{2003},20^{2000}) = 2^{2003} * 5 ^{2000}$

Any number that divides $30^{2003}$ and $20^{2000}$  must divide $GCD(30^{2003},20^{2000})$

So number of numbers that divide $30^{2003}$ and $20^{2000}$ = $(2003+1)(2000+1) = 2004 * 2001$

So number of numbers that divide $30^{2003}$ and does not divide $20^{2000}$ = $2004^3 - 2004 * 2001 = 2004(2004^2-2021) = 8044086060$ 

8044086060 is the number of divisors of $30^{2003}$ that are not divisor of  $20^{2000}$ 

Friday, July 23, 2021

2021/054)Find all integer solutions of the equation $\lfloor \frac{x}{1!}\rfloor + \lfloor \frac{x}{2!}\rfloor +\cdots + \lfloor \frac{x}{10!}\rfloor = 1001$

 Let us define

$f(x) =  \lfloor \frac{x}{1!}\rfloor + \lfloor \frac{x}{2!}\rfloor +\cdots + \lfloor \frac{x}{10!}\rfloor $

So we have 

$f(x) > \lfloor \frac{x}{1!}\rfloor $ for $x>=2$

as $f(x) = 1001$ so 

$x < 1001$

As $7!>1000$ so we have   $\lfloor \frac{x}{n!}\rfloor =0 $ for $x< 1000$ and $n>6$

Further 

$f(kn!+i)= kf(n!) + f(i)\cdots(1)$ for k = 1 to n and i is less than n!

This is so because for m < n 

$\lfloor \frac{kn!+l}{m!} \rfloor =  \lfloor\frac{kn!}{m!}\rfloor  + \lfloor \frac{l}{m!} \rfloor $  

additionally  

$f(kn!+i)= f(kn!) + f(i)\cdots(2)$ for any $k$ and $ i \le n!\cdots(2)$

and $f((n+1)!) = (n+1)f(n!) + 1$

to use the facts let us calculate f(k!) for k = 1 to 6.

f(1) = 1, f(2) = 3, f(6) = 10, f(24) = 41, f(120) = 206

and f(720) = 1237

so the value of  x is less than 720 so let us look at next lowest factorial that is 120

f(120) = 206

$\lfloor \frac{1000}{206}\rfloor = 4$ 

using (1) $f(120*4) = 206 * 4 = 824$

Or f(480) =  824

So we have to account for 1001 - 824 = 177

now f(24) = 41  

$\lfloor \frac{177}{41}\rfloor = 4$ 

so we f(96) = 41 * 4 = 164 

so $f(576) = f(480+96) = f(120 * 4 + 96)

= f(480) + f(96) = 824 + 164 = 988$

Now we have to account for remaining 13 and f(3!) = f(6) = 10

so 6 goes one more time and we ahve

$f(582) = f(576 + 6) = f(24 * 24 + 6) = f(576) + f(6) = 988 + 10 = 998$ using (2)

now we need to account for 3 and as f(2!) = f(2) =3 so we get

E$f(584) = f(582+2) = f(97 * 6) + 2 = f(682) + f(2) = 988 + 3 = 1001$      

so x = 584

Wednesday, July 21, 2021

2021/053) Prove that $n^{n-1}-1$ is divisible by $(n-1)^2$ for integer n

Replacing n by k+ 1 we need to prove

$(k+1)^k-1$ is divisible by $k^2$

If k is less than 2 it is obvious so let us check for k greater than 2

We have $(k+1)^k - 1 =\sum_{n=0}^k {k \choose n} k^n - 1$

$= 1 + k . k + \sum_{n=2}^k {k \choose n} k^n -1 $

$ =  k . k + \sum_{n=2}^k {k \choose n} k^n$

Each term is divisible by $k^2$ and hence the expression 

Saturday, July 10, 2021

2021/052) Let f(x) be a polynomial in x with integer coefficients and suppose that for 5 distinct integers $a_1,a_2,a_3,a_4,a_5$ one has $f(a_1)= f(a_2)= f(a-3) = f(a_4) = f(a_5) = 2 $ Show that there is no integer b such that $f(b) = 9$

Because  $f(a_1)= f(a_2)= f(a-3) = f(a_4) = f(a_5) = 2 $


So defining  $g(x) = f(x) - 2$  


We get $g(a_1)= g(a_2)= g(a-3) = g(a_4) = g(a_5) = 0 $


So $g(x) =  (x-a_1)(x-a_2)(x-a_3)x-a_4)(x-a_5)h(x)$ for some function h(x) of x


So g(x) is product of atleast 5 different numbers 


Because $f(b) = 9$ so $g(b) = 7$ 


For g(x) to be 7 at some b 7 should be product of 5 different numbers but is is not product of have at least 5 different factors but 7  has at most 3(as -7 * -1 * 1) so it is not possible for any b such that $g(b) = 7$ or $f(b)  = 9$


Wednesday, July 7, 2021

2021/051) Prove that $\frac{5^{125}-1}{5^{25}-1}$ is a composite number

Let $f(x) = x^4 + x^3 + x^2 + x+ 1$
\
we get $f(x) = (x^2 + 1)^2 + x^3 - x^2 + x$

$= (x^3 + 3x + 1)^2 - 2* 3x(x^2+1) - 9x^2 + x^3 - x^2 + x$

$= (x^2 + 3x + 1) ^2 - (5x^3 + 10x^2 + 5x)$

$= (x^2 + 3x +1^2 - 5x(x+1)^2$

$\frac{5^{125}-1}{5^{25}-1} = f(5^{25})$

$f(5^{25}) =  (5^{50} + 3 * 5^{25} +1)^2 - 5 * 5^{25}(5^{25}+1)^2$

$= (5^{50} + 3 * 5^{25} +1)^2 - (5^{13}(5^{25}+1))^2$

$= (5^{50} + 3 * 5^{25} +1 + (5^{13}(5^{25}+1))(5^{50} + 3 * 5^{25} +1 - (5^{13}(5^{25}+1))$

product of 2 numbers neither is 1 so composite 

Monday, July 5, 2021

2021/050) Solve the equation $4x^6-6x^2 + 2\sqrt{2}=0$

Because it has $x^6$ and $x^2$ term we feel that it could be transformed to a trigonometric equation By  putting $x^2=a\cos\,y$

We get $4a^3\cos^3y - 6a\cos\,y + 2\sqrt{2}=0$

Comparing with $4cos^3z - 3\cos\,z$ the coefficients being proportional we get

$\frac{4a^3}{4}= \frac{6a}{3}$ or $a =\sqrt{2}$

Putting $x^2=\sqrt{2}\cos\,y$

we get $4 * 2 \sqrt{2}\cos^3 y - 6\sqrt{2} \cos\,y + 2\sqrt{2} = 0$

or  $4 \sqrt{2}\cos^3 y - 3 \cos\,y + 1 = 0$

or $\cos\,3y = -1 =\cos\, \pi$

so 3 solutions $3y = \pi$ or $3y= 3\pi$ or $3y = 5\pi$

or $x^2 = \sqrt{2} \cos\,\frac{\pi}{3}$   or  $x^2 = \sqrt{2} \cos\,\pi$ or  $x^2 = \sqrt{2} \cos\,\frac{5\pi}{3}$

giving solution $ x = \pm \frac{1}{\sqrt[4]{2}}$(double roots)  or $x= \pm  \sqrt[4]{2}i$

Alternative solution

because there is a $\sqrt{2}$ term and $x^2$ and $x^6$ so we can get rid of $\sqrt{2}$ by putting $x = a \sqrt{2}$ to give

$8a^3\sqrt{2} - 6a\sqrt{2} + 2 \sqrt{2} = 0$

or $8a^3-6a+2= 0$

or $4a^3-3a+1 = 0$

by inspection we get a = -1 is a solution so $a+1$ us a factor

we get $4a^3 - 3a + 1 = 4a^2(a+1) - 4a^2 - 3a + 1 = 4a^2(a+1) - 4a(a+1) + a + 1 = (a+1)(4a^2-4a+1) = (a+1)(2a-1)^2$

giving solution a = -1 or $a= \frac{1}{2}$ (double root)

or $x^2 = - \sqrt{2}$ or  $x^2 = \frac{1}{\sqrt{2}}$ (double root)

 giving solution  $x= \pm  \sqrt[4]{2}i$ or $ x = \pm \frac{1}{\sqrt[4]{2}}$(double roots)

Saturday, July 3, 2021

2021/049) Solve the equation $x^3-3x= \sqrt{(x+2)}$

 As RHS is not negative so we have $x^2>=3$

Trying the lowest integer $>\sqrt{3}$ that is 2 we get this satisfies the equation.

Now squaring both sides we get $x^2(x^2-3)^2 = x + 2$

at $x >2$ LHS grows faster than RHS so x = 2 is the only solution

Thursday, July 1, 2021

2021/048) Maximise abcd given $ab+cd = 4\cdots(1)$ $ac + bd=8\cdots(2)$

Because abcd is maximum when abcd is positive as we have ab , cd are of same sign and as sum is positive so ab and cd both are positive.

Similarly ac and bd are positive. . so all 4 are positive or all 4 are -ve. with out loss of generality we can assume all 4 are positive.

We are given

$ab+cd = 4\cdots(1)$

$ac + bd=8\cdots(2)$

From  (1) we have using AM GM inequality $abcd <= 4$ and 

$abcd = 4$ when

$ab = cd  = 2\cdots(3)$

The value shall be 4 in case we find some abcd satisfying (2) and (3)

From (3) we have $a=\frac{2}{b}$ and $c=\frac{2}{d}$

Putting in (2) we get $ac + db =\frac{4}{bd} + db = 8$

or $(bd)^2 - 8bd + 4 =0$

So $bd = 4 + \sqrt{12}$ one solution

taking a = 1 we get

$a =1, b= 2 , c = 4- \sqrt{12} , d = 2 + \sqrt{3}$ satisfy (1) and (2) hence   maximum value of abcd = 4