Re: [algogeeks] 1/x + 1/y = 1/(n factorial)
x+y/(x*y)=1/N! N!=x*y/(x+y) assume x=y N!=x^2/(2x) x/2=N! x=2*N! 1/(2*N!)+1/(2*N!)=1/N! for example for N=4 1/48+1/48=1/24 On Mon, Jun 25, 2012 at 5:30 PM, Kumar Vishal kumar...@gmail.com wrote: We have to find number of Pair(x,y) which will satisfy the eq: 1/x + 1/y = 1/(n factorial) for large 0 N 10 ^ 4 N is integer Its problem from Code Sprint I tried to solve it by taking LOG but the sol was very slow , can any one please help Thanks Kumar Vishal -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To view this discussion on the web visit https://groups.google.com/d/msg/algogeeks/-/9SPU8dameBgJ. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- Thanks Regards Amritpal singh -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
Re: [algogeeks] 1/x + 1/y = 1/(n factorial)
1 /x + 1/y = 1/(n!) * Consider N = n! , * *The Equation becoz :-* 1/x + 1/y = 1/N or (x+y)/xy = 1/N or N( x + y ) = xy *Changing sides we get :-* xy - N(x+y) = 0 *Adding N^2 on both sides we get :-* xy - N( x + y) + N^2 = N^2 or xy - Nx - Ny + N^2 = N^2 or x(y - N) - N (y - N ) = N^2 or (x - N) (y - N) = N^2 From this equation we find that we can find the number of solution equal to the total number of divisors of (N ^ 2) .or ( n! ^2) . So you need to find the divisors of the square of the n! which can be done by finding the primes factor of the n! For example :- n! = p1^a * p2^b * pn^x *[ p1 , p2 .. pn are the prime factors ]* (n1 ^ 2) = p1^2a * p2^2b * pn^2x So the number of divisors are *(2a + 1) * (2b +1 ) * (2x + 1) *.. You need to calculate this ... -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
[algogeeks] 1/x + 1/y = 1/(n factorial)
We have to find number of Pair(x,y) which will satisfy the eq: 1/x + 1/y = 1/(n factorial) for large 0 N 10 ^ 4 N is integer Its problem from Code Sprint I tried to solve it by taking LOG but the sol was very slow , can any one please help Thanks Kumar Vishal -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To view this discussion on the web visit https://groups.google.com/d/msg/algogeeks/-/9SPU8dameBgJ. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.