pub fn eval_2_iso(p2: Point, p: Point) -> Point {
    // x3:=(x^2*x2-x)/(x-x2);
    // y3:=y*(x^2*x2-2*x*x2^2+x2)/(x-x2)^2;

    let (x2, _) = p2;
    let (x, y) = p;

    let t1 = fp2mul(x, x2);
    let t2 = fp2mul(x, t1);
    let t3 = fp2mul(t1, x2);
    let t3 = fp2add(t3, t3);
    let t3 = fp2sub(t2, t3);
    let t3 = fp2add(t3, x2);
    let t3 = fp2mul(y, t3);
    let t2 = fp2sub(t2, x);
    let t1 = fp2sub(x, x2);
    let t1 = fp2inv(t1);
    let x3 = fp2mul(t2, t1);
    let t1 = fp2sqr(t1);
    let y3 = fp2mul(t3, t1);
    (x3, y3)
}
/// Input: point p and point p2 of order 2
/// Output: phi(p) where phi is the 2-isogeny corresponding to p2
point p and point p2 of order 2
Output: phi(p) where phi is the 2-isogeny corresponding to p2
point p and point p2 of order 2 Output : phi ( p ) where phi is the 2 - isogeny corresponding to p2
pub fn eval_2_iso(p2: Point, p: Point) -> Point {
    // x3:=(x^2*x2-x)/(x-x2);
    // y3:=y*(x^2*x2-2*x*x2^2+x2)/(x-x2)^2;
    let (x2, _) = p2;
    let (x, y) = p;
    let t1 = fp2mul(x, x2);
    let t2 = fp2mul(x, t1);
    let t3 = fp2mul(t1, x2);
    let t3 = fp2add(t3, t3);
    let t3 = fp2sub(t2, t3);
    let t3 = fp2add(t3, x2);
    let t3 = fp2mul(y, t3);
    let t2 = fp2sub(t2, x);
    let t1 = fp2sub(x, x2);
    let t1 = fp2inv(t1);
    let x3 = fp2mul(t2, t1);
    let t1 = fp2sqr(t1);
    let y3 = fp2mul(t3, t1);
    (x3, y3)
}
pub fn eval_2_iso ( p2 : Point , p : Point ) -> Point { // x3:=(x^2*x2-x)/(x-x2); // y3:=y*(x^2*x2-2*x*x2^2+x2)/(x-x2)^2; let ( x2 , _ ) = p2 ; let ( x , y ) = p ; let t1 = fp2mul ( x , x2 ) ; let t2 = fp2mul ( x , t1 ) ; let t3 = fp2mul ( t1 , x2 ) ; let t3 = fp2add ( t3 , t3 ) ; let t3 = fp2sub ( t2 , t3 ) ; let t3 = fp2add ( t3 , x2 ) ; let t3 = fp2mul ( y , t3 ) ; let t2 = fp2sub ( t2 , x ) ; let t1 = fp2sub ( x , x2 ) ; let t1 = fp2inv ( t1 ) ; let x3 = fp2mul ( t2 , t1 ) ; let t1 = fp2sqr ( t1 ) ; let y3 = fp2mul ( t3 , t1 ) ; ( x3 , y3 ) }
Input: point p and point p2 of order 2
Output: phi(p) where phi is the 2-isogeny corresponding to p2
Input : point p and point p2 of order 2 Output : phi ( p ) where phi is the 2 - isogeny corresponding to p2
p2
Point
p
Point
p2
Point
p
Point