src/HOL/Data_Structures/Brother12_Map.thy
changeset 68431 b294e095f64c
parent 68020 6aade817bee5
child 73526 a3cc9fa1295d
equal deleted inserted replaced
68423:c1db7503dbaa 68431:b294e095f64c
   190 end
   190 end
   191 
   191 
   192 subsection "Overall correctness"
   192 subsection "Overall correctness"
   193 
   193 
   194 interpretation Map_by_Ordered
   194 interpretation Map_by_Ordered
   195 where empty = N0 and lookup = lookup and update = update.update
   195 where empty = empty and lookup = lookup and update = update.update
   196 and delete = delete.delete and inorder = inorder and inv = "\<lambda>t. \<exists>h. t \<in> B h"
   196 and delete = delete.delete and inorder = inorder and inv = "\<lambda>t. \<exists>h. t \<in> B h"
   197 proof (standard, goal_cases)
   197 proof (standard, goal_cases)
   198   case 2 thus ?case by(auto intro!: lookup_map_of)
   198   case 2 thus ?case by(auto intro!: lookup_map_of)
   199 next
   199 next
   200   case 3 thus ?case by(auto intro!: update.inorder_update)
   200   case 3 thus ?case by(auto intro!: update.inorder_update)
   202   case 4 thus ?case by(auto intro!: delete.inorder_delete)
   202   case 4 thus ?case by(auto intro!: delete.inorder_delete)
   203 next
   203 next
   204   case 6 thus ?case using update.update_type by (metis Un_iff)
   204   case 6 thus ?case using update.update_type by (metis Un_iff)
   205 next
   205 next
   206   case 7 thus ?case using delete.delete_type by blast
   206   case 7 thus ?case using delete.delete_type by blast
   207 qed auto
   207 qed (auto simp: empty_def)
   208 
   208 
   209 end
   209 end