| ⊦ ((lls(r0, r1, x) * lls(r1, r2, y) * hP))(h) → ((lls(r0, r2, x + y) * hP))(h) |
((lls(r0, r1, x) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r0, r2, x + y) * hP))(h) ⊦
| ((lls(r0, r1, x) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r0, r2, x + y) * hP))(h) ⊦ |
((lls(r0, r1, x) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r0, r2, x + y) * hP))(h) ⊦
| ((lls(r0, r1, x) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r0, r2, x + y) * hP))(h) ⊦ |
((lls(r0, r1, a + x0) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r0, r2, (a + x0) + y) * hP))(h), ∀ r0, r1, r2, y, hP, h. ¬(((lls(r0, r1, x0) * lls(r1, r2, y) * hP))(h) ∧ ¬ ((lls(r0, r2, x0 + y) * hP))(h)) ⊦
Used simplifier rules: lls-base: ⊦ lls(r0, r1, []) = (emp ∧ ⌜r0 = r1⌝ ); list freely generated by [], +;; ⊦ emp * hP = hP; (s) ⊦ (⌜bv⌝ ∧ hP0) * hP1 = (⌜bv⌝ ∧ hP0 * hP1); (s) sep-ass: ⊦ (hP0 * hP1) * hP2 = hP0 * hP1 * hP2; from specification heap-sep sep-com: ⊦ hP0 * hP1 = hP1 * hP0; from specification heap-sep ⊦ ((hP0 ∧ hP1))(h) ↔ hP0(h) ∧ hP1(h); (s) ⊦ ⌜bv⌝ (h) ↔ bv; (s) and-ass: ⊦ ((hP0 ∧ hP1) ∧ hP2) = (hP0 ∧ hP1 ∧ hP2); from specification heap-sep and-com: ⊦ (hP0 ∧ hP1) = (hP1 ∧ hP0); from specification heap-sep ⊦ [] + x = x; (s) a: ⊦ (x + y) + z = x + y + z; from specification list
| ((lls(r0, r1, a + x0) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r0, r2, (a + x0) + y) * hP))(h), ∀ r0, r1, r2, y, hP, h. ¬(((lls(r0, r1, x0) * lls(r1, r2, y) * hP))(h) ∧ ¬ ((lls(r0, r2, x0 + y) * hP))(h)) ⊦ |
(((r0 => a × r * lls(r, r1, x0)) * lls(r1, r2, y) * hP))(h), ∀ r3, r4, r5, y0, hP0, h0. ¬ ((lls(r3, r4, x0) * lls(r4, r5, y0) * hP0))(h0) ∨ ((lls(r3, r5, x0 + y0) * hP0))(h0) ⊦ ∃ r. (((r0 => a × r * lls(r, r2, x0 + y)) * hP))(h)
Used simplifier rules: lls-rec: ⊦ lls(r, r1, a ' + x) = _∃(λ r0. r => a × r0 * lls(r0, r1, x)); sep-com: ⊦ hP0 * hP1 = hP1 * hP0; from specification heap-sep sep-ass: ⊦ (hP0 * hP1) * hP2 = hP0 * hP1 * hP2; from specification heap-sep ⊦ ((_∃ rP * hP))(h) ↔ (∃ r. ((rP(r) * hP))(h)); (s) a: ⊦ (x + y) + z = x + y + z; from specification list ⊦ a + x = a ' + x; (s)
| (((r0 => a × r * lls(r, r1, x0)) * lls(r1, r2, y) * hP))(h), ∀ r3, r4, r5, y0, hP0, h0. ¬ ((lls(r3, r4, x0) * lls(r4, r5, y0) * hP0))(h0) ∨ ((lls(r3, r5, x0 + y0) * hP0))(h0) ⊦ ∃ r. (((r0 => a × r * lls(r, r2, x0 + y)) * hP))(h) |
(((r0 => a × r * lls(r, r1, x0)) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r, r1, x0) * lls(r1, r2, y) * hP * r0 => a × r))(h) ∨ ((lls(r, r2, x0 + y) * hP * r0 => a × r))(h) ⊦ ∃ r. (((r0 => a × r * lls(r, r2, x0 + y)) * hP))(h)
Used terms: r, r1, r2, y, hP * r0 => a × r, h
| (((r0 => a × r * lls(r, r1, x0)) * lls(r1, r2, y) * hP))(h), ¬ ((lls(r, r1, x0) * lls(r1, r2, y) * hP * r0 => a × r))(h) ∨ ((lls(r, r2, x0 + y) * hP * r0 => a × r))(h) ⊦ ∃ r. (((r0 => a × r * lls(r, r2, x0 + y)) * hP))(h) |
(((r0 => a × r * lls(r, r1, x0)) * lls(r1, r2, y) * hP))(h), ((lls(r, r2, x0 + y) * hP * r0 => a × r))(h) ⊦ ∃ r. (((r0 => a × r * lls(r, r2, x0 + y)) * hP))(h)
Used simplifier rules: sep-com: ⊦ hP0 * hP1 = hP1 * hP0; from specification heap-sep sep-ass: ⊦ (hP0 * hP1) * hP2 = hP0 * hP1 * hP2; from specification heap-sep eq-objs: ⊦ ((r => o0 * hP0))(h) ∧ ((r => o1 * hP1))(h) → o0 = o1; (forward) from specification maplet[cell-heap]
| (((r0 => a × r * lls(r, r1, x0)) * lls(r1, r2, y) * hP))(h), ((lls(r, r2, x0 + y) * hP * r0 => a × r))(h) ⊦ ∃ r. (((r0 => a × r * lls(r, r2, x0 + y)) * hP))(h) |
Used simplifier rules: sep-ass: ⊦ (hP0 * hP1) * hP2 = hP0 * hP1 * hP2; from specification heap-sep sep-com: ⊦ hP0 * hP1 = hP1 * hP0; from specification heap-sep Used terms: r
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.