Theorem: collapseSRSElement_G1_soundness
Proof state before:
case intro.a.left.e_a.e_f.h.e_a.e_a
F : Type
inst✝¹ : Field F
𝓟 : AGMProofSystemInstantiation F
hTypeIII : 𝓟.Identified_Proof_Elems = []
inst✝ : DecidableEq 𝓟.SRSElements_G1
twin1 twin2 : 𝓟.SRSElements_G1
not_same : twin1 ≠ twin2
hcount1 : List.count twin1 𝓟.ListSRSElements_G1 = 1
hcount2 : List.count twin2 𝓟.ListSRSElements_G1 = 1
interchangeable : ∀ (idx : 𝓟.Proof_G1) (agm : 𝓟.Proof_G1 → 𝓟.SRSElements_G1 → F), agm idx twin1 = agm idx twin2
interchangeable' :
  ∀ (stmt : 𝓟.Stmt) (check_idx : 𝓟.EqualityChecks) (pairing : 𝓟.Pairings check_idx),
    𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin1 = 𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin2
Wit : Type
relation : 𝓟.Stmt → Wit → Prop
extractor : AGMProofSystemInstantiation.Prover F 𝓟 → Wit
stmt : (collapseSRSElement_G1 𝓟 twin1 twin2).Stmt
agm : AGMProofSystemInstantiation.Prover F (collapseSRSElement_G1 𝓟 twin1 twin2)
check_idx : 𝓟.EqualityChecks
pairing : 𝓟.Pairings check_idx
⊢ (List.map
        (fun SRS_elem =>
          MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing SRS_elem) * 𝓟.SRSElementValue_G1 SRS_elem)
        𝓟.ListSRSElements_G1).sum =
    (List.map
        (fun SRS_elem =>
          if SRS_elem = twin1 then
            MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing SRS_elem) *
              (𝓟.SRSElementValue_G1 twin1 + 𝓟.SRSElementValue_G1 twin2)
          else
            if SRS_elem = twin2 then 0
            else
              MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing SRS_elem) *
                𝓟.SRSElementValue_G1 SRS_elem)
        𝓟.ListSRSElements_G1).sum
Tactic:
simp only [List.sum_map_ite_eq, nsmul_eq_mul, zero_sub, smul_neg]
Proof state after:
case intro.a.left.e_a.e_f.h.e_a.e_a
F : Type
inst✝¹ : Field F
𝓟 : AGMProofSystemInstantiation F
hTypeIII : 𝓟.Identified_Proof_Elems = []
inst✝ : DecidableEq 𝓟.SRSElements_G1
twin1 twin2 : 𝓟.SRSElements_G1
not_same : twin1 ≠ twin2
hcount1 : List.count twin1 𝓟.ListSRSElements_G1 = 1
hcount2 : List.count twin2 𝓟.ListSRSElements_G1 = 1
interchangeable : ∀ (idx : 𝓟.Proof_G1) (agm : 𝓟.Proof_G1 → 𝓟.SRSElements_G1 → F), agm idx twin1 = agm idx twin2
interchangeable' :
  ∀ (stmt : 𝓟.Stmt) (check_idx : 𝓟.EqualityChecks) (pairing : 𝓟.Pairings check_idx),
    𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin1 = 𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin2
Wit : Type
relation : 𝓟.Stmt → Wit → Prop
extractor : AGMProofSystemInstantiation.Prover F 𝓟 → Wit
stmt : (collapseSRSElement_G1 𝓟 twin1 twin2).Stmt
agm : AGMProofSystemInstantiation.Prover F (collapseSRSElement_G1 𝓟 twin1 twin2)
check_idx : 𝓟.EqualityChecks
pairing : 𝓟.Pairings check_idx
⊢ (List.map
        (fun SRS_elem =>
          MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing SRS_elem) * 𝓟.SRSElementValue_G1 SRS_elem)
        𝓟.ListSRSElements_G1).sum =
    ↑(List.count twin1 𝓟.ListSRSElements_G1) *
        (MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin1) *
            (𝓟.SRSElementValue_G1 twin1 + 𝓟.SRSElementValue_G1 twin2) -
          if twin1 = twin2 then 0
          else MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin1) * 𝓟.SRSElementValue_G1 twin1) +
      (-(↑(List.count twin2 𝓟.ListSRSElements_G1) *
            (MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing twin2) * 𝓟.SRSElementValue_G1 twin2)) +
        (List.map
            (fun SRS_elem =>
              MvPolynomial.C (𝓟.verificationPairingSRS_G1 stmt check_idx pairing SRS_elem) *
                𝓟.SRSElementValue_G1 SRS_elem)
            𝓟.ListSRSElements_G1).sum)