Home | History | Annotate | Download | only in libtommath

Lines Matching defs:u2

19    a*u1 + b*u2 = u3
21 int mp_exteuclid(mp_int *a, mp_int *b, mp_int *U1, mp_int *U2, mp_int *U3)
23 mp_int u1,u2,u3,v1,v2,v3,t1,t2,t3,q,tmp;
26 if ((err = mp_init_multi(&u1, &u2, &u3, &v1, &v2, &v3, &t1, &t2, &t3, &q, &tmp, NULL)) != MP_OKAY) {
30 /* initialize, (u1,u2,u3) = (1,0,a) */
43 /* (t1,t2,t3) = (u1,u2,u3) - (v1,v2,v3)q */
47 if ((err = mp_sub(&u2, &tmp, &t2)) != MP_OKAY) { goto _ERR; }
51 /* (u1,u2,u3) = (v1,v2,v3) */
53 if ((err = mp_copy(&v2, &u2)) != MP_OKAY) { goto _ERR; }
65 mp_neg(&u2, &u2);
71 if (U2 != NULL) { mp_exch(U2, &u2); }
75 _ERR: mp_clear_multi(&u1, &u2, &u3, &v1, &v2, &v3, &t1, &t2, &t3, &q, &tmp, NULL);