Hi to all,
I am new to this forum. i want to know the number of solution of the equation x*x = 1 (mod n) for given n.
certainly it is 2 if n is prime if n is non prime I cant figure it out .
I would be gratefull if u help me.
Hi to all,
I am new to this forum. i want to know the number of solution of the equation x*x = 1 (mod n) for given n.
certainly it is 2 if n is prime if n is non prime I cant figure it out .
I would be gratefull if u help me.
Right the faulty assumption in topsquark's answer is there being no zero divisors, which is false in this case. Then what satisfies that equation is a pair of zero divisors different by 2. It is clear -1 and +1 work because then (-1+1)(-1-1)=0 and (1+1)(1-1)=0. When else can this happen though?
It is clear that this is exactly when by the modulo. Suppose there is some other y such that . Then and so .
So if there are two more solutions exactly when n is the product of consecutive even or odd integers. In other words, when n=8,15,24, etc. More generally, when n=x^2-1 for some integer x. The one exception to this is of course x=2 where n=3.
I think this is correct, I haven't thought through it more than a plausibility thing but it seems correct.
EDIT: Ok, thats not correct. I just randomly picked 12 to see that 5^2=25 which is 1 mod 5 because 4*6=24=0 mod 12. So the multiples are also kind of important... whoops! So in this case we're really looking for x-1, x+1 such that the prime divisors of n are contained in the prime divisors of x-1, x+1. I'll think about it some more.
It also seems to be true for multiples of 4, interestingly enough. Divide it in half to get a 0 divisor, then pick , and this will clearly work. So two special cases clearly give you 4 divisors. Its been two long since I've thought about the nuances of polynomials in this context. At this point perhaps more experimentation would reveal the pattern?
The key is to consider for all positive integers a and for all positive integers k that will evenly divide . For every pair of numbers with appropriate k, you get another pair of solutions for n: . You only need to consider values of a which are less than half of n after the calculation.
Here are the solutions for select composite numbers:
8 - 1, 3, 5, 7
gives
12 - 1, 5, 7, 11
gives
15 - 1, 4, 11, 14
gives
20 - 1, 9, 11, 19
gives
24 - 1, 5, 7, 11, 13, 17, 19, 23
gives ; gives ; gives
Note also that every solution for a particular number is expressible as . For instance, you may obtain the solutions of 11 for 15 by and 14 for 15 by , but this is unnecessary since you have obtained them from knowing that 1 and 4 are solutions.
I don't really see a more direct way of determining the solutions explicitly; induction doesn't seem to make much sense in terms of this problem. About all you can say for certain is that there are an even number of solutions for every modulus greater than 2, since the solutions come in pairs. You might also say that every number which is a multiple of 4, with the exception of 4 itself, has at least 4 solutions but some numbers (even those that are not multiples of 4) may have more.
To answer this question it is best to look at the structure of the multiplicative group of order n. For a full review on the subject go to this link: Multiplicative group of integers modulo n - Wikipedia, the free encyclopedia
So since we know that satisfying the equation is equivalent to finding an element of order at most 2 in this multiplicative group.
Note that in each cyclic group of even order there are exactly 2 such elements. And also note that if you take the direct product of groups the amount of such elements gets multiplied together to make the grand total of such elements.
So all it comes down to is counting the number of 'terms' this multiplicative group is made of.
so let's count: for each odd prime divisor there is exactly 1 term, and for the prime 2 there is either 2 terms if n is a multiple of 8, or 1 if n is even, (or zero if n is odd).
So this gives the formule where is 1 if n isn't a multiple of 8, and 2 otherwhise.