pub fn double(&self) -> Self {
        if self.is_neutral_element() {
            return self.clone();
        }
        let [px, py, pz] = self.coordinates();

        let px_square = px * px;
        let three_px_square = &px_square + &px_square + &px_square;
        let w = E::a() * pz * pz + three_px_square;
        let w_square = &w * &w;

        let s = py * pz;
        let s_square = &s * &s;
        let s_cube = &s * &s_square;
        let two_s_cube = &s_cube + &s_cube;
        let four_s_cube = &two_s_cube + &two_s_cube;
        let eight_s_cube = &four_s_cube + &four_s_cube;

        let b = px * py * &s;
        let two_b = &b + &b;
        let four_b = &two_b + &two_b;
        let eight_b = &four_b + &four_b;

        let h = &w_square - eight_b;
        let hs = &h * &s;

        let pys_square = py * py * s_square;
        let two_pys_square = &pys_square + &pys_square;
        let four_pys_square = &two_pys_square + &two_pys_square;
        let eight_pys_square = &four_pys_square + &four_pys_square;

        let xp = &hs + &hs;
        let yp = w * (four_b - &h) - eight_pys_square;
        let zp = eight_s_cube;

        debug_assert_eq!(
            E::defining_equation_projective(&xp, &yp, &zp),
            FieldElement::<E::BaseField>::zero()
        );
        // SAFETY: The values `x_p, y_p, z_p` are computed correctly to be on the curve.
        // The assertion above verifies that the resulting point is valid.
        let point = Self::new([xp, yp, zp]);
        point.unwrap()
    }
Performs the group operation between a point and itself a + a = 2a in
additive notation
crates/math/src/elliptic_curve/short_weierstrass/point.rs