4

Suppose that a group $Z_p=${$1,2,3......(p-1)$} where p is a prime number. How to Determine the generator/generators of this group? what are the possible method of finding it?

iostream007
  • 4,509
Aria
  • 291
  • 1
    Something is strange here. The cyclic group of order $p$, or more generally the ring of integers mod $p$, includes a zero element, but you've only listed $p-1$ elements with no zero element. Are you perhaps talking about the multiplicative group $U(p):=({\bf Z}/p{\bf Z})^\times$? The generators of the additive group of integers mod $p$ are relatively easy to characterize; characterizing the generators of the multiplicative group $U(p)$ is a very hard problem with no known (or expected, really) general solution. – anon Jun 28 '13 at 06:23
  • related ; http://math.stackexchange.com/questions/124408/finding-a-primitive-root-of-a-prime-number – lab bhattacharjee Jun 28 '13 at 06:34
  • yes here i talking about multiplicative group.but what will happen in case of cyclic group. – Aria Jun 28 '13 at 06:34

1 Answers1

5

Suppose you can factor the order of the group, $p-1$ (which is not a safe assumption for large $p$). Suppose $p-1$ has prime factorization $p-1 = f_1^{i_1}\cdots f_k^{i_k}$. Then you can test any element $a$ as a generator by computing $a^{(p-1)/f_j} \bmod p$ for every $j\in [1,k]$. If you ever get 1, then $a$ isn't a generator. If you get non-1's every time, then $a$ is. Keep guessing until you find one.

Note that $Z_p^*$ is always cyclic, so there always is a generator. In fact, there are $\phi(p-1)$ of them. If you want generators to be easy to find, you can choose a prime $p=2q+1$ where $q$ is prime since then $\phi(p-1)=\phi(2q) = q-1$ meaning nearly half the group is generators. You need about 2 expected tries to find one.

Fixee
  • 11,760
  • "Suppose you can factor the order of the group, p−1 (which is not a safe assumption for large p)." I'd say it's a very safe assumption. Of course it's not a safe assumption that you can efficiently factor it (that is, you might not actually manage to get the factors in your lifetime), but we know for sure that the factorization exists and can be calculated in a finite (although possibly very large) number of steps. – celtschk Jun 28 '13 at 06:48
  • 5
    @cel, I'd say that if you can't do it in your lifetime, then you can't do it. – Gerry Myerson Jun 28 '13 at 07:34
  • 1
    In mathematics, I consider "you can do it" as equivalent to "there's an algorithm to do it that is known to halt." Otherwise statements like "you can add 1 to any natural number" would be wrong because at some point you'll have to do so many carry operations that you'll not be able to finish the addition in your lifetime. Not to mention that for a sufficiently large number, you'll run out of resources to write it down. – celtschk Jun 28 '13 at 12:28
  • When I said, "suppose you can factor" the "you" is the OP who is (presumably) a human trying to solve a problem. I did not (and would not) say "suppose a factorization exists for $(p-1)$". – Fixee Jun 28 '13 at 22:30