Discrete Logarithms

Log(b, x): QuadBinElt, QuadBinElt -> RngIntElt
The discrete logarithm of binary quadratic form x with respect to base b, or -1 if Magma can that determine no solution exists. This function exists only for negative discriminant forms. Computation is done via the Pohlig-Hellman algorithm along with a collision search subroutine (a variant of Pollard's rho method). If the user is unsure whether a solution exists, it is safest to use Log with a time limit (see below) to prevent an infinite loop in the collision search.
Log(b, x, t): QuadBinElt, QuadBinElt, RngIntElt -> RngIntElt
Searches for up to t seconds for the discrete logarithm of binary quadratic form x with respect to base b. This function exists only for negative discriminant forms. If Magma is able to determine no solution exists, then -1 will be returned. If no solution is found within the given time frame, then -2 will be returned. Computation is done via the Pohlig-Hellman algorithm along with a collision search subroutine (a variant of Pollard's rho method).
V2.28, 13 July 2023