protected virtual ECFieldElement Two(ECFieldElement x) { return x.Add(x); }
protected virtual ECFieldElement DoubleProductFromSquares(ECFieldElement a, ECFieldElement b, ECFieldElement aSquared, ECFieldElement bSquared) { /* * NOTE: If squaring in the field is faster than multiplication, then this is a quicker * way to calculate 2.A.B, if A^2 and B^2 are already known. */ return a.Add(b).Square().Subtract(aSquared).Subtract(bSquared); }