Package list-set-thm: Properties of list to set conversions
Information
name | list-set-thm |
version | 1.52 |
description | Properties of list to set conversions |
author | Joe Leslie-Hurd <joe@gilith.com> |
license | HOLLight |
provenance | HOL Light theory exported on 2019-05-03 |
checksum | b13a6d8784cf12cb6474c5b9b09f15753782a147 |
requires | bool list-def list-dest list-length list-set-def natural set |
show | Data.Bool Data.List Number.Natural Set |
Files
- Package tarball list-set-thm-1.52.tgz
- Theory source file list-set-thm.thy (included in the package tarball)
Theorems
⊦ ∀l. finite (toSet l)
⊦ ∀l. all (λx. ⊤) l
⊦ ∀l. size (toSet l) ≤ length l
⊦ ∀l. all (λx. ⊥) l ⇔ null l
⊦ ∀l. toSet l = ∅ ⇔ null l
⊦ ∀l. toSet l = ∅ ⇔ l = []
⊦ ∀s. finite s ⇒ toSet (fromSet s) = s
⊦ ∀s. finite s ⇒ length (fromSet s) = size s
⊦ ∀l x. member x l ⇔ x ∈ toSet l
⊦ ∀p l. ¬all p l ⇔ any (λx. ¬p x) l
⊦ ∀p l. ¬any p l ⇔ all (λx. ¬p x) l
⊦ ∀p l. ¬all (λx. ¬p x) l ⇔ any p l
⊦ ∀p l. ¬any (λx. ¬p x) l ⇔ all p l
⊦ ∀s. finite s ⇒ ∀x. member x (fromSet s) ⇔ x ∈ s
⊦ ∀p l. (∀x. member x l ⇒ p x) ⇔ all p l
⊦ ∀p l. (∃x. member x l ∧ p x) ⇔ any p l
⊦ ∀p l. all p l ⇔ ∀x. x ∈ toSet l ⇒ p x
⊦ ∀p l. any p l ⇔ ∃x. x ∈ toSet l ∧ p x
⊦ ∀p l. (∀x. all (p x) l) ⇔ all (λy. ∀x. p x y) l
⊦ ∀p l. (∃x. any (p x) l) ⇔ any (λy. ∃x. p x y) l
⊦ ∀p q l. all (λx. p x ∧ q x) l ⇔ all p l ∧ all q l
⊦ ∀p q l. all (λx. p x ⇒ q x) l ∧ all p l ⇒ all q l
⊦ ∀p q l. (∀x. member x l ∧ p x ⇒ q x) ∧ all p l ⇒ all q l
⊦ ∀p q l. (∀x. member x l ∧ p x ⇒ q x) ∧ any p l ⇒ any q l
⊦ ∀p q r l. all p l ∧ (∀x. p x ⇒ (q x ⇔ r x)) ⇒ (all q l ⇔ all r l)
External Type Operators
- →
- bool
- Data
- List
- list
- List
- Number
- Natural
- natural
- Natural
- Set
- set
External Constants
- =
- Data
- Bool
- ∀
- ∧
- ⇒
- ∃
- ∨
- ¬
- cond
- ⊥
- ⊤
- List
- ::
- []
- all
- any
- fromSet
- length
- member
- null
- toSet
- Bool
- Number
- Natural
- ≤
- suc
- zero
- Natural
- Set
- ∅
- finite
- insert
- ∈
- size
Assumptions
⊦ ⊤
⊦ null []
⊦ finite ∅
⊦ ¬⊥ ⇔ ⊤
⊦ size ∅ = 0
⊦ toSet [] = ∅
⊦ ∀n. 0 ≤ n
⊦ ∀n. n ≤ n
⊦ ∀p. all p []
⊦ ⊥ ⇔ ∀p. p
⊦ ∀x. ¬member x []
⊦ ∀x. ¬(x ∈ ∅)
⊦ ∀n. n ≤ suc n
⊦ ∀p. ¬any p []
⊦ (¬) = λp. p ⇒ ⊥
⊦ ∀t. (∀x. t) ⇔ t
⊦ ∀t. (λx. t x) = t
⊦ (∀) = λp. p = λx. ⊤
⊦ ∀t. ¬¬t ⇔ t
⊦ ∀t. (⊤ ⇔ t) ⇔ t
⊦ ∀t. ⊤ ∧ t ⇔ t
⊦ ∀t. t ∧ ⊤ ⇔ t
⊦ ∀t. ⊥ ⇒ t ⇔ ⊤
⊦ ∀t. ⊤ ⇒ t ⇔ t
⊦ ∀t. t ⇒ ⊤ ⇔ ⊤
⊦ ∀t. (⊥ ⇔ t) ⇔ ¬t
⊦ ∀t. t ⇒ ⊥ ⇔ ¬t
⊦ ∀l. null l ⇔ l = []
⊦ ∀h t. ¬null (h :: t)
⊦ (⇒) = λp q. p ∧ q ⇔ p
⊦ ∀x s. ¬(insert x s = ∅)
⊦ ∀s x. finite (insert x s) ⇔ finite s
⊦ ∀h t. length (h :: t) = suc (length t)
⊦ ∀s. (∃x. x ∈ s) ⇔ ¬(s = ∅)
⊦ (∧) = λp q. (λf. f p q) = λf. f ⊤ ⊤
⊦ ∀p. ¬(∀x. p x) ⇔ ∃x. ¬p x
⊦ ∀p. ¬(∃x. p x) ⇔ ∀x. ¬p x
⊦ (∃) = λp. ∀q. (∀x. p x ⇒ q) ⇒ q
⊦ ∀h t. toSet (h :: t) = insert h (toSet t)
⊦ ∀t1 t2. ¬(t1 ⇒ t2) ⇔ t1 ∧ ¬t2
⊦ ∀m n. suc m ≤ suc n ⇔ m ≤ n
⊦ ∀t1 t2. ¬(t1 ∨ t2) ⇔ ¬t1 ∧ ¬t2
⊦ (∨) = λp q. ∀r. (p ⇒ r) ⇒ (q ⇒ r) ⇒ r
⊦ ∀p. (∀x y. p x y) ⇔ ∀y x. p x y
⊦ ∀p. (∃x y. p x y) ⇔ ∃y x. p x y
⊦ ∀p q. p ∧ (∃x. q x) ⇔ ∃x. p ∧ q x
⊦ ∀p q. p ⇒ (∀x. q x) ⇔ ∀x. p ⇒ q x
⊦ ∀p q r. p ⇒ q ⇒ r ⇔ p ∧ q ⇒ r
⊦ ∀m n p. m ≤ n ∧ n ≤ p ⇒ m ≤ p
⊦ ∀s. finite s ⇒ toSet (fromSet s) = s ∧ length (fromSet s) = size s
⊦ ∀p h t. all p (h :: t) ⇔ p h ∧ all p t
⊦ ∀p h t. any p (h :: t) ⇔ p h ∨ any p t
⊦ ∀x h t. member x (h :: t) ⇔ x = h ∨ member x t
⊦ ∀x y s. x ∈ insert y s ⇔ x = y ∨ x ∈ s
⊦ ∀p. p [] ∧ (∀h t. p t ⇒ p (h :: t)) ⇒ ∀l. p l
⊦ ∀x s.
finite s ⇒ size (insert x s) = if x ∈ s then size s else suc (size s)
⊦ ∀p c x y. p (if c then x else y) ⇔ (c ⇒ p x) ∧ (¬c ⇒ p y)