Home About
Complex Discrete Logs Compressed Histogram Hash
DIY crypto Fusion
Heterodyne Physics McCoskey Count Sort
Oil Spill Fix Personal Rail
Rational Residue Residue Arithmetic
Reverse Translation Analysis Rotary Engine
Subatomic Energy

Discrete Log Calculator Complex Discrete Logarithms
Residue Roots and CDLs Complex Linear Congruence
Indexed Complex Discrete Logarithms DLP solver for some primes

DLP solver for some primes

I would like to know if this has already been discovered, and is it useful?

Here’s the code: http://alrightsound.com/mcky/xlog.txt

This currently only works on groups or sequences to the base 2. For any prime P where the length of the sequence is one less than the prime. We are only interested in the odd members of this sequence.

We are given the target and the prime, P, and we are trying to find the discrete log base 2 of the target.

In the python code, the exp.stp() function generates the sequence and stores the results in a dictionary where the keys are the exponents from the sequence and the dictionary entries are the logarithms associated with thoes exponents.

As new members of the sequence are calculated, an exponent total and a log total are kept. Modular division is used to find the number, nu, that could multiply the exponent total mod P to equal the target.

If nu is in the dictionary of exponents and logs, then we have enough information to find the log of the target. We add the log total to the log for nu from the dictionary, and take the modulus with respect to (P-1).