def lt_succ_le

bendtorch-core@0.1.0.0 · src/tensor/contracts/pointwise_proof.bend:98

import bendtorch-core@0.1.0.0/src/tensor/contracts/pointwise_proof.bend as PointwiseProof
import Base
import bendtorch-core@0.1.0.0/src/storage/arith.bend as Arith

98def lt_succ_le(+index: Nat, +bound: Nat, below: {Nat.is_lt(index, bound) == True{} : Bool}) ->
99  {Nat.is_le(1n+index, bound) == True{} : Bool}:
100  match index bound:
101    case 0n 0n:
102      Empty.absurd({Nat.is_le(1n, 0n) == True{} : Bool}, Arith.clash(below))
103    case 0n 1n+q:
104      Arith.le_zero(q)
105    case 1n+p 0n:
106      Empty.absurd({Nat.is_le(2n+p, 0n) == True{} : Bool}, Arith.clash(below))
107    case 1n+p 1n+q:
108      lt_succ_le(p, q, below)

Uses (7)

Used by (0)

No other definition uses this definition.