The Theory list
Parents
nat.gif
Children
char
Constants
IsListRep
(nat.gif rarr.gif 'a) cross.gif nat.gif rarr.gif BOOL
Cons
'a rarr.gif 'a LIST rarr.gif 'a LIST
[]
'a LIST
Length
'a LIST rarr.gif nat.gif
Hd
'a LIST rarr.gif 'a
Tl
'a LIST rarr.gif 'a LIST
Append
'a LIST rarr.gif 'a LIST rarr.gif 'a LIST
Rev
'a LIST rarr.gif 'a LIST
Split
('a cross.gif 'b) LIST rarr.gif 'a LIST cross.gif 'b LIST
Combine
'a LIST rarr.gif 'b LIST rarr.gif ('a cross.gif 'b) LIST
Map
('a rarr.gif 'b) rarr.gif 'a LIST rarr.gif 'b LIST
Fold
('a rarr.gif 'b rarr.gif 'b) rarr.gif 'a LIST rarr.gif 'b rarr.gif 'b
Aliases
@
Append : 'a LIST rarr.gif 'a LIST rarr.gif 'a LIST
Types
'1 LIST
Fixity
Right Infix 300:
@
Definitions
IsListRep
is_list_rep_def
turnstil.gif exist.gif nil cons
fillbull.gif IsListRep nil
filland.gif (forall.gif xbull.gif IsListRep x ruarr.gif (forall.gif hbull.gif not.gif cons h x = nil))
filland.gif (forall.gif x y
fillbull.gif IsListRep x and.gif IsListRep y
fillruarr.gif (forall.gif a b
fillbull.gif cons a x = cons b y equiv.gif a = b and.gif x = y))
filland.gif (forall.gif x
fillbull.gif IsListRep x ruarr.gif (forall.gif hbull.gif IsListRep (cons h x)))
filland.gif (forall.gif p
fillbull.gif p nil and.gif (forall.gif mbull.gif p m ruarr.gif (forall.gif hbull.gif p (cons h m)))
fillruarr.gif (forall.gif nbull.gif IsListRep n ruarr.gif p n))
LIST
list_def
turnstil.gif exist.gif fbull.gif TypeDefn IsListRep f
Nil
Cons
nil_cons_def
turnstil.gif (forall.gif x listbull.gif not.gif Cons x list = [])
filland.gif (forall.gif x1 x2 list1 list2
fillbull.gif Cons x1 list1 = Cons x2 list2
fillequiv.gif x1 = x2 and.gif list1 = list2)
filland.gif (forall.gif p
fillbull.gif p [] and.gif (forall.gif listbull.gif p list ruarr.gif (forall.gif xbull.gif p (Cons x list)))
fillruarr.gif (forall.gif listbull.gif p list))
Length
length_def
turnstil.gif # [] = 0 and.gif (forall.gif h listbull.gif # (Cons h list) = # list + 1)
Hd
hd_def
turnstil.gif forall.gif h listbull.gif Head (Cons h list) = h
Tl
tl_def
turnstil.gif forall.gif h listbull.gif Tail (Cons h list) = list
Append
append_def
turnstil.gif (forall.gif listbull.gif [] ⁀ list = list)
filland.gif (forall.gif h list list'
fillbull.gif Cons h list ⁀ list' = Cons h (list ⁀ list'))
Rev
rev_def
turnstil.gif Rev [] = []
filland.gif (forall.gif h listbull.gif Rev (Cons h list) = Rev list ⁀ [h])
Split
split_def
turnstil.gif Split [] = ([], [])
filland.gif (forall.gif list h1 h2
fillbull.gif Split (Cons (h1, h2) list)
fill= (Cons h1 (Fst (Split list)),
fillCons h2 (Snd (Split list))))
Combine
combine_def
turnstil.gif Combine [] [] = []
filland.gif (forall.gif h1 h2 list1 list2
fillbull.gif Combine (Cons h1 list1) (Cons h2 list2)
fill= Cons (h1, h2) (Combine list1 list2))
Map
map_def
turnstil.gif (forall.gif gbull.gif Map g [] = [])
filland.gif (forall.gif h g list
fillbull.gif Map g (Cons h list) = Cons (g h) (Map g list))
Fold
fold_def
turnstil.gif (forall.gif g xbull.gif Fold g [] x = x)
filland.gif (forall.gif h g x list
fillbull.gif Fold g (Cons h list) x = g h (Fold g list x))
Theorems
list_induction_thm
turnstil.gif forall.gif p
fillbull.gif p [] and.gif (forall.gif listbull.gif p list ruarr.gif (forall.gif xbull.gif p (Cons x list)))
fillruarr.gif (forall.gif listbull.gif p list)
list_prim_rec_thm
turnstil.gif forall.gif n c
fillbull.gif exist.gif1 f
fillbull.gif f [] = n
filland.gif (forall.gif list a
fillbull.gif f (Cons a list) = c a (f list) list)
list_clauses
turnstil.gif forall.gif x1 x2 list1 list2
fillbull.gif not.gif Cons x1 list1 = []
filland.gif not.gif [] = Cons x1 list1
filland.gif (Cons x1 list1 = Cons x2 list2
fillequiv.gif x1 = x2 and.gif list1 = list2)
filland.gif Head (Cons x1 list1) = x1
filland.gif Tail (Cons x1 list1) = list1
list_cases_thm
turnstil.gif forall.gif list1
fillbull.gif list1 = [] or.gif (exist.gif x list2bull.gif list1 = Cons x list2)

up quick index

V