def pos_pos
bend-collections-laws-crypto@1.0.0.0 · proofs/crypto/secp256k1/bounds.bend:20
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/bounds.bend as Bounds
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/proofs/math/typed/width.bend as WW
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/limbs.bend as LV
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/secp256k1/ineq.bend as I
20def pos_pos(+one: Nat, +h1: {one == 1n : Nat}, k: Nat) -> {Nat.is_lt(0n, LV.pos(k, one)) == True{} : Bool}:
21 match k:
22 case 0n:
23 lt_one(one, h1)
24 case 1n+ +j:
25 %Equal.sym(Nat, 0n, C.shift(16n, 0n), Equal.sym(Nat, C.shift(16n, 0n), 0n, WW.shift_zero(16n))) : {Nat.is_lt(_, C.shift(16n, LV.pos(j, one))) == True{} : Bool}
26 I.shift_lt(16n, 0n, LV.pos(j, one), pos_pos(one, h1, j))