Esempio n. 1
0
 public override ECFieldElement SquarePlusProduct(ECFieldElement x, ECFieldElement y)
 {
     ulong[] array  = this.x;
     ulong[] array2 = ((SecT163FieldElement)x).x;
     ulong[] y2     = ((SecT163FieldElement)y).x;
     ulong[] array3 = Nat192.CreateExt64();
     SecT163Field.SquareAddToExt(array, array3);
     SecT163Field.MultiplyAddToExt(array2, y2, array3);
     ulong[] z = Nat192.Create64();
     SecT163Field.Reduce(array3, z);
     return(new SecT163FieldElement(z));
 }
Esempio n. 2
0
        public override ECFieldElement MultiplyPlusProduct(ECFieldElement b, ECFieldElement x, ECFieldElement y)
        {
            ulong[] ax = this.x, bx = ((SecT163FieldElement)b).x;
            ulong[] xx = ((SecT163FieldElement)x).x, yx = ((SecT163FieldElement)y).x;

            ulong[] tt = Nat192.CreateExt64();
            SecT163Field.MultiplyAddToExt(ax, bx, tt);
            SecT163Field.MultiplyAddToExt(xx, yx, tt);

            ulong[] z = Nat192.Create64();
            SecT163Field.Reduce(tt, z);
            return(new SecT163FieldElement(z));
        }
 public override ECFieldElement MultiplyPlusProduct(ECFieldElement b, ECFieldElement x, ECFieldElement y)
 {
     ulong[] numArray  = this.x;
     ulong[] numArray2 = ((SecT163FieldElement)b).x;
     ulong[] numArray3 = ((SecT163FieldElement)x).x;
     ulong[] numArray4 = ((SecT163FieldElement)y).x;
     ulong[] zz        = Nat192.CreateExt64();
     SecT163Field.MultiplyAddToExt(numArray, numArray2, zz);
     SecT163Field.MultiplyAddToExt(numArray3, numArray4, zz);
     ulong[] z = Nat192.Create64();
     SecT163Field.Reduce(zz, z);
     return(new SecT163FieldElement(z));
 }