| nl0[m0] = rem(⌜nl0⌝ , np)[n], ⌜n⌝ + ⌜1⌝ = # rem(⌜nl0⌝ , np), m0 < # nl0, m ≤ nl0[m0], mon<(⌜nl0⌝ + ⌜m '⌝ ), ∀ n0. n0 < n → rem(⌜nl0⌝ , np)[n0] < rem(⌜nl0⌝ , np)[n0 + 1], ∀ nl1, np. # nl1 < #(nl0 + m ') → mon<(⌜nl1⌝ ) → mon<(rem(⌜nl1⌝ , np)) ⊦ nl0 = [], np(m0), np(# nl0) |
⊦ mon<(nσ) ∧ m < n ∧ ⌜n⌝ < # nσ → nσ[m] < nσ[n]
Used simplifier rules: size-append: ⊦ #(nσ + nσ0) = # nσ + # nσ0; from specification stream[natstream]%size-fin: ⊦ # ⌜nl⌝ = ⌜# nl⌝ ; from specification stream[natstream]%len-02: ⊦ # m ' = 0 +1; from specification list[natstream]%append-assoc: ⊦ (nσ + nσ0) + nσ1 = nσ + nσ0 + nσ1; from specification stream[natstream]%less-succ-leq: ⊦ ⌜n⌝ < ⌜1⌝ + n∞ ↔ ¬ n∞ < ⌜n⌝ ; from specification nat-inf%less-fin: ⊦ ⌜m⌝ < ⌜n⌝ ↔ m < n; from specification nat-inf%ref-1: ⊦ ¬ n < n; from specification nat-basic1%add-assoc: ⊦ (n∞ + n∞1) + n∞2 = n∞ + n∞1 + n∞2; from specification nat-inf%add-comm: ⊦ n∞1 + n∞2 = n∞2 + n∞1; from specification nat-inf%get-append2-fin: ⊦ (⌜nl⌝ + ⌜nl0⌝ )[m] = (nl + nl0)[m]; from specification stream[natstream]%get-butlast: ⊦ n < # nl → (nl + m ')[n] = nl[n]; from specification list-del[natstream]%a: ⊦ (nl + nl0) + nl1 = nl + nl0 + nl1; from specification list[natstream]%get-last-03: ⊦ (nl + m ')[# nl] = m; from specification list-del[natstream]%le-ls-simp: ⊦ m ≤ n → (n < m ↔ false); from specification nat Used terms: ⌜nl0⌝ + ⌜m '⌝ , m0, # nl0