Skip to content
Snippets Groups Projects
Commit f54148d7 authored by Praveen Kumar Vadlamani's avatar Praveen Kumar Vadlamani
Browse files

arrays

parent 03e93880
No related branches found
No related tags found
No related merge requests found
......@@ -57,6 +57,8 @@ theory ArrayLists =
// equational theory???❙
grow_update_eq : {m,l:array m, a,b,c} (grow l by a) update b as c ≐ grow (l update b as c) by a ❙
array_same : {a,x :a, l : array a, b,y:b, m : array b} x ≐ y ⟶ l ≐ m ❙
array_same_grow : {a, l: array a, m: array b,k :nat} l ≐ m ⟶ grow l by k ≐ grow m by k ❙
length : {a} array a ⟶ nat❘# | 2 |❙
length_make : {a,n,x:a} |make n x| ≐ n❙
......@@ -71,6 +73,8 @@ theory ArrayLists =
get_grow_def : {a,l:array a,m,n} |l| < m ⟶ m < |l|+n ⟶ (grow l by n) get m ≐ some (default l)❙
get_set_eq: {a,x:a,l,n} (l update n as x) get n ≐ some x❙
get_set_neq: {a,x:a,l,m,n} m ≠ n ⟶ (l update n as x) get m ≐ l get m ❙
// some thing new from here❙
get_set_noteq : {a, x: a, l: array a, m, n} (l update m as x) get n ≠ x ⟶ m ≠ n ❙
theory SparseLists =
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment