- First, I was partly wrong. *Any* factor of p-1 could

be the order of n mod p.

One thing to do is cycle through the factors of p-1.

In this case, 22120388821200*8+1=p, so we see that 2

has order 2^4*3*5^2*151*1367*89303. Note that the

multiplicative inverse of n mod p has the same order

as n mod p.

I'm sure there's a more efficient way to get the order

than by cycling through all the factors, but that's a

start.

Joseph.

--- joseph_osiecki <osieckis@...> wrote:> Can someone give me some more details on working out

__________________________________

> the order of an

> element mod p when we have a factorization of p-1?

> Please use the following example p = 176963110569601

> =

> 2^7*3*5^2*151*1367*89303 + 1. The order of 2 is

> 22120388821200.

> But why? How would I compute this from the

> factorization of p-1?

Do you Yahoo!?

Yahoo! Mail - Helps protect you from nasty viruses.

http://promotions.yahoo.com/new_mail - --- In primenumbers@yahoogroups.com, "joseph_osiecki" <osieckis@n...>

wrote:> Can someone give me some more details on working out the order of

an

> element mod p when we have a factorization of p-1?

The best way I know is to start with N=p-1 and trial divide by each

> Please use the following example p = 176963110569601 =

> 2^7*3*5^2*151*1367*89303 = 1. The order of 2 is 22120388821200.

> But why? How would I compute this from the factorization of p-1?

prime factor "q" of N. If 2^(N/q) = 1 mod p, then replace N by N/q

and continue. In your example, trial division by 2 works the first 3

times. Trial division by the other primes fails.

I do this whenever the ElevenSmooth Special Project finds a new

divisor. These factors are found as divisors of 2^3326400-1, so I

know the order is a divisor of GCD(3326400, p-1). I use this process

to find the order of 2, which tells me for which Mersenne number the

prime is a primitive factor. I then tell Will Edgington and post it

on the ElevenSmooth factors page at

http://ElevenSmooth.com/ElevenFactors.html

William

==================

ElevenSmooth http://ElevenSmooth.com

Distributed Factoring of 2^3326400-1 - Hi,

I have two experimental methods under investigation for this problem.

One is the 'reverse algorithm' as mentioned a week or so back.

A second method involves growing a 'binary tree'. This works from

knowing that the final modulo result in a trial factorisation is 1.

From this you can grow a tree, which will eventually give you the

number that you want.

The trick with the tree is to spot non-fruitful branches and to 'prune

them'. You also need to control the growth of the tree, since there

are many possible results, which are multiples of the one that you

want. The terminal condition for any branch of the tree is to trial

factor the number that you just generated and to check for a modulo 1

result.

Once you have grown a few trees then you will start to see the 1's and

0's of the binary representation of a number as a series of decision

points. From that you can start to appreciate that the final order 2

is as much a result of the spacings of 1's and 0's of the original

number as anything else.

The whole trick with this approach is to grow each branch one level at

a time. This prevents uncontrolled growth of any one branch. Another

thing is to watch out for repeating sequences, these need weeding out

too.

Kevin.

> --- In primenumbers@yahoogroups.com, "joseph_osiecki" <osieckis@n...>

22120388821200.

> wrote:

> > Can someone give me some more details on working out the order of

> an

> > element mod p when we have a factorization of p-1?

> > Please use the following example p = 176963110569601 =

> > 2^7*3*5^2*151*1367*89303 = 1. The order of 2 is

> > But why? How would I compute this from the factorization of p-1?

>

> The best way I know is to start with N=p-1 and trial divide by each

> prime factor "q" of N. If 2^(N/q) = 1 mod p, then replace N by N/q

> and continue. In your example, trial division by 2 works the first 3

> times. Trial division by the other primes fails.

>

> I do this whenever the ElevenSmooth Special Project finds a new

> divisor. These factors are found as divisors of 2^3326400-1, so I

> know the order is a divisor of GCD(3326400, p-1). I use this process

> to find the order of 2, which tells me for which Mersenne number the

> prime is a primitive factor. I then tell Will Edgington and post it

> on the ElevenSmooth factors page at

> http://ElevenSmooth.com/ElevenFactors.html

>

> William

> ==================

> ElevenSmooth http://ElevenSmooth.com

> Distributed Factoring of 2^3326400-1

>