public static void HalfTrace(ulong[] x, ulong[] z) { ulong[] tt = Nat.Create64(13); Nat448.Copy64(x, z); for (int i = 1; i < 409; i += 2) { ImplSquare(z, tt); Reduce(tt, z); ImplSquare(z, tt); Reduce(tt, z); AddTo(x, z); } }
public override ECLookupTable CreateCacheSafeLookupTable(ECPoint[] points, int off, int len) { ulong[] table = new ulong[len * SECT409R1_FE_LONGS * 2]; { int pos = 0; for (int i = 0; i < len; ++i) { ECPoint p = points[off + i]; Nat448.Copy64(((SecT409FieldElement)p.RawXCoord).x, 0, table, pos); pos += SECT409R1_FE_LONGS; Nat448.Copy64(((SecT409FieldElement)p.RawYCoord).x, 0, table, pos); pos += SECT409R1_FE_LONGS; } } return(new SecT409R1LookupTable(this, table, len)); }