Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for euclidExtGCD (0.11 sec)

  1. src/math/big/int_test.go

    	d := new(Int).GCD(x, y, a, b)
    	x.Mul(x, a)
    	y.Mul(y, b)
    	x.Add(x, y)
    
    	return x.Cmp(d) == 0
    }
    
    // euclidExtGCD is a reference implementation of Euclid's
    // extended GCD algorithm for testing against optimized algorithms.
    // Requirements: a, b > 0
    func euclidExtGCD(a, b *Int) (g, x, y *Int) {
    	A := new(Int).Set(a)
    	B := new(Int).Set(b)
    
    	// A = Ua*a + Va*b
    	// B = Ub*a + Vb*b
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 58.5K bytes
    - Viewed (0)
Back to top