PROOF.un.inc_w: def of bend-osdev-u32@0.1.0.0 Import: import bend-osdev-u32@0.1.0.0/PROOF.bend as PROOF Lines 722-732 of bend-osdev-u32@0.1.0.0/PROOF.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-u32@0.1.0.0/PROOF.bend&start_line=722&end_line=732 import Base import bend-osdev-u32@0.1.0.0/u32.bend as U def un.inc_w(n: Nat, w: Word(n), h: {Nat.is_lt(1n+Word.to_nat(n, w), U.U32Nat.dbl(n, 1n)) == True{} : Bool}) -> {Word.to_nat(n, Word.inc(n, w)) == 1n+Word.to_nat(n, w) : Nat}: match n: case 0n: Empty.absurd({Word.to_nat(0n, Word.inc(0n, w)) == 1n+Word.to_nat(0n, w) : Nat}, un.ft(h)) case 1n+ +p: match w: case WCon{False{}, t}: {==} case WCon{True{}, +t}: +x = Word.to_nat(p, t) un.double_cong(Word.to_nat(p, Word.inc(p, t)), 1n+x, un.inc_w(p, t, Equal.trans(Bool, Nat.is_lt(1n+x, U.U32Nat.dbl(p, 1n)), Nat.is_lt(Nat.double(1n+x), Nat.double(U.U32Nat.dbl(p, 1n))), True{}, Equal.sym(Bool, Nat.is_lt(Nat.double(1n+x), Nat.double(U.U32Nat.dbl(p, 1n))), Nat.is_lt(1n+x, U.U32Nat.dbl(p, 1n)), un.lt_dbl(1n+x, U.U32Nat.dbl(p, 1n))), h))) Uses (15): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Empty.absurd https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.sym https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.trans https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.double https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_lt https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.Con https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.inc https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.to_nat https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/PROOF.bend&name=un.double_cong https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/PROOF.bend&name=un.ft https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/PROOF.bend&name=un.lt_dbl https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/u32.bend&name=U32Nat.dbl