Solve for exponent in modular exponentiation

869 Views Asked by At

If given that

N^x mod C = B

How does one solve for x if (x > 1). I did CRT and got 1, so does anyone know what direction I should go?

1

There are 1 best solutions below

4
On BEST ANSWER

This is known as the discrete logarithm problem. This isn't an easy problem in the general case, no $P$ algorithm is known to exist.

However, there exists algorithms that solve it in $O(n^{\log n})$ in finite fields : http://arxiv.org/pdf/1306.4244.pdf.

Some instances of the problem may be solved by hand, or quicker.

Furthermore, there exist algorithms better than the brute-force. Using a baby-step-giant-step method speeds up the search a lot.