PROOFChecksum.ckp.e1g: def of bend-osdev-acpi@0.1.2.0 Import: import bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend as PROOFChecksum Lines 246-252 of bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend&start_line=246&end_line=252 import Base import bend-osdev-u32@0.1.0.0/u32.bend as U import bend-osdev-u32@0.1.0.0/LAWS.bend as UL def ckp.e1g(+so: U32, +b: U32, +n: Nat, +ev: {U32.to_nat(so) == U.U32Nat.low(8n, n) : Nat}) -> {U.U32Nat.low(8n, Nat.add(U32.to_nat(U32.and(255, U32.sub(so, b))), U32.to_nat(b))) == U.U32Nat.low(8n, n) : Nat}: %Equal.sym(Nat, U32.to_nat(U32.and(255, U32.sub(so, b))), U.U32Nat.low(8n, U32.to_nat(U32.sub(so, b))), ckp.am(U32.sub(so, b))) : {U.U32Nat.low(8n, Nat.add(_, U32.to_nat(b))) == U.U32Nat.low(8n, n) : Nat} %ckp.l1(U32.to_nat(U32.sub(so, b)), U32.to_nat(b)) : {_ == U.U32Nat.low(8n, n) : Nat} %Equal.sym(Nat, Nat.add(U32.to_nat(U32.sub(so, b)), U32.to_nat(b)), Nat.add(U32.to_nat(so), U.U32Nat.dbl(32n, U.U32Nat.bit(U32.is_lt(so, b)))), UL.u32_sub_wrap(so, b)) : {U.U32Nat.low(8n, _) == U.U32Nat.low(8n, n) : Nat} %Equal.sym(Nat, U.U32Nat.low(8n, Nat.add(U32.to_nat(so), U.U32Nat.dbl(32n, U.U32Nat.bit(U32.is_lt(so, b))))), U.U32Nat.low(8n, U32.to_nat(so)), ckp.l2(U32.to_nat(so), U.U32Nat.bit(U32.is_lt(so, b)))) : {_ == U.U32Nat.low(8n, n) : Nat} %Equal.sym(Nat, U32.to_nat(so), U.U32Nat.low(8n, n), ev) : {U.U32Nat.low(8n, _) == U.U32Nat.low(8n, n) : Nat} ckp.ll(n) Uses (16): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.sym https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.add https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.and https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.is_lt https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.sub https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.to_nat https://jend.leeeet.dev/definition.txt?path=bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend&name=ckp.am https://jend.leeeet.dev/definition.txt?path=bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend&name=ckp.l1 https://jend.leeeet.dev/definition.txt?path=bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend&name=ckp.l2 https://jend.leeeet.dev/definition.txt?path=bend-osdev-acpi@0.1.2.0/PROOF_checksum.bend&name=ckp.ll https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/LAWS.bend&name=u32_sub_wrap https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/u32.bend&name=U32Nat.bit https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/u32.bend&name=U32Nat.dbl https://jend.leeeet.dev/definition.txt?path=bend-osdev-u32@0.1.0.0/u32.bend&name=U32Nat.low