Documentation ¶
Overview ¶
Package factorization implements various algorithms for efficient factoring integers of small to medium size.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetFactorECM ¶
GetFactorECM finds a factor of N using ECM factorization.
func GetFactorPollardRho ¶
GetFactorPollardRho implements Pollard's Rho algorithm for fast prime factorization, but this function only returns one factor per call This function can fail and return m.
func GetFactors ¶
GetFactors returns all the prime factors of m. Only the unique primes are returned, not their power.
func NewRandomWeierstrassCurve ¶
func NewRandomWeierstrassCurve(N *big.Int) (Weierstrass, Point)
NewRandomWeierstrassCurve generates a new random Weierstrass curve modulo N, along with a random point that lies on the curve.
Types ¶
type Weierstrass ¶
Weierstrass is an elliptic curve y^2 = x^3 + ax + b mod N.
func (*Weierstrass) Add ¶
func (w *Weierstrass) Add(P, Q Point) Point
Add adds two Weierstrass points together with respect to the underlying Weierstrass curve. This method does not check if the points lie on the underlying curve.