| firstn(n0, x0) = (n1 ≤ # x0 + # x1 ⊃ firstn(n1, x0 + x1);x0 + x1), n0 ≤ # x0 ⊦ n1 < # x0 ∧ n0 = n1, n0 = # x0 ∧ n1 = # x0 ∧ x1 ≠ [], n0 = # x0 ∧ # x0 ≤ n1 ∧ x1 = [] |
Used simplifier rules: ⊦ m ≤ m + n; (s)%a: ⊦ (m + n0) + n1 = m + n0 + n1; from specification nat-basic%c: ⊦ m + n = n + m; from specification nat-basic% ⊦ firstn(# x, x + y) = x; (s)%a: ⊦ (x + y) + z = x + y + z; from specification list% ⊦ # [] = 0; (s)% ⊦ n + 0 = n; (s)% ⊦ m ≤ n → (n ≤ m ↔ m = n); (s)% ⊦ x + [] = x; (s)% ⊦ firstn(# x, x) = x; (s)% ⊦ x = x + y ↔ y = []; (s)% ⊦ x + y = [] ↔ x = [] ∧ y = []; (as)% ⊦ #(x + y) = # x + # y; (s)% ⊦ m + m0 ≤ m ↔ m0 = 0; (s)% ⊦ # x = 0 ↔ x = []; (s)% ⊦ m ≤ n ↔ ¬ n < m; (ss)%f: ⊦ m < n → n ≠ 0; (forward) from specification nat-basic%lf: ⊦ m < n ∧ n < n0 → m +1 < n0; (forward) from specification nat-basic%trans: ⊦ n < n0 ∧ n0 < n1 → n < n1; (forward) from specification nat-basic% ⊦ m < n → n ≠ 0; (s)% ⊦ m +1 = m + 1; (s)% ⊦ m + m0 < n → ¬ n + n0 < m; (s)% ⊦ # firstn(n, x) = n; (s)% ⊦ m < n ↔ ¬ n ≤ m; (ss)% ⊦ m ≠ n → (m ≤ n ↔ m < n); (s)%fle-01: ⊦ m ≤ n ∧ n < n0 → m < n0; (forward) from specification nat% ⊦ m < n → (n ≤ m ↔ false); (s)%⊦ n ≤ # x → (y = firstn(n, x) ∧ z = restn(n, x) ↔ x = y + z ∧ # y = n); (elim) Used terms: x0, n0, y, z