Saturday, September 29, 2012

How many 5-digit numbers divisible by 11 are there containing each of the digits 2,3,4,5,6?

The sum of digits = 2 + 3+ 4 + 5 + 6 = 20

now for the number to be divisible by 11 the sum of digits at odd place should be same as sum of digits at even place or difference multiple of 11

say o is sum od digits at odd place and e sum of digits at even place.

o + e = 20
o- e = 11n and |o - e| < 20 as o+ e = 20

o-e should be even hence should be 0

so e = o = 10
sum of 2 digits ( even placed) and 4 + 6 (only combination)

so 4 and 6 can go to even place

2,3,5 should go to odd place

even position digits can be permuted( 2 ways)  among them selves and odd placed as well ( 6 ways)

so number of numbers = 2 * 6 = 12

Wednesday, September 26, 2012

If (x+ 1/x)^2 = 3 then the value of x^206 + x^200 + x^90 + x^84 + x^18 + x^12 + x^6 + 1


x^206 + x^200 + x^90 + x^84 + x^18 + x^12 + x^6 + 1
= x^200(x^6+1) + x^84(x^6+1) + x^12(x^6+1) + (x^6+1)
= (x^6+1)(x^200 + x^ 84+ x^12 + 1)

x^2 + 1/x^2 + 2 = 3
so x^2 + 1/x^2 = 1
or x^4 + 1 = x^2
or x^4 - x^2 + 1 = 0
or x ^6 + 1 = 0 ( multiplying by x^2 + 1)

hence given sum = 0          

Saturday, September 22, 2012

prove that (3)*5^(2n+1)+2^(3n+1) is divisible by 17

= 3 * 5 * 5^(2n) + 2 * (2^3)^n mod 17
= 15 * 25^n + 2 * 8^n mod 17
= 1 5 * 8^n + 2 * 8^n mod 17 as 25 = 8 mod 17
= 17 * 8^n

hence divisible by 17

Friday, September 14, 2012

calculate 2008 ! mod 2011

we see that 2011 is a prime number

so as per wilson theorem http://en.wikipedia.org/wiki/Wilson%27s_…

2010! mod 2011 = - 1

as 2010 mod 2011 = - 1 so 2009! mod 2011 = 1

so 2008 ! mod 2011 = inverse(2009) mod 2011 = - (inverse 2 mod 2011)

you can compute inverse using extended euclid algorithm http://en.wikipedia.org/wiki/Extended_Eu…

but there is a short cut.

as 2 * 1006 = 1 mod 2011 so inverse 2 is 1006
so 2008 ! mod 2011 = - (inverse 2 mod 2011) = - 1006 mod 2011 = 1005

What is the remainder of (x^100 - 4x^98 + 5x + 6) divided by (x³ - 2x² - x + 2)?

The remainder shall be quadratic say f(x) = ax^2 + bx + c

Now (x³ - 2x² - x + 2) = (x-2)(x-1)(x+1)
Let g(x) = (x^100 - 4x^98 + 5x + 6)- (ax^2 + bx + c)
g(1) , g(2), g(-1) all are 0
g(1) = 1- 4 + 5 + 6 – (a + b + c) = 0 or a + b+ c = 8 ..1
g(-1) = 1 – 4 – 5 + 6 – (a-b+ c) = 0 or a-b+c = -2 ..2
g(2) = 2^100- 2^100 + 10 + 6 – (4a + 2b+c) = 0 or 4a + 2b + c = 16 ..3

subtract (2) from (1) 2b = 10 or b = 5
so a + c = 3 and 4a + c = 6=> a = 1 and c = 2

remainder = x^2 + 5x + 2

Wednesday, September 12, 2012

show that p^4+p^2−2 is a multiple of 72 for prime p > 3

p^4 + p^2 - 2 = p^4 - 1 + p^2 - 1
= (p^2 - 1)(p^2 + 2)
= (p+1)(p-1)(p^2 + 2)

if p is a prime > 3 then 3 does not devide p so p+1 or p-1 is divisible by 3 and so p^2-1 is divisible by 3
as p^2 + 2 = p^2-1 + 3 so p^2 + 2 is divisible by 3

so (p^2 - 1)(p^2 + 2) is divisible by 9

now as p + 1 and p-1 are 2 consecutive even numbers one of them is divsible by 4 and other by 2 so product is diviisble by 8

so the number is divisible by 72

Monday, September 10, 2012

Is the sum of positive numbers < 10^6 close to even square more or less than sum of numbers close to odd square ?


A number is near even square if it is closer to even square than odd square else if is close to odd square. 

Let us take the numbers from (2n)^2 upto (2n+2)^2-1 that is from even square to the number 1 less than next even squares  that is from (2n)^2 upto (2n+2)^2-1.

That is from 4n^2 to 4n^4 + 8n + 3

Average of numbers = (8n^2 + 8n+ 3)/2

Total number of numbers = (8n+4)

Sum of numbers = (4n+2)(8n^2+8n + 3) ..1

Nuw numbers near odd square (2n+1)^2 (or 4n^2 + 4n + 1) are from 4n^2+ 2n+1 to 4n^2 + 6n + 2

Average of numbers = 2

Number of numbers = 4n+ 2

So sum of numbers near odd square = (2n+1)( (8n^2+ 8n + 3) ..2

Which is ½ of sum of numbers

So sum of numbers near odd square = sum of numbers near even square

taking the ranges from 0 to 2^2-1, 2^2 to 4^2- 1 so on upto 998^2 to 1000^2-1 we can each odd sum is same as even sum and hence sum of close to odd square is same as sum of close to even square.

Wednesday, September 5, 2012

2arctan(sqrtx)-arcsin((x-1)/(x+1)) is equal to pi/2?

it is defined for x >= 0

now let y = arctan(sqrtx)

cos 2arctan(sqrtx)
= cos (2y)
= (cos^2 y - sin ^2 y)/(cos^2 y + sin ^2 y)
= (cos^2 y - sin ^2 y)/(cos^2 y + sin ^2 y) as denominator is 1
= ( 1- tan ^2 y)/(1+ tan ^2 y)
= (1-tan ^2 y)/(1+tan ^2 y)
= (1-x)/(x+1)

so 2arctan(sqrtx)-arcsin((x-1)/(x+1)
= arc cos((1-x)/(x+1)) - arcsin((x-1)/(x+1))
= arc cos((1-x)/(x+1)) + arcsin((1-x)/(x+1)) as arcsin t = - arcsin - t
= pi/2 as arccos t + arcsin t = pi/2

(if t >= 0 both in 1st quadrant and sum is between 0 and pi)
if ( t < 0 then arc cos is between pi/2 and pi and arc sin < 0) so sum between 0 and pi) this is mentioned for fixing the range

α & β are roots of ax^2+bx+c=0 a,b,c real constants & λ is a constant find equation with roots α+ λ and β+ λ?

α & β are roots of f(x) = ax^2+bx+c=0

so α+ λ and β+ λ are root of f(x - λ)

the reason is x = α+ λ => x - λ = α and x = β + λ => x - λ = β

f(x) = ax^2+bx+c=0
=> f(x - λ) -= a (x - λ)^2 + b(x - λ) + c = 0

or ax^2 + x(b- 2a λ) + (c- bλ+ aλ^2) = 0

Sunday, September 2, 2012

find x such that 3^x-x^2 is divisible by 5?

as 3 and 5 are coprimes

so 3^4 = 1 mod 5 as per Fermats little theorem

now 3^(4k+1) = 3 mod 5
3^(4k+2) = 4 mod 5
3^(4k+3) = 2 mod 5
3^(4k) = 1 mod 5

now (5k+m)^2 mod 5 = 0 if m= 0, 1 if m= 1 or 4, 4 if m = 2 or 3 mod 5

now 3^x= x^2 mod 5 if

x =  0 mod 4 and 1 mod 5 ( in both cases remainder 1)
or x = 0 mod 4 and 1 mod 5( in both cases remainder 1)
or x = 2 mod 4 and 2 or 3 mod 5

x = 0 mod 4 and 1 mod 5 => x= 16 mod 20 (checking 0,4,8,12,16)
or x = 0 mod 4 mod 5 => x = 4 mod 20 (checking 0,4,8,12,16)
x =2 mod 5 and 2 mod 4 => x = 2 mod 20 as remainders are 2
or x = 2 mod 4 and 3 mod 5 => x= 18 mod 20 (checking 2,6,10,14,18)

 so solutions x = 2 mod 20, 4 mod 20, 18 mod 20, 16 mod 20

This could be solved by using Chinese remainder theorem but bing smapll number I checked for direct

There exists positive integers x,y such that both the expressions (3x+2y) and (4x-3y) are exactly divisibe by ?

Options a) 11 b) 7 c) 23 d) 17

solution
Let us eliminate y from a combination of the two

3(3x+2y) + 2( 4x -3y) = 17x

as sum of combination is divisible by 17 so ans is (d) 17 provided one of them is divisible by 17

this can be shown if we have x and y such that 3x+ 2y is divisible by 17

x= 3 , y = 4 satisfies it so (d) is solution