equal
deleted
inserted
replaced
109 qed "image_is_empty"; |
109 qed "image_is_empty"; |
110 AddIffs [image_is_empty]; |
110 AddIffs [image_is_empty]; |
111 |
111 |
112 goalw thy [image_def] |
112 goalw thy [image_def] |
113 "(%x. if P x then f x else g x) `` S \ |
113 "(%x. if P x then f x else g x) `` S \ |
114 \ = (f `` ({x. x:S & P x})) Un (g `` ({x. x:S & ~(P x)}))"; |
114 \ = (f `` (S Int {x. P x})) Un (g `` (S Int {x. ~(P x)}))"; |
115 by (split_tac [expand_if] 1); |
115 by (split_tac [expand_if] 1); |
116 by (Blast_tac 1); |
116 by (Blast_tac 1); |
117 qed "if_image_distrib"; |
117 qed "if_image_distrib"; |
118 Addsimps[if_image_distrib]; |
118 Addsimps[if_image_distrib]; |
119 |
119 |
367 |
367 |
368 section "UN and INT"; |
368 section "UN and INT"; |
369 |
369 |
370 (*Basic identities*) |
370 (*Basic identities*) |
371 |
371 |
372 val not_empty = prove_goal Set.thy "A ~= {} = (? x. x:A)" (K [Blast_tac 1]); |
372 val not_empty = prove_goal Set.thy "(A ~= {}) = (? x. x:A)" (K [Blast_tac 1]); |
373 (*Addsimps[not_empty];*) |
373 (*Addsimps[not_empty];*) |
374 |
374 |
375 goal thy "(UN x:{}. B x) = {}"; |
375 goal thy "(UN x:{}. B x) = {}"; |
376 by (Blast_tac 1); |
376 by (Blast_tac 1); |
377 qed "UN_empty"; |
377 qed "UN_empty"; |