law fold_eq

bend-collections-laws-crypto@1.0.0.0 · proofs/crypto/poly1305/modp.bend:33

import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/poly1305/modp.bend as Modp
import Base
import bend-collections-laws-crypto@1.0.0.0/spec/lib/common.bend as C
import bend-collections-laws-crypto@1.0.0.0/spec/crypto/poly1305.bend as R

33# x == hi p + fold(x)
34law fold_eq:
35  for +one: Nat
36  for +h1: {one == 1n : Nat}
37  for +bp: Nat
38  for +h5: {Nat.add(1n+bp, 5n) == C.shift(130n, one) : Nat}
39  for +x: Nat
40  {x == Nat.add(Nat.mul(C.high(130n, x), 1n+bp), R.fold(x)) : Nat}

Uses (12)

Used by (2)