[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 main-lemma (conclusion) (back to tree)

⊦ r × c ∈ spmx ∧ c < # x ∧ r < # y → y[r, y[r] + spmx[r × c] * x[c]] + (spmx -- (r × c)).toMatrix(# y, # x) * x = y + spmx.toMatrix(# y, # x) * x

System applied rule normalize

And obtained the following new goals

Rule argument

Additional information

Proof step 2 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + spmx[r × c] * x[c]] + (spmx -- (r × c)).toMatrix(# y, # x) * x ≠ y + spmx.toMatrix(# y, # x) * x, c < # x, r < # y, r × c ∈ spmx ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: store[sparsearray], name:exin, seq: ⊦ a ∈ st ↔ (∃ d, st0. st = st0[a, d] ∧ ¬ a ∈ st0), subst:[a, st] → [r × c, spmx], <all paths>

Additional information

Used terms: r × c, spmx

Proof step 3 from proof main-lemma (previous step) (back to tree)

⊦ a ∈ st ↔ (∃ d, st0. st = st0[a, d] ∧ ¬ a ∈ st0)

A spec-lemma

Proof step 4 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + spmx[r × c] * x[c]] + (spmx -- (r × c)).toMatrix(# y, # x) * x ≠ y + spmx.toMatrix(# y, # x) * x, r < # y, c < # x, ∃ d, st0. spmx = st0[r × c, d] ∧ ¬ r × c ∈ st0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: ⊦ m < n → n ≠ 0; (s) f: ⊦ m < n → n ≠ 0; (forward) from specification nat-basic ⊦ ¬ a ∈ st → st -- a = st; (s) ⊦ st[a, d] -- a = st -- a; (s) ⊦ a = b → st[b, d][a] = d; (s)

Proof step 5 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x ≠ y + spmx0[r × c, a].toMatrix(# y, # x) * x, r < # y, c < # x, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: <toplevel>, name:toMatrix-add, seq:⊦ r < m ∧ c < n ∧ ¬ r × c ∈ spmx → spmx[r × c, a].toMatrix(m, n) = spmx.toMatrix(m, n) + mkmatrix(m, n, O)[r, c, a], subst:[n, m, spmx, c, r, a] → [# x, # y, spmx0, c, r, a], <all paths>

Additional information

Used terms: # x, # y, spmx0, c, r, a

Proof step 6 from proof main-lemma (previous step) (back to tree)

⊦ r < m ∧ c < n ∧ ¬ r × c ∈ spmx → spmx[r × c, a].toMatrix(m, n) = spmx.toMatrix(m, n) + mkmatrix(m, n, O)[r, c, a]

Lemma toMatrix-add

Proof step 7 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x ≠ y + (spmx0.toMatrix(# y, # x) + mkmatrix(# y, # x, O)[r, c, a]) * x, r < # y, c < # x, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: matrixops, name:distrmxmxvec, seq:⊦ #r mx1 = #r mx2 ∧ #c mx1 = #c mx2 ∧ #c mx1 = # vec → (mx1 + mx2) * vec = mx1 * vec + mx2 * vec, subst:[mx1, mx2, vec] → [spmx0.toMatrix(# y, # x), mkmatrix(# y, # x, O)[r, c, a], x], <all paths>

Additional information

Used simplifier rules: toMatrix-rowno: ⊦ #r spmx.toMatrix(r, c) = r; toMatrix-colno: ⊦ #c spmx.toMatrix(r, c) = c; ⊦ #r mx[r, c, a] = #r mx; (s) ⊦ #r mkmatrix(r, c, a) = r; (s) ⊦ #c mx[r, c, a] = #c mx; (s) ⊦ #c mkmatrix(r, c, a) = c; (s) Used terms: spmx0.toMatrix(# y, # x), mkmatrix(# y, # x, O)[r, c, a], x

Proof step 8 from proof main-lemma (previous step) (back to tree)

⊦ #r mx1 = #r mx2 ∧ #c mx1 = #c mx2 ∧ #c mx1 = # vec → (mx1 + mx2) * vec = mx1 * vec + mx2 * vec

A spec-lemma

Proof step 9 from proof main-lemma (previous step) (back to tree)

#c spmx0.toMatrix(# y, # x) = #c mkmatrix(# y, # x, O)[r, c, a], #c spmx0.toMatrix(# y, # x) = # x, #r spmx0.toMatrix(# y, # x) = #r mkmatrix(# y, # x, O)[r, c, a], y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x ≠ y + spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x, c < # x, r < # y, ¬ r × c ∈ spmx0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: toMatrix-rowno: ⊦ #r spmx.toMatrix(r, c) = r; toMatrix-colno: ⊦ #c spmx.toMatrix(r, c) = c; ⊦ #c mkmatrix(r, c, a) = c; (s) ⊦ #c mx[r, c, a] = #c mx; (s) ⊦ #r mkmatrix(r, c, a) = r; (s) ⊦ #r mx[r, c, a] = #r mx; (s)

Proof step 10 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x ≠ y + spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x, r < # y, c < # x, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: array[matrixops], name:Extension, seq: ⊦ ar1 = ar2 ↔ # ar1 = # ar2 ∧ (∀ n. n < # ar1 → ar1[n] = ar2[n]), subst:[ar1, ar2] → [y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x, y + spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x], <all paths>

Additional information

Used terms: y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x, y + spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x

Proof step 11 from proof main-lemma (previous step) (back to tree)

⊦ ar1 = ar2 ↔ # ar1 = # ar2 ∧ (∀ n. n < # ar1 → ar1[n] = ar2[n])

A spec-lemma

Proof step 12 from proof main-lemma (previous step) (back to tree)

c < # x, r < # y, ¬ r × c ∈ spmx0, #(y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x) ≠ #(y + spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x) ∨ (∃ n. ¬ ( n < #(y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x) → (y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x)[n] = (y + spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x)[n])) ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: ⊦ n < # vec1 → (vec1 + vec2)[n] = vec1[n] + vec2[n]; (s) ⊦ # ar[n, a] = # ar; (s) ⊦ #(vec1 + vec2) = # vec1; (s)

Proof step 13 from proof main-lemma (previous step) (back to tree)

(y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x)[n], r < # y, c < # x, n < # y, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: matrixops, name:addmvec-get, seq: ⊦ n < # vec1 → (vec1 + vec2)[n] = vec1[n] + vec2[n], subst:[vec1, vec2, n] → [spmx0.toMatrix(# y, # x) * x, mkmatrix(# y, # x, O)[r, c, a] * x, n], <all paths>

Additional information

Used terms: spmx0.toMatrix(# y, # x) * x, mkmatrix(# y, # x, O)[r, c, a] * x, n

Proof step 14 from proof main-lemma (previous step) (back to tree)

⊦ n < # vec1 → (vec1 + vec2)[n] = vec1[n] + vec2[n]

A spec-lemma

Proof step 15 from proof main-lemma (previous step) (back to tree)

(y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x)[n], n < # y, c < # x, r < # y, ¬ n < #(spmx0.toMatrix(# y, # x) * x), ¬ r × c ∈ spmx0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: fle-01: ⊦ m ≤ n ∧ n < n0 → m < n0; (forward) from specification nat ⊦ m < n ↔ ¬ n ≤ m; (ss)

Proof step 16 from proof main-lemma (previous step) (back to tree)

(y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x + mkmatrix(# y, # x, O)[r, c, a] * x)[n], r < # y, c < # x, n < # y, #(spmx0.toMatrix(# y, # x) * x) < # y, #(spmx0.toMatrix(# y, # x) * x) ≤ n, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: matrixops, name:multmxvec-size, seq: ⊦ #c mx = # vec → #(mx * vec) = #r mx, subst:[mx, vec] → [spmx0.toMatrix(# y, # x), x], <all paths>

Additional information

Used simplifier rules: toMatrix-colno: ⊦ #c spmx.toMatrix(r, c) = c; toMatrix-colno: ⊦ #c spmx.toMatrix(r, c) = c; toMatrix-rowno: ⊦ #r spmx.toMatrix(r, c) = r; ⊦ m < n → (n ≤ m ↔ false); (s) Used terms: spmx0.toMatrix(# y, # x), x

Proof step 17 from proof main-lemma (previous step) (back to tree)

⊦ #c mx = # vec → #(mx * vec) = #r mx

A spec-lemma

Proof step 18 from proof main-lemma (previous step) (back to tree)

(y[r, y[r] + a * x[c]] + spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x)[n] + (mkmatrix(# y, # x, O)[r, c, a] * x)[n], n < # y, c < # x, r < # y, n < #(spmx0.toMatrix(# y, # x) * x), ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: matrixops, name:addmvec-get, seq: ⊦ n < # vec1 → (vec1 + vec2)[n] = vec1[n] + vec2[n], subst:[vec1, vec2, n] → [y[r, y[r] + a * x[c]], spmx0.toMatrix(# y, # x) * x, n], <all paths>

Additional information

Used simplifier rules: ⊦ # ar[n, a] = # ar; (s) ⊦ m < n ↔ ¬ n ≤ m; (ss) ⊦ m < n → (n ≤ m ↔ false); (s) Used terms: y[r, y[r] + a * x[c]], spmx0.toMatrix(# y, # x) * x, n

Proof step 19 from proof main-lemma (previous step) (back to tree)

⊦ n < # vec1 → (vec1 + vec2)[n] = vec1[n] + vec2[n]

A spec-lemma

Proof step 20 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + a * x[c]][n] + (spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x)[n] + (mkmatrix(# y, # x, O)[r, c, a] * x)[n], n < #(spmx0.toMatrix(# y, # x) * x), r < # y, c < # x, n < # y, n < # y[r, y[r] + a * x[c]], ¬ r × c ∈ spmx0 ⊦

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

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

Proof step 21 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + a * x[c]][n] + (spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x)[n] + (mkmatrix(# y, # x, O)[r, c, a] * x)[n], n < #(spmx0.toMatrix(# y, # x) * x), r < # y, c < # x, n < # y, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: matrixops, name:singletonmxvec-get, seq:⊦ r < m ∧ c < # vec ∧ n < m → (mkmatrix(m, # vec, O)[r, c, a] * vec)[n] = (n = r ⊃ a * vec[c];O), subst:[vec, n, m, c, r, a] → [x, n, # y, c, r, a], <all paths>

Additional information

Used terms: x, n, # y, c, r, a

Proof step 22 from proof main-lemma (previous step) (back to tree)

⊦ r < m ∧ c < # vec ∧ n < m → (mkmatrix(m, # vec, O)[r, c, a] * vec)[n] = (n = r ⊃ a * vec[c];O)

A spec-lemma

Proof step 23 from proof main-lemma (previous step) (back to tree)

y[r, y[r] + a * x[c]][n] + (spmx0.toMatrix(# y, # x) * x)[n] ≠ y[n] + (spmx0.toMatrix(# y, # x) * x)[n] + (n = r ⊃ a * x[c];O), n < #(spmx0.toMatrix(# y, # x) * x), r < # y, c < # x, n < # y, ¬ r × c ∈ spmx0 ⊦

User applied rule apply rewrite lemma

And obtained the following new goals

Rule argument

spec: array[matrixops], name:Put-other, seq: ⊦ m ≠ n → ar[n, a][m] = ar[m], subst:[ar, n, a, m] → [y, r, y[r] + a * x[c], n], <all paths>

Additional information

Used simplifier rules: ⊦ a + O = a; (s) addcom: ⊦ a + b = b + a; from specification ring addassoc: ⊦ (a + b) + c = a + b + c; from specification ring ⊦ m < # ar → ar[m, a][m] = a; (s) Used terms: y, r, y[r] + a * x[c], n

Proof step 24 from proof main-lemma (previous step) (back to tree)

⊦ m ≠ n → ar[n, a][m] = ar[m]

A spec-lemma

Proof Tree for main-lemma (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