def aff_x_l

bend-collections-laws-crypto@1.0.0.0 · proofs/crypto/secp256k1/pver.bend:32

import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/pver.bend as Pver
import Base
import bend-collections-laws-crypto@1.0.0.0/spec/crypto/secp256k1/field.bend as FS
import bend-collections-laws-crypto@1.0.0.0/src/crypto/secp256k1/point.bend as P
import bend-collections-laws-crypto@1.0.0.0/proofs/lib/logic.bend as Lg
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/point.bend as PT
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/sel.bend as SL
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/paff.bend as PA

32def aff_x_l(+one: Nat, a: P.Affine, +ha: {PA.ared(one, a) == True{} : Bool}) -> {FS.limbs16(one, 16n, P.aff_x(a)) == True{} : Bool}:
33  match a:
34    case P.Affine{+x, +y}:
35      SL.l16(one, x, Lg.and_left(PT.red(one, x), PT.red(one, y), ha))

Uses (9)

Used by (1)