diff -r 6decb8811d30 -r 587e97d144a0 Quot/Examples/FSet.thy --- a/Quot/Examples/FSet.thy Fri Dec 11 11:12:53 2009 +0100 +++ b/Quot/Examples/FSet.thy Fri Dec 11 11:14:05 2009 +0100 @@ -27,18 +27,18 @@ done quotient_def - EMPTY :: "EMPTY :: 'a fset" -where + "EMPTY :: 'a fset" +as "[]::'a list" quotient_def - INSERT :: "INSERT :: 'a \ 'a fset \ 'a fset" -where + "INSERT :: 'a \ 'a fset \ 'a fset" +as "op #" quotient_def - FUNION :: "FUNION :: 'a fset \ 'a fset \ 'a fset" -where + "FUNION :: 'a fset \ 'a fset \ 'a fset" +as "op @" fun @@ -48,8 +48,8 @@ | card1_cons: "(card1 (x # xs)) = (if (x mem xs) then (card1 xs) else (Suc (card1 xs)))" quotient_def - CARD :: "CARD :: 'a fset \ nat" -where + "CARD :: 'a fset \ nat" +as "card1" (* text {* @@ -111,18 +111,18 @@ done quotient_def - IN :: "IN :: 'a \ 'a fset \ bool" -where + "IN :: 'a \ 'a fset \ bool" +as "op mem" quotient_def - FOLD :: "FOLD :: ('a \ 'a \ 'a) \ ('b \ 'a) \ 'a \ 'b fset \ 'a" -where + "FOLD :: ('a \ 'a \ 'a) \ ('b \ 'a) \ 'a \ 'b fset \ 'a" +as "fold1" quotient_def - fmap::"fmap :: ('a \ 'b) \ 'a fset \ 'b fset" -where + "fmap :: ('a \ 'b) \ 'a fset \ 'b fset" +as "map" lemma mem_rsp: @@ -275,13 +275,13 @@ by (rule equivp_list_eq) quotient_def - EMPTY2 :: "EMPTY2 :: 'a fset2" -where + "EMPTY2 :: 'a fset2" +as "[]::'a list" quotient_def - INSERT2 :: "INSERT2 :: 'a \ 'a fset2 \ 'a fset2" -where + "INSERT2 :: 'a \ 'a fset2 \ 'a fset2" +as "op #" lemma "P (x :: 'a fset2) (EMPTY :: 'c fset) \ (\e t. P x t \ P x (INSERT e t)) \ P x l" @@ -293,13 +293,13 @@ done quotient_def - fset_rec::"fset_rec :: 'a \ ('b \ 'b fset \ 'a \ 'a) \ 'b fset \ 'a" -where + "fset_rec :: 'a \ ('b \ 'b fset \ 'a \ 'a) \ 'b fset \ 'a" +as "list_rec" quotient_def - fset_case::"fset_case :: 'a \ ('b \ 'b fset \ 'a) \ 'b fset \ 'a" -where + "fset_case :: 'a \ ('b \ 'b fset \ 'a) \ 'b fset \ 'a" +as "list_case" (* Probably not true without additional assumptions about the function *)