[Imprint][Data Privacy Statement][E-Mail]



View long theorem info. View the proof. Back to main index. View the specification. View theorem base summary, View theorem base listing, the used properties by spec, the dependency list, the symbol table,

Proof step 1 from proof get-butlast (conclusion) (back to tree)

⊦ n < # x → (x + a ')[n] = x[n]

System applied rule normalize

And obtained the following new goals

Rule argument

Additional information

Proof step 2 from proof get-butlast (previous step) (back to tree)

(x + a ')[n] ≠ x[n], n < # x ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: ⊦ # x = 0 ↔ x = []; (s) f: ⊦ m < n → n ≠ 0; (forward) from specification nat-basic

Proof step 3 from proof get-butlast (previous step) (back to tree)

(x + a ')[n] ≠ x[n], x ≠ [], n < # x ⊦

Heuristic structural induction applied rule structural induction

And obtained the following new goals

Rule argument

term: x

Additional information

Used simplifier rules: list freely generated by [], +;;

Proof step 4 from proof get-butlast (previous step) (back to tree)

a0 + x0 ≠ [], ((a0 + x0) + a ')[n] ≠ (a0 + x0)[n], n < #(a0 + x0), ∀ a, n. ¬((x0 + a ')[n] ≠ x0[n] ∧ x0 ≠ [] ∧ n < # x0) ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: ⊦ m < n ↔ ¬ n ≤ m; (ss) c: ⊦ m + n = n + m; from specification nat-basic a: ⊦ (m + n0) + n1 = m + n0 + n1; from specification nat-basic ⊦ m < n + 1 ↔ ¬ n < m; (s) a: ⊦ (x + y) + z = x + y + z; from specification list ⊦ m +1 = m + 1; (s) ⊦ #(a ' + x) = (# x)+1; (s) ⊦ a + x = a ' + x; (s) ⊦ a ' + x ≠ []; (s)

Proof step 5 from proof get-butlast (previous step) (back to tree)

((a0 ' + x0) + a ')[n] ≠ (a0 ' + x0)[n], n ≤ # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ x0 = [] ∨ ¬ n0 < # x0 ⊦

Heuristic cut applied rule cut formula

And obtained the following new goals

Rule argument

fma: x0 = []

Additional information

Used simplifier rules: get-zero-01: ⊦ (a ' + x)[0] = a; one-03: ⊦ a '[0] = a; ⊦ x + [] = x; (s) ⊦ # [] = 0; (s) ⊦ m ≤ 0 ↔ m = 0; (s) ⊦ [] + x = x; (s) a: ⊦ (x + y) + z = x + y + z; from specification list Used formulas: x0 = []

Proof step 6 from proof get-butlast (previous step) (back to tree)

((a0 ' + x0) + a ')[n] ≠ (a0 ' + x0)[n], x0 ≠ [], n ≤ # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ x0 = [] ∨ ¬ n0 < # x0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Proof step 7 from proof get-butlast (previous step) (back to tree)

((a0 ' + x0) + a ')[n] ≠ (a0 ' + x0)[n], x0 ≠ [], n ≤ # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ ¬ n0 < # x0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: <toplevel>, name:get-rec, seq: ⊦ x ≠ [] ∧ n ≠ 0 → x[n] = x.tail[n - 1], subst:[n, x] → [n, (a0 ' + x0) + a '], <all paths>

Additional information

Used simplifier rules: get-zero-01: ⊦ (a ' + x)[0] = a; ⊦ a ' + x ≠ []; (s) a: ⊦ (x + y) + z = x + y + z; from specification list Used terms: n, (a0 ' + x0) + a '

Proof step 8 from proof get-butlast (previous step) (back to tree)

⊦ x ≠ [] ∧ n ≠ 0 → x[n] = x.tail[n - 1]

Lemma get-rec

Proof step 9 from proof get-butlast (previous step) (back to tree)

(a0 ' + x0) + a ' ≠ [], ((a0 ' + x0) + a ').tail[n - 1] ≠ (a0 ' + x0)[n], n ≠ 0, x0 ≠ [], n ≤ # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ ¬ n0 < # x0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: a: ⊦ (x + y) + z = x + y + z; from specification list ⊦ (a ' + x).tail = x; (s) ⊦ a ' + x ≠ []; (s)

Proof step 10 from proof get-butlast (previous step) (back to tree)

(x0 + a ')[n - 1] ≠ (a0 ' + x0)[n], n ≠ 0, x0 ≠ [], n ≤ # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ ¬ n0 < # x0 ⊦

Heuristic elimination applied rule apply elim lemma

And obtained the following new goals

Rule argument

spec: nat, name:elim-pred-c, seq:n ≠ 0 ⊦ m = n - 1 ↔ n = m + 1, subst:[n, m] → [n, m]

Additional information

Used simplifier rules: n ≠ 0 ⊦ m = n - 1 ↔ n = m + 1; (elim) Used terms: n, m

Proof step 11 from proof get-butlast (previous step) (back to tree)

n = m + 1, (x0 + a ')[m] ≠ (a0 ' + x0)[n], n ≠ 0, x0 ≠ [], n ≤ # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ ¬ n0 < # x0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: get-succ: ⊦ (a ' + x)[n + 1] = x[n]; ⊦ # x = 0 ↔ x = []; (s) f: ⊦ m < n → n ≠ 0; (forward) from specification nat-basic c: ⊦ m + n = n + m; from specification nat-basic a: ⊦ (m + n0) + n1 = m + n0 + n1; from specification nat-basic ⊦ m + 1 ≤ n ↔ m < n; (s) ⊦ m + 1 ≠ 0; (s) a: ⊦ (x + y) + z = x + y + z; from specification list

Proof step 12 from proof get-butlast (previous step) (back to tree)

(x0 + a ')[m] ≠ x0[m], x0 ≠ [], m < # x0, ∀ a1, n0. (x0 + a1 ')[n0] = x0[n0] ∨ ¬ n0 < # x0 ⊦

Heuristic quantifier closing applied rule all left

And closed the goal!

Rule argument

pos: left 4 terms: a, m

Additional information

Used terms: a, m

Proof Tree for get-butlast (View conclusion)

The following image shows the proof tree of sequent calculus. The proved goal is at the bottom. You can click on the nodes to view additional rules. See here for details on colors in a proof tree.

the proof tree