| # x = n2 + n1 ⊦ n2 = 0, x = [], # σ < ⌜n⌝ , #((σ to n) + ⌜x⌝ from n1 + n) = ⌜n2⌝ ∧ (n0 < n2 → ((σ to n) + ⌜x⌝ from n1 + n)[n0] = x[n1 + n0]) |
⊦ ⌜n⌝ < # σ ∧ finp(σ) → #(σ from n) = ⌜(# σ).n - n⌝
# x = n2 + n1, ⌜n1 + n⌝ < #((σ to n) + ⌜x⌝ ), finp((σ to n) + ⌜x⌝ ) ⊦ n2 = 0, x = [], # σ < ⌜n⌝ , ⌜(#((σ to n) + ⌜x⌝ )).n - n1 + n⌝ = ⌜n2⌝ ∧ (n0 < n2 → ((σ to n) + ⌜x⌝ from n1 + n)[n0] = x[n1 + n0])
Used simplifier rules: size-append: ⊦ #(σ + σ1) = # σ + # σ1;%size-to: ¬ # σ < ⌜n⌝ ⊦ #(σ to n) = ⌜n⌝ ;%size-fin: ⊦ # ⌜x⌝ = ⌜# x⌝ ;%append-assoc: ⊦ (σ + σ1) + σ2 = σ + σ1 + σ2;%neq-fin-inf-03: ⊦ σ0 + ⌜x⌝ = ⌜nf0⌝ ↔ σ0 = ⌜nf0⌝ ;%inf-not-to: ⊦ ⌜nf⌝ ≠ σ to n;% ⊦ ⌜m + n⌝ = ⌜m⌝ + ⌜n⌝ ; (s)%a: ⊦ (m + n0) + n1 = m + n0 + n1; from specification nat-basic%c: ⊦ m + n = n + m; from specification nat-basic% ⊦ ⌜n⌝ + n∞1 < ⌜n⌝ + n∞2 ↔ n∞1 < n∞2; (s)% ⊦ ⌜m⌝ < ⌜n⌝ ↔ m < n; (s)%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% ⊦ m < m + n ↔ n ≠ 0; (s)%stream-inf-forward: ⊦ ¬ finp(σ) → (∃ nf. ⌜nf⌝ = σ); (forward) from specification stream-basic Used terms: n1 + n, (σ to n) + ⌜x⌝