MCPcopy Create free account
hub / github.com/docknetwork/crypto / add_sources

Method add_sources

utils/src/randomized_pairing_check.rs:104–112  ·  view source on GitHub ↗

Add 2 group elements whose pairing should be equal to the pairing of another 2 given group elements, i.e. `e(a, b) = e(c, d)`

(
        &mut self,
        a: &E::G1Affine,
        b: impl Into<E::G2Prepared>,
        c: &E::G1Affine,
        d: impl Into<E::G2Prepared>,
    )

Source from the content-addressed store, hash-verified

102 /// Add 2 group elements whose pairing should be equal to the pairing of another 2 given group
103 /// elements, i.e. `e(a, b) = e(c, d)`
104 pub fn add_sources(
105 &mut self,
106 a: &E::G1Affine,
107 b: impl Into<E::G2Prepared>,
108 c: &E::G1Affine,
109 d: impl Into<E::G2Prepared>,
110 ) {
111 self.add_sources_with_laziness_choice(a, b, c, d, self.lazy)
112 }
113
114 /// Same as `Self::add_multiple_sources_and_target` except that this accepts whether to be lazy or
115 /// not and does not default to laziness decided during creation of the checker

Tested by 1

test_pairing_randomizeFunction · 0.64