-
Notifications
You must be signed in to change notification settings - Fork 0
/
AOT_model.thy
1325 lines (1247 loc) · 79.1 KB
/
AOT_model.thy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
(*<*)
theory AOT_model
imports Main "HOL-Cardinals.Cardinals"
begin
declare[[typedef_overloaded]]
(*>*)
section\<open>References\<close>
text\<open>
A full description of this formalization including references can be found
at @{url \<open>http://dx.doi.org/10.17169/refubium-35141\<close>}.
The version of Principia Logico-Metaphysica (PLM) implemented in this formalization
can be found at @{url \<open>http://mally.stanford.edu/principia-2021-10-13.pdf\<close>}, while
the latest version of PLM is available at @{url \<open>http://mally.stanford.edu/principia.pdf\<close>}.
\<close>
section\<open>Model for the Logic of AOT\<close>
text\<open>We introduce a primitive type for hyperintensional propositions.\<close>
typedecl \<o>
text\<open>To be able to model modal operators following Kripke semantics,
we introduce a primitive type for possible worlds and assert, by axiom,
that there is a surjective function mapping propositions to the
boolean-valued functions acting on possible worlds. We call the result
of applying this function to a proposition the Montague intension
of the proposition.\<close>
typedecl w \<comment>\<open>The primtive type of possible worlds.\<close>
axiomatization AOT_model_d\<o> :: \<open>\<o>\<Rightarrow>(w\<Rightarrow>bool)\<close> where
d\<o>_surj: \<open>surj AOT_model_d\<o>\<close>
text\<open>The axioms of PLM require the existence of a non-actual world.\<close>
consts w\<^sub>0 :: w \<comment>\<open>The designated actual world.\<close>
axiomatization where AOT_model_nonactual_world: \<open>\<exists>w . w \<noteq> w\<^sub>0\<close>
text\<open>Validity of a proposition in a given world can now be modelled as the result
of applying that world to the Montague intension of the proposition.\<close>
definition AOT_model_valid_in :: \<open>w\<Rightarrow>\<o>\<Rightarrow>bool\<close> where
\<open>AOT_model_valid_in w \<phi> \<equiv> AOT_model_d\<o> \<phi> w\<close>
text\<open>By construction, we can choose a proposition for any given Montague intension,
s.t. the proposition is valid in a possible world iff the Montague intension
evaluates to true at that world.\<close>
definition AOT_model_proposition_choice :: \<open>(w\<Rightarrow>bool) \<Rightarrow> \<o>\<close> (binder \<open>\<epsilon>\<^sub>\<o> \<close> 8)
where \<open>\<epsilon>\<^sub>\<o> w. \<phi> w \<equiv> (inv AOT_model_d\<o>) \<phi>\<close>
lemma AOT_model_proposition_choice_simp: \<open>AOT_model_valid_in w (\<epsilon>\<^sub>\<o> w. \<phi> w) = \<phi> w\<close>
by (simp add: surj_f_inv_f[OF d\<o>_surj] AOT_model_valid_in_def
AOT_model_proposition_choice_def)
text\<open>Nitpick can trivially show that there are models for the axioms above.\<close>
lemma \<open>True\<close> nitpick[satisfy, user_axioms, expect = genuine] ..
typedecl \<omega> \<comment>\<open>The primtive type of ordinary objects/urelements.\<close>
text\<open>Validating extended relation comprehension requires a large set of
special urelements. For simple models that do not validate extended
relation comprehension (and consequently the predecessor axiom in the
theory of natural numbers), it suffices to use a primitive type as @{text \<sigma>},
i.e. @{theory_text \<open>typedecl \<sigma>\<close>}.\<close>
typedecl \<sigma>'
typedef \<sigma> = \<open>UNIV::((\<omega> \<Rightarrow> w \<Rightarrow> bool) set \<times> (\<omega> \<Rightarrow> w \<Rightarrow> bool) set \<times> \<sigma>') set\<close> ..
typedecl null \<comment> \<open>Null-urelements representing non-denoting terms.\<close>
datatype \<upsilon> = \<omega>\<upsilon> \<omega> | \<sigma>\<upsilon> \<sigma> | is_null\<upsilon>: null\<upsilon> null \<comment> \<open>Type of urelements\<close>
text\<open>Urrelations are proposition-valued functions on urelements.
Urrelations are required to evaluate to necessarily false propositions for
null-urelements (note that there may be several distinct necessarily false
propositions).\<close>
typedef urrel = \<open>{ \<phi> . \<forall> x w . \<not>AOT_model_valid_in w (\<phi> (null\<upsilon> x)) }\<close>
by (rule exI[where x=\<open>\<lambda> x . (\<epsilon>\<^sub>\<o> w . \<not>is_null\<upsilon> x)\<close>])
(auto simp: AOT_model_proposition_choice_simp)
text\<open>Abstract objects will be modelled as sets of urrelations and will
have to be mapped surjectively into the set of special urelements.
We show that any mapping from abstract objects to special urelements
has to involve at least one large set of collapsed abstract objects.
We will use this fact to extend arbitrary mappings from abstract objects
to special urelements to surjective mappings.\<close>
lemma \<alpha>\<sigma>_pigeonhole:
\<comment> \<open>For any arbitrary mapping @{term \<alpha>\<sigma>} from sets of urrelations to special
urelements, there exists an abstract object x, s.t. the cardinal of the set
of special urelements is strictly smaller than the cardinal of the set of
abstract objects that are mapped to the same urelement as x under @{term \<alpha>\<sigma>}.\<close>
\<open>\<exists>x . |UNIV::\<sigma> set| <o |{y . \<alpha>\<sigma> x = \<alpha>\<sigma> y}|\<close>
for \<alpha>\<sigma> :: \<open>urrel set \<Rightarrow> \<sigma>\<close>
proof(rule ccontr)
have card_\<sigma>_set_set_bound: \<open>|UNIV::\<sigma> set set| \<le>o |UNIV::urrel set|\<close>
proof -
let ?pick = \<open>\<lambda>u s . \<epsilon>\<^sub>\<o> w . case u of (\<sigma>\<upsilon> s') \<Rightarrow> s' \<in> s | _ \<Rightarrow> False\<close>
have \<open>\<exists>f :: \<sigma> set \<Rightarrow> urrel . inj f\<close>
proof
show \<open>inj (\<lambda>s . Abs_urrel (\<lambda>u . ?pick u s))\<close>
proof(rule injI)
fix x y
assume \<open>Abs_urrel (\<lambda>u. ?pick u x) = Abs_urrel (\<lambda>u. ?pick u y)\<close>
hence \<open>(\<lambda>u. ?pick u x) = (\<lambda>u. ?pick u y)\<close>
by (auto intro!: Abs_urrel_inject[THEN iffD1]
simp: AOT_model_proposition_choice_simp)
hence \<open>AOT_model_valid_in w\<^sub>0 (?pick (\<sigma>\<upsilon> s) x) =
AOT_model_valid_in w\<^sub>0 (?pick (\<sigma>\<upsilon> s) y)\<close>
for s by metis
hence \<open>(s \<in> x) = (s \<in> y)\<close> for s
by (auto simp: AOT_model_proposition_choice_simp)
thus \<open>x = y\<close>
by blast
qed
qed
thus ?thesis
by (metis card_of_image inj_imp_surj_inv)
qed
text\<open>Assume, for a proof by contradiction, that there is no large collapsed set.\<close>
assume \<open>\<nexists>x . |UNIV::\<sigma> set| <o |{y . \<alpha>\<sigma> x = \<alpha>\<sigma> y}|\<close>
hence A: \<open>\<forall>x . |{y . \<alpha>\<sigma> x = \<alpha>\<sigma> y}| \<le>o |UNIV::\<sigma> set|\<close>
by auto
have union_univ: \<open>(\<Union>x \<in> range(inv \<alpha>\<sigma>) . {y . \<alpha>\<sigma> x = \<alpha>\<sigma> y}) = UNIV\<close>
by auto (meson f_inv_into_f range_eqI)
text\<open>We refute by case distinction: there is either finitely many or
infinitely many special urelements and in both cases we can derive
a contradiction from the assumption above.\<close>
{
text\<open>Finite case.\<close>
assume finite_\<sigma>_set: \<open>finite (UNIV::\<sigma> set)\<close>
hence finite_collapsed: \<open>finite {y . \<alpha>\<sigma> x = \<alpha>\<sigma> y}\<close> for x
using A card_of_ordLeq_infinite by blast
hence 0: \<open>\<forall>x . card {y . \<alpha>\<sigma> x = \<alpha>\<sigma> y} \<le> card (UNIV::\<sigma> set)\<close>
by (metis A finite_\<sigma>_set card_of_ordLeq inj_on_iff_card_le)
have 1: \<open>card (range (inv \<alpha>\<sigma>)) \<le> card (UNIV::\<sigma> set)\<close>
using finite_\<sigma>_set card_image_le by blast
hence 2: \<open>finite (range (inv \<alpha>\<sigma>))\<close>
using finite_\<sigma>_set by blast
define n where \<open>n = card (UNIV::urrel set set)\<close>
define m where \<open>m = card (UNIV::\<sigma> set)\<close>
have \<open>n = card (\<Union>x \<in> range(inv \<alpha>\<sigma>) . {y . \<alpha>\<sigma> x = \<alpha>\<sigma> y})\<close>
unfolding n_def using union_univ by argo
also have \<open>\<dots> \<le> (\<Sum>i\<in>range (inv \<alpha>\<sigma>). card {y. \<alpha>\<sigma> i = \<alpha>\<sigma> y})\<close>
using card_UN_le 2 by blast
also have \<open>\<dots> \<le> (\<Sum>i\<in>range (inv \<alpha>\<sigma>). card (UNIV::\<sigma> set))\<close>
by (metis (no_types, lifting) 0 sum_mono)
also have \<open>\<dots> \<le> card (range (inv \<alpha>\<sigma>)) * card (UNIV::\<sigma> set)\<close>
using sum_bounded_above by auto
also have \<open>\<dots> \<le> card (UNIV::\<sigma> set) * card (UNIV::\<sigma> set)\<close>
using 1 by force
also have \<open>\<dots> = m*m\<close>
unfolding m_def by blast
finally have n_upper: \<open>n \<le> m*m\<close>.
have \<open>finite (\<Union>x \<in> range(inv \<alpha>\<sigma>) . {y . \<alpha>\<sigma> x = \<alpha>\<sigma> y})\<close>
using 2 finite_collapsed by blast
hence finite_\<alpha>set: \<open>finite (UNIV::urrel set set)\<close>
using union_univ by argo
have \<open>2^2^m = (2::nat)^(card (UNIV::\<sigma> set set))\<close>
by (metis Pow_UNIV card_Pow finite_\<sigma>_set m_def)
moreover have \<open>card (UNIV::\<sigma> set set) \<le> (card (UNIV::urrel set))\<close>
using card_\<sigma>_set_set_bound
by (meson Finite_Set.finite_set card_of_ordLeq finite_\<alpha>set
finite_\<sigma>_set inj_on_iff_card_le)
ultimately have \<open>2^2^m \<le> (2::nat)^(card (UNIV:: urrel set))\<close>
by simp
also have \<open>\<dots> = n\<close>
unfolding n_def
by (metis Finite_Set.finite_set Pow_UNIV card_Pow finite_\<alpha>set)
finally have \<open>2^2^m \<le> n\<close> by blast
hence \<open>2^2^m \<le> m*m\<close> using n_upper by linarith
moreover {
have \<open>(2::nat)^(2^m) \<ge> (2^(m + 1))\<close>
by (metis Suc_eq_plus1 Suc_leI less_exp one_le_numeral power_increasing)
also have \<open>(2^(m + 1)) = (2::nat) * 2^m\<close>
by auto
have \<open>m < 2^m\<close>
by (simp add: less_exp)
hence \<open>m*m < (2^m)*(2^m)\<close>
by (simp add: mult_strict_mono)
moreover have \<open>\<dots> = 2^(m+m)\<close>
by (simp add: power_add)
ultimately have \<open>m*m < 2 ^ (m + m)\<close> by presburger
moreover have \<open>m+m \<le> 2^m\<close>
proof (induct m)
case 0
thus ?case by auto
next
case (Suc m)
thus ?case
by (metis Suc_leI less_exp mult_2 mult_le_mono2 power_Suc)
qed
ultimately have \<open>m*m < 2^2^m\<close>
by (meson less_le_trans one_le_numeral power_increasing)
}
ultimately have False by auto
}
moreover {
text\<open>Infinite case.\<close>
assume \<open>infinite (UNIV::\<sigma> set)\<close>
hence Cinf\<sigma>: \<open>Cinfinite |UNIV::\<sigma> set|\<close>
by (simp add: cinfinite_def)
have 1: \<open>|range (inv \<alpha>\<sigma>)| \<le>o |UNIV::\<sigma> set|\<close>
by auto
have 2: \<open>\<forall>i\<in>range (inv \<alpha>\<sigma>). |{y . \<alpha>\<sigma> i = \<alpha>\<sigma> y}| \<le>o |UNIV::\<sigma> set|\<close>
proof
fix i :: \<open>urrel set\<close>
assume \<open>i \<in> range (inv \<alpha>\<sigma>)\<close>
show \<open>|{y . \<alpha>\<sigma> i = \<alpha>\<sigma> y}| \<le>o |UNIV::\<sigma> set|\<close>
using A by blast
qed
have \<open>|\<Union> ((\<lambda>i. {y. \<alpha>\<sigma> i = \<alpha>\<sigma> y}) ` (range (inv \<alpha>\<sigma>)))| \<le>o
|Sigma (range (inv \<alpha>\<sigma>)) (\<lambda>i. {y. \<alpha>\<sigma> i = \<alpha>\<sigma> y})|\<close>
using card_of_UNION_Sigma by blast
hence \<open>|UNIV::urrel set set| \<le>o
|Sigma (range (inv \<alpha>\<sigma>)) (\<lambda>i. {y. \<alpha>\<sigma> i = \<alpha>\<sigma> y})|\<close>
using union_univ by argo
moreover have \<open>|Sigma (range (inv \<alpha>\<sigma>)) (\<lambda>i. {y. \<alpha>\<sigma> i = \<alpha>\<sigma> y})| \<le>o |UNIV::\<sigma> set|\<close>
using card_of_Sigma_ordLeq_Cinfinite[OF Cinf\<sigma>, OF 1, OF 2] by blast
ultimately have \<open>|UNIV::urrel set set| \<le>o |UNIV::\<sigma> set|\<close>
using ordLeq_transitive by blast
moreover {
have \<open>|UNIV::\<sigma> set| <o |UNIV::\<sigma> set set|\<close>
by auto
moreover have \<open>|UNIV::\<sigma> set set| \<le>o |UNIV::urrel set|\<close>
using card_\<sigma>_set_set_bound by blast
moreover have \<open>|UNIV::urrel set| <o |UNIV::urrel set set|\<close>
by auto
ultimately have \<open>|UNIV::\<sigma> set| <o |UNIV::urrel set set|\<close>
by (metis ordLess_imp_ordLeq ordLess_ordLeq_trans)
}
ultimately have False
using not_ordLeq_ordLess by blast
}
ultimately show False by blast
qed
text\<open>We introduce a mapping from abstract objects (i.e. sets of urrelations) to
special urelements @{text \<open>\<alpha>\<sigma>\<close>} that is surjective and distinguishes all
abstract objects that are distinguished by a (not necessarily surjective)
mapping @{text \<open>\<alpha>\<sigma>'\<close>}. @{text \<open>\<alpha>\<sigma>'\<close>} will be used to model extended relation
comprehension.\<close>
consts \<alpha>\<sigma>' :: \<open>urrel set \<Rightarrow> \<sigma>\<close>
consts \<alpha>\<sigma> :: \<open>urrel set \<Rightarrow> \<sigma>\<close>
specification(\<alpha>\<sigma>)
\<alpha>\<sigma>_surj: \<open>surj \<alpha>\<sigma>\<close>
\<alpha>\<sigma>_\<alpha>\<sigma>': \<open>\<alpha>\<sigma> x = \<alpha>\<sigma> y \<Longrightarrow> \<alpha>\<sigma>' x = \<alpha>\<sigma>' y\<close>
proof -
obtain x where x_prop: \<open>|UNIV::\<sigma> set| <o |{y. \<alpha>\<sigma>' x = \<alpha>\<sigma>' y}|\<close>
using \<alpha>\<sigma>_pigeonhole by blast
have \<open>\<exists>f :: urrel set \<Rightarrow> \<sigma> . f ` {y. \<alpha>\<sigma>' x = \<alpha>\<sigma>' y} = UNIV \<and> f x = \<alpha>\<sigma>' x\<close>
proof -
have \<open>\<exists>f :: urrel set \<Rightarrow> \<sigma> . f ` {y. \<alpha>\<sigma>' x = \<alpha>\<sigma>' y} = UNIV\<close>
by (simp add: x_prop card_of_ordLeq2 ordLess_imp_ordLeq)
then obtain f :: \<open>urrel set \<Rightarrow> \<sigma>\<close> where \<open>f ` {y. \<alpha>\<sigma>' x = \<alpha>\<sigma>' y} = UNIV\<close>
by presburger
moreover obtain a where \<open>f a = \<alpha>\<sigma>' x\<close> and \<open>\<alpha>\<sigma>' a = \<alpha>\<sigma>' x\<close>
by (smt (verit, best) calculation UNIV_I image_iff mem_Collect_eq)
ultimately have \<open>(f (a := f x, x := f a)) ` {y. \<alpha>\<sigma>' x = \<alpha>\<sigma>' y} = UNIV \<and>
(f (a := f x, x := f a)) x = \<alpha>\<sigma>' x\<close>
by (auto simp: image_def)
thus ?thesis by blast
qed
then obtain f where fimage: \<open>f ` {y. \<alpha>\<sigma>' x = \<alpha>\<sigma>' y} = UNIV\<close>
and fx: \<open>f x = \<alpha>\<sigma>' x\<close>
by blast
define \<alpha>\<sigma> :: \<open>urrel set \<Rightarrow> \<sigma>\<close> where
\<open>\<alpha>\<sigma> \<equiv> \<lambda> urrels . if \<alpha>\<sigma>' urrels = \<alpha>\<sigma>' x \<and> f urrels \<notin> range \<alpha>\<sigma>'
then f urrels
else \<alpha>\<sigma>' urrels\<close>
have \<open>surj \<alpha>\<sigma>\<close>
proof -
{
fix s :: \<sigma>
{
assume \<open>s \<in> range \<alpha>\<sigma>'\<close>
hence 0: \<open>\<alpha>\<sigma>' (inv \<alpha>\<sigma>' s) = s\<close>
by (meson f_inv_into_f)
{
assume \<open>s = \<alpha>\<sigma>' x\<close>
hence \<open>\<alpha>\<sigma> x = s\<close>
using \<alpha>\<sigma>_def fx by presburger
hence \<open>\<exists>f . \<alpha>\<sigma> (f s) = s\<close>
by auto
}
moreover {
assume \<open>s \<noteq> \<alpha>\<sigma>' x\<close>
hence \<open>\<alpha>\<sigma> (inv \<alpha>\<sigma>' s) = s\<close>
unfolding \<alpha>\<sigma>_def 0 by presburger
hence \<open>\<exists>f . \<alpha>\<sigma> (f s) = s\<close>
by blast
}
ultimately have \<open>\<exists>f . \<alpha>\<sigma> (f s) = s\<close>
by blast
}
moreover {
assume \<open>s \<notin> range \<alpha>\<sigma>'\<close>
moreover obtain urrels where \<open>f urrels = s\<close> and \<open>\<alpha>\<sigma>' x = \<alpha>\<sigma>' urrels\<close>
by (smt (verit, best) UNIV_I fimage image_iff mem_Collect_eq)
ultimately have \<open>\<alpha>\<sigma> urrels = s\<close>
using \<alpha>\<sigma>_def by presburger
hence \<open>\<exists>f . \<alpha>\<sigma> (f s) = s\<close>
by (meson f_inv_into_f range_eqI)
}
ultimately have \<open>\<exists>f . \<alpha>\<sigma> (f s) = s\<close>
by blast
}
thus ?thesis
by (metis surj_def)
qed
moreover have \<open>\<forall>x y. \<alpha>\<sigma> x = \<alpha>\<sigma> y \<longrightarrow> \<alpha>\<sigma>' x = \<alpha>\<sigma>' y\<close>
by (metis \<alpha>\<sigma>_def rangeI)
ultimately show ?thesis
by blast
qed
text\<open>For extended models that validate extended relation comprehension
(and consequently the predecessor axiom), we specify which
abstract objects are distinguished by @{const \<alpha>\<sigma>'}.\<close>
definition urrel_to_\<omega>rel :: \<open>urrel \<Rightarrow> (\<omega> \<Rightarrow> w \<Rightarrow> bool)\<close> where
\<open>urrel_to_\<omega>rel \<equiv> \<lambda> r u w . AOT_model_valid_in w (Rep_urrel r (\<omega>\<upsilon> u))\<close>
definition \<omega>rel_to_urrel :: \<open>(\<omega> \<Rightarrow> w \<Rightarrow> bool) \<Rightarrow> urrel\<close> where
\<open>\<omega>rel_to_urrel \<equiv> \<lambda> \<phi> . Abs_urrel
(\<lambda> u . \<epsilon>\<^sub>\<o> w . case u of \<omega>\<upsilon> x \<Rightarrow> \<phi> x w | _ \<Rightarrow> False)\<close>
definition AOT_urrel_\<omega>equiv :: \<open>urrel \<Rightarrow> urrel \<Rightarrow> bool\<close> where
\<open>AOT_urrel_\<omega>equiv \<equiv> \<lambda> r s . \<forall> u v . AOT_model_valid_in v (Rep_urrel r (\<omega>\<upsilon> u)) =
AOT_model_valid_in v (Rep_urrel s (\<omega>\<upsilon> u))\<close>
lemma urrel_\<omega>rel_quot: \<open>Quotient3 AOT_urrel_\<omega>equiv urrel_to_\<omega>rel \<omega>rel_to_urrel\<close>
proof(rule Quotient3I)
show \<open>urrel_to_\<omega>rel (\<omega>rel_to_urrel a) = a\<close> for a
unfolding \<omega>rel_to_urrel_def urrel_to_\<omega>rel_def
apply (rule ext)
apply (subst Abs_urrel_inverse)
by (auto simp: AOT_model_proposition_choice_simp)
next
show \<open>AOT_urrel_\<omega>equiv (\<omega>rel_to_urrel a) (\<omega>rel_to_urrel a)\<close> for a
unfolding \<omega>rel_to_urrel_def AOT_urrel_\<omega>equiv_def
apply (subst (1 2) Abs_urrel_inverse)
by (auto simp: AOT_model_proposition_choice_simp)
next
show \<open>AOT_urrel_\<omega>equiv r s = (AOT_urrel_\<omega>equiv r r \<and> AOT_urrel_\<omega>equiv s s \<and>
urrel_to_\<omega>rel r = urrel_to_\<omega>rel s)\<close> for r s
proof
assume \<open>AOT_urrel_\<omega>equiv r s\<close>
hence \<open>AOT_model_valid_in v (Rep_urrel r (\<omega>\<upsilon> u)) =
AOT_model_valid_in v (Rep_urrel s (\<omega>\<upsilon> u))\<close> for u v
using AOT_urrel_\<omega>equiv_def by metis
hence \<open>urrel_to_\<omega>rel r = urrel_to_\<omega>rel s\<close>
unfolding urrel_to_\<omega>rel_def
by simp
thus \<open>AOT_urrel_\<omega>equiv r r \<and> AOT_urrel_\<omega>equiv s s \<and>
urrel_to_\<omega>rel r = urrel_to_\<omega>rel s\<close>
unfolding AOT_urrel_\<omega>equiv_def
by auto
next
assume \<open>AOT_urrel_\<omega>equiv r r \<and> AOT_urrel_\<omega>equiv s s \<and>
urrel_to_\<omega>rel r = urrel_to_\<omega>rel s\<close>
hence \<open>AOT_model_valid_in v (Rep_urrel r (\<omega>\<upsilon> u)) =
AOT_model_valid_in v (Rep_urrel s (\<omega>\<upsilon> u))\<close> for u v
by (metis urrel_to_\<omega>rel_def)
thus \<open>AOT_urrel_\<omega>equiv r s\<close>
using AOT_urrel_\<omega>equiv_def by presburger
qed
qed
specification (\<alpha>\<sigma>')
\<alpha>\<sigma>_eq_ord_exts_all:
\<open>\<alpha>\<sigma>' a = \<alpha>\<sigma>' b \<Longrightarrow> (\<And>s . urrel_to_\<omega>rel s = urrel_to_\<omega>rel r \<Longrightarrow> s \<in> a)
\<Longrightarrow> (\<And> s . urrel_to_\<omega>rel s = urrel_to_\<omega>rel r \<Longrightarrow> s \<in> b)\<close>
\<alpha>\<sigma>_eq_ord_exts_ex:
\<open>\<alpha>\<sigma>' a = \<alpha>\<sigma>' b \<Longrightarrow> (\<exists> s . s \<in> a \<and> urrel_to_\<omega>rel s = urrel_to_\<omega>rel r)
\<Longrightarrow> (\<exists>s . s \<in> b \<and> urrel_to_\<omega>rel s = urrel_to_\<omega>rel r)\<close>
proof -
define \<alpha>\<sigma>_wit_intersection where
\<open>\<alpha>\<sigma>_wit_intersection \<equiv> \<lambda> urrels .
{ordext . \<forall>urrel . urrel_to_\<omega>rel urrel = ordext \<longrightarrow> urrel \<in> urrels}\<close>
define \<alpha>\<sigma>_wit_union where
\<open>\<alpha>\<sigma>_wit_union \<equiv> \<lambda> urrels .
{ordext . \<exists>urrel\<in>urrels . urrel_to_\<omega>rel urrel = ordext}\<close>
let ?\<alpha>\<sigma>_wit = \<open>\<lambda> urrels .
let ordexts = \<alpha>\<sigma>_wit_intersection urrels in
let ordexts' = \<alpha>\<sigma>_wit_union urrels in
(ordexts, ordexts', undefined)\<close>
define \<alpha>\<sigma>_wit :: \<open>urrel set \<Rightarrow> \<sigma>\<close> where
\<open>\<alpha>\<sigma>_wit \<equiv> \<lambda> urrels . Abs_\<sigma> (?\<alpha>\<sigma>_wit urrels)\<close>
{
fix a b :: \<open>urrel set\<close> and r s
assume \<open>\<alpha>\<sigma>_wit a = \<alpha>\<sigma>_wit b\<close>
hence 0: \<open>{ordext. \<forall>urrel. urrel_to_\<omega>rel urrel = ordext \<longrightarrow> urrel \<in> a} =
{ordext. \<forall>urrel. urrel_to_\<omega>rel urrel = ordext \<longrightarrow> urrel \<in> b}\<close>
unfolding \<alpha>\<sigma>_wit_def Let_def
apply (subst (asm) Abs_\<sigma>_inject)
by (auto simp: \<alpha>\<sigma>_wit_intersection_def \<alpha>\<sigma>_wit_union_def)
assume \<open>urrel_to_\<omega>rel s = urrel_to_\<omega>rel r \<Longrightarrow> s \<in> a\<close> for s
hence \<open>urrel_to_\<omega>rel r \<in>
{ordext. \<forall>urrel. urrel_to_\<omega>rel urrel = ordext \<longrightarrow> urrel \<in> a}\<close>
by auto
hence \<open>urrel_to_\<omega>rel r \<in>
{ordext. \<forall>urrel. urrel_to_\<omega>rel urrel = ordext \<longrightarrow> urrel \<in> b}\<close>
using 0 by blast
moreover assume \<open>urrel_to_\<omega>rel s = urrel_to_\<omega>rel r\<close>
ultimately have \<open>s \<in> b\<close>
by blast
}
moreover {
fix a b :: \<open>urrel set\<close> and s r
assume \<open>\<alpha>\<sigma>_wit a = \<alpha>\<sigma>_wit b\<close>
hence 0: \<open>{ordext. \<exists>urrel \<in> a. urrel_to_\<omega>rel urrel = ordext} =
{ordext. \<exists>urrel \<in> b. urrel_to_\<omega>rel urrel = ordext}\<close>
unfolding \<alpha>\<sigma>_wit_def
apply (subst (asm) Abs_\<sigma>_inject)
by (auto simp: Let_def \<alpha>\<sigma>_wit_intersection_def \<alpha>\<sigma>_wit_union_def)
assume \<open>s \<in> a\<close>
hence \<open>urrel_to_\<omega>rel s \<in> {ordext. \<exists>urrel \<in> a. urrel_to_\<omega>rel urrel = ordext}\<close>
by blast
moreover assume \<open>urrel_to_\<omega>rel s = urrel_to_\<omega>rel r\<close>
ultimately have \<open>urrel_to_\<omega>rel r \<in>
{ordext. \<exists>urrel \<in> b. urrel_to_\<omega>rel urrel = ordext}\<close>
using "0" by argo
hence \<open>\<exists>s. s \<in> b \<and> urrel_to_\<omega>rel s = urrel_to_\<omega>rel r\<close>
by blast
}
ultimately show ?thesis
by (safe intro!: exI[where x=\<alpha>\<sigma>_wit]; metis)
qed
text\<open>We enable the extended model version.\<close>
abbreviation (input) AOT_ExtendedModel where \<open>AOT_ExtendedModel \<equiv> True\<close>
text\<open>Individual terms are either ordinary objects, represented by ordinary urelements,
abstract objects, modelled as sets of urrelations, or null objects, used to
represent non-denoting definite descriptions.\<close>
datatype \<kappa> = \<omega>\<kappa> \<omega> | \<alpha>\<kappa> \<open>urrel set\<close> | is_null\<kappa>: null\<kappa> null
text\<open>The mapping from abstract objects to urelements can be naturally
lifted to a surjective mapping from individual terms to urelements.\<close>
primrec \<kappa>\<upsilon> :: \<open>\<kappa>\<Rightarrow>\<upsilon>\<close> where
\<open>\<kappa>\<upsilon> (\<omega>\<kappa> x) = \<omega>\<upsilon> x\<close>
| \<open>\<kappa>\<upsilon> (\<alpha>\<kappa> x) = \<sigma>\<upsilon> (\<alpha>\<sigma> x)\<close>
| \<open>\<kappa>\<upsilon> (null\<kappa> x) = null\<upsilon> x\<close>
lemma \<kappa>\<upsilon>_surj: \<open>surj \<kappa>\<upsilon>\<close>
using \<alpha>\<sigma>_surj by (metis \<kappa>\<upsilon>.simps(1) \<kappa>\<upsilon>.simps(2) \<kappa>\<upsilon>.simps(3) \<upsilon>.exhaust surj_def)
text\<open>By construction if the urelement of an individual term is exemplified by
an urrelation, it cannot be a null-object.\<close>
lemma urrel_null_false:
assumes \<open>AOT_model_valid_in w (Rep_urrel f (\<kappa>\<upsilon> x))\<close>
shows \<open>\<not>is_null\<kappa> x\<close>
by (metis (mono_tags, lifting) assms Rep_urrel \<kappa>.collapse(3) \<kappa>\<upsilon>.simps(3)
mem_Collect_eq)
text\<open>AOT requires any ordinary object to be @{emph \<open>possibly concrete\<close>} and that
there is an object that is not actually, but possibly concrete.\<close>
consts AOT_model_concrete\<omega> :: \<open>\<omega> \<Rightarrow> w \<Rightarrow> bool\<close>
specification (AOT_model_concrete\<omega>)
AOT_model_\<omega>_concrete_in_some_world:
\<open>\<exists> w . AOT_model_concrete\<omega> x w\<close>
AOT_model_contingent_object:
\<open>\<exists> x w . AOT_model_concrete\<omega> x w \<and> \<not>AOT_model_concrete\<omega> x w\<^sub>0\<close>
by (rule exI[where x=\<open>\<lambda>_ w. w \<noteq> w\<^sub>0\<close>]) (auto simp: AOT_model_nonactual_world)
text\<open>We define a type class for AOT's terms specifying the conditions under which
objects of that type denote and require the set of denoting terms to be
non-empty.\<close>
class AOT_Term =
fixes AOT_model_denotes :: \<open>'a \<Rightarrow> bool\<close>
assumes AOT_model_denoting_ex: \<open>\<exists> x . AOT_model_denotes x\<close>
text\<open>All types except the type of propositions involve non-denoting terms. We
define a refined type class for those.\<close>
class AOT_IncompleteTerm = AOT_Term +
assumes AOT_model_nondenoting_ex: \<open>\<exists> x . \<not>AOT_model_denotes x\<close>
text\<open>Generic non-denoting term.\<close>
definition AOT_model_nondenoting :: \<open>'a::AOT_IncompleteTerm\<close> where
\<open>AOT_model_nondenoting \<equiv> SOME \<tau> . \<not>AOT_model_denotes \<tau>\<close>
lemma AOT_model_nondenoing: \<open>\<not>AOT_model_denotes (AOT_model_nondenoting)\<close>
using someI_ex[OF AOT_model_nondenoting_ex]
unfolding AOT_model_nondenoting_def by blast
text\<open>@{const AOT_model_denotes} can trivially be extended to products of types.\<close>
instantiation prod :: (AOT_Term, AOT_Term) AOT_Term
begin
definition AOT_model_denotes_prod :: \<open>'a\<times>'b \<Rightarrow> bool\<close> where
\<open>AOT_model_denotes_prod \<equiv> \<lambda>(x,y) . AOT_model_denotes x \<and> AOT_model_denotes y\<close>
instance proof
show \<open>\<exists>x::'a\<times>'b. AOT_model_denotes x\<close>
by (simp add: AOT_model_denotes_prod_def AOT_model_denoting_ex)
qed
end
text\<open>We specify a transformation of proposition-valued functions on terms, s.t.
the result is fully determined by @{emph \<open>regular\<close>} terms. This will be required
for modelling n-ary relations as functions on tuples while preserving AOT's
definition of n-ary relation identity.\<close>
locale AOT_model_irregular_spec =
fixes AOT_model_irregular :: \<open>('a \<Rightarrow> \<o>) \<Rightarrow> 'a \<Rightarrow> \<o>\<close>
and AOT_model_regular :: \<open>'a \<Rightarrow> bool\<close>
and AOT_model_term_equiv :: \<open>'a \<Rightarrow> 'a \<Rightarrow> bool\<close>
assumes AOT_model_irregular_false:
\<open>\<not>AOT_model_valid_in w (AOT_model_irregular \<phi> x)\<close>
assumes AOT_model_irregular_equiv:
\<open>AOT_model_term_equiv x y \<Longrightarrow>
AOT_model_irregular \<phi> x = AOT_model_irregular \<phi> y\<close>
assumes AOT_model_irregular_eqI:
\<open>(\<And> x . AOT_model_regular x \<Longrightarrow> \<phi> x = \<psi> x) \<Longrightarrow>
AOT_model_irregular \<phi> x = AOT_model_irregular \<psi> x\<close>
text\<open>We introduce a type class for individual terms that specifies being regular,
being equivalent (i.e. conceptually @{emph \<open>sharing urelements\<close>}) and the
transformation on proposition-valued functions as specified above.\<close>
class AOT_IndividualTerm = AOT_IncompleteTerm +
fixes AOT_model_regular :: \<open>'a \<Rightarrow> bool\<close>
fixes AOT_model_term_equiv :: \<open>'a \<Rightarrow> 'a \<Rightarrow> bool\<close>
fixes AOT_model_irregular :: \<open>('a \<Rightarrow> \<o>) \<Rightarrow> 'a \<Rightarrow> \<o>\<close>
assumes AOT_model_irregular_nondenoting:
\<open>\<not>AOT_model_regular x \<Longrightarrow> \<not>AOT_model_denotes x\<close>
assumes AOT_model_term_equiv_part_equivp:
\<open>equivp AOT_model_term_equiv\<close>
assumes AOT_model_term_equiv_denotes:
\<open>AOT_model_term_equiv x y \<Longrightarrow> (AOT_model_denotes x = AOT_model_denotes y)\<close>
assumes AOT_model_term_equiv_regular:
\<open>AOT_model_term_equiv x y \<Longrightarrow> (AOT_model_regular x = AOT_model_regular y)\<close>
assumes AOT_model_irregular:
\<open>AOT_model_irregular_spec AOT_model_irregular AOT_model_regular
AOT_model_term_equiv\<close>
interpretation AOT_model_irregular_spec AOT_model_irregular AOT_model_regular
AOT_model_term_equiv
using AOT_model_irregular .
text\<open>Our concrete type for individual terms satisfies the type class of
individual terms.
Note that all unary individuals are regular. In general, an individual term
may be a tuple and is regular, if at most one tuple element does not denote.\<close>
instantiation \<kappa> :: AOT_IndividualTerm
begin
definition AOT_model_term_equiv_\<kappa> :: \<open>\<kappa> \<Rightarrow> \<kappa> \<Rightarrow> bool\<close> where
\<open>AOT_model_term_equiv_\<kappa> \<equiv> \<lambda> x y . \<kappa>\<upsilon> x = \<kappa>\<upsilon> y\<close>
definition AOT_model_denotes_\<kappa> :: \<open>\<kappa> \<Rightarrow> bool\<close> where
\<open>AOT_model_denotes_\<kappa> \<equiv> \<lambda> x . \<not>is_null\<kappa> x\<close>
definition AOT_model_regular_\<kappa> :: \<open>\<kappa> \<Rightarrow> bool\<close> where
\<open>AOT_model_regular_\<kappa> \<equiv> \<lambda> x . True\<close>
definition AOT_model_irregular_\<kappa> :: \<open>(\<kappa> \<Rightarrow> \<o>) \<Rightarrow> \<kappa> \<Rightarrow> \<o>\<close> where
\<open>AOT_model_irregular_\<kappa> \<equiv> SOME \<phi> . AOT_model_irregular_spec \<phi>
AOT_model_regular AOT_model_term_equiv\<close>
instance proof
show \<open>\<exists>x :: \<kappa>. AOT_model_denotes x\<close>
by (rule exI[where x=\<open>\<omega>\<kappa> undefined\<close>])
(simp add: AOT_model_denotes_\<kappa>_def)
next
show \<open>\<exists>x :: \<kappa>. \<not>AOT_model_denotes x\<close>
by (rule exI[where x=\<open>null\<kappa> undefined\<close>])
(simp add: AOT_model_denotes_\<kappa>_def AOT_model_regular_\<kappa>_def)
next
show "\<not>AOT_model_regular x \<Longrightarrow> \<not> AOT_model_denotes x" for x :: \<kappa>
by (simp add: AOT_model_regular_\<kappa>_def)
next
show \<open>equivp (AOT_model_term_equiv :: \<kappa> \<Rightarrow> \<kappa> \<Rightarrow> bool)\<close>
by (rule equivpI; rule reflpI exI sympI transpI)
(simp_all add: AOT_model_term_equiv_\<kappa>_def)
next
fix x y :: \<kappa>
show \<open>AOT_model_term_equiv x y \<Longrightarrow> AOT_model_denotes x = AOT_model_denotes y\<close>
by (metis AOT_model_denotes_\<kappa>_def AOT_model_term_equiv_\<kappa>_def \<kappa>.exhaust_disc
\<kappa>\<upsilon>.simps \<upsilon>.disc(1,3,5,6) is_\<alpha>\<kappa>_def is_\<omega>\<kappa>_def is_null\<kappa>_def)
next
fix x y :: \<kappa>
show \<open>AOT_model_term_equiv x y \<Longrightarrow> AOT_model_regular x = AOT_model_regular y\<close>
by (simp add: AOT_model_regular_\<kappa>_def)
next
have "AOT_model_irregular_spec (\<lambda> \<phi> (x::\<kappa>) . \<epsilon>\<^sub>\<o> w . False)
AOT_model_regular AOT_model_term_equiv"
by standard (auto simp: AOT_model_proposition_choice_simp)
thus \<open>AOT_model_irregular_spec (AOT_model_irregular::(\<kappa>\<Rightarrow>\<o>) \<Rightarrow> \<kappa> \<Rightarrow> \<o>)
AOT_model_regular AOT_model_term_equiv\<close>
unfolding AOT_model_irregular_\<kappa>_def by (metis (no_types, lifting) someI_ex)
qed
end
text\<open>We define relations among individuals as proposition valued functions.
@{emph \<open>Denoting\<close>} unary relations (among @{typ \<kappa>}) will match the
urrelations introduced above.\<close>
typedef 'a rel (\<open><_>\<close>) = \<open>UNIV::('a::AOT_IndividualTerm \<Rightarrow> \<o>) set\<close> ..
setup_lifting type_definition_rel
text\<open>We will use the transformation specified above to "fix" the behaviour of
functions on irregular terms when defining @{text \<open>\<lambda>\<close>}-expressions.\<close>
definition fix_irregular :: \<open>('a::AOT_IndividualTerm \<Rightarrow> \<o>) \<Rightarrow> ('a \<Rightarrow> \<o>)\<close> where
\<open>fix_irregular \<equiv> \<lambda> \<phi> x . if AOT_model_regular x
then \<phi> x else AOT_model_irregular \<phi> x\<close>
lemma fix_irregular_denoting:
\<open>AOT_model_denotes x \<Longrightarrow> fix_irregular \<phi> x = \<phi> x\<close>
by (meson AOT_model_irregular_nondenoting fix_irregular_def)
lemma fix_irregular_regular:
\<open>AOT_model_regular x \<Longrightarrow> fix_irregular \<phi> x = \<phi> x\<close>
by (meson AOT_model_irregular_nondenoting fix_irregular_def)
lemma fix_irregular_irregular:
\<open>\<not>AOT_model_regular x \<Longrightarrow> fix_irregular \<phi> x = AOT_model_irregular \<phi> x\<close>
by (simp add: fix_irregular_def)
text\<open>Relations among individual terms are (potentially non-denoting) terms.
A relation denotes, if it agrees on all equivalent terms (i.e. terms sharing
urelements), is necessarily false on all non-denoting terms and is
well-behaved on irregular terms.\<close>
instantiation rel :: (AOT_IndividualTerm) AOT_IncompleteTerm
begin
text\<open>\linelabel{AOT_model_denotes_rel}\<close>
lift_definition AOT_model_denotes_rel :: \<open><'a> \<Rightarrow> bool\<close> is
\<open>\<lambda> \<phi> . (\<forall> x y . AOT_model_term_equiv x y \<longrightarrow> \<phi> x = \<phi> y) \<and>
(\<forall> w x . AOT_model_valid_in w (\<phi> x) \<longrightarrow> AOT_model_denotes x) \<and>
(\<forall> x . \<not>AOT_model_regular x \<longrightarrow> \<phi> x = AOT_model_irregular \<phi> x)\<close> .
instance proof
have \<open>AOT_model_irregular (fix_irregular \<phi>) x = AOT_model_irregular \<phi> x\<close>
for \<phi> and x :: 'a
by (rule AOT_model_irregular_eqI) (simp add: fix_irregular_def)
thus \<open>\<exists> x :: <'a> . AOT_model_denotes x\<close>
by (safe intro!: exI[where x=\<open>Abs_rel (fix_irregular (\<lambda>x. \<epsilon>\<^sub>\<o> w . False))\<close>])
(transfer; auto simp: AOT_model_proposition_choice_simp fix_irregular_def
AOT_model_irregular_equiv AOT_model_term_equiv_regular
AOT_model_irregular_false)
next
show \<open>\<exists>f :: <'a> . \<not>AOT_model_denotes f\<close>
by (rule exI[where x=\<open>Abs_rel (\<lambda>x. \<epsilon>\<^sub>\<o> w . True)\<close>];
auto simp: AOT_model_denotes_rel.abs_eq AOT_model_nondenoting_ex
AOT_model_proposition_choice_simp)
qed
end
text\<open>Auxiliary lemmata.\<close>
lemma AOT_model_term_equiv_eps:
shows \<open>AOT_model_term_equiv (Eps (AOT_model_term_equiv \<kappa>)) \<kappa>\<close>
and \<open>AOT_model_term_equiv \<kappa> (Eps (AOT_model_term_equiv \<kappa>))\<close>
and \<open>AOT_model_term_equiv \<kappa> \<kappa>' \<Longrightarrow>
(Eps (AOT_model_term_equiv \<kappa>)) = (Eps (AOT_model_term_equiv \<kappa>'))\<close>
apply (metis AOT_model_term_equiv_part_equivp equivp_def someI_ex)
apply (metis AOT_model_term_equiv_part_equivp equivp_def someI_ex)
by (metis AOT_model_term_equiv_part_equivp equivp_def)
lemma AOT_model_denotes_Abs_rel_fix_irregularI:
assumes \<open>\<And> x y . AOT_model_term_equiv x y \<Longrightarrow> \<phi> x = \<phi> y\<close>
and \<open>\<And> w x . AOT_model_valid_in w (\<phi> x) \<Longrightarrow> AOT_model_denotes x\<close>
shows \<open>AOT_model_denotes (Abs_rel (fix_irregular \<phi>))\<close>
proof -
have \<open>AOT_model_irregular \<phi> x = AOT_model_irregular
(\<lambda>x. if AOT_model_regular x then \<phi> x else AOT_model_irregular \<phi> x) x\<close>
if \<open>\<not> AOT_model_regular x\<close>
for x
by (rule AOT_model_irregular_eqI) auto
thus ?thesis
unfolding AOT_model_denotes_rel.rep_eq
using assms by (auto simp: AOT_model_irregular_false Abs_rel_inverse
AOT_model_irregular_equiv fix_irregular_def
AOT_model_term_equiv_regular)
qed
lemma AOT_model_term_equiv_rel_equiv:
assumes \<open>AOT_model_denotes x\<close>
and \<open>AOT_model_denotes y\<close>
shows \<open>AOT_model_term_equiv x y = (\<forall> \<Pi> w . AOT_model_denotes \<Pi> \<longrightarrow>
AOT_model_valid_in w (Rep_rel \<Pi> x) = AOT_model_valid_in w (Rep_rel \<Pi> y))\<close>
proof
assume \<open>AOT_model_term_equiv x y\<close>
thus \<open>\<forall> \<Pi> w . AOT_model_denotes \<Pi> \<longrightarrow> AOT_model_valid_in w (Rep_rel \<Pi> x) =
AOT_model_valid_in w (Rep_rel \<Pi> y)\<close>
by (simp add: AOT_model_denotes_rel.rep_eq)
next
have 0: \<open>(AOT_model_denotes x' \<and> AOT_model_term_equiv x' y) =
(AOT_model_denotes y' \<and> AOT_model_term_equiv y' y)\<close>
if \<open>AOT_model_term_equiv x' y'\<close> for x' y'
by (metis that AOT_model_term_equiv_denotes AOT_model_term_equiv_part_equivp
equivp_def)
assume \<open>\<forall> \<Pi> w . AOT_model_denotes \<Pi> \<longrightarrow> AOT_model_valid_in w (Rep_rel \<Pi> x) =
AOT_model_valid_in w (Rep_rel \<Pi> y)\<close>
moreover have \<open>AOT_model_denotes (Abs_rel (fix_irregular
(\<lambda> x . \<epsilon>\<^sub>\<o> w . AOT_model_denotes x \<and> AOT_model_term_equiv x y)))\<close>
(is "AOT_model_denotes ?r")
by (rule AOT_model_denotes_Abs_rel_fix_irregularI)
(auto simp: 0 AOT_model_denotes_rel.rep_eq Abs_rel_inverse fix_irregular_def
AOT_model_proposition_choice_simp AOT_model_irregular_false)
ultimately have \<open>AOT_model_valid_in w (Rep_rel ?r x) =
AOT_model_valid_in w (Rep_rel ?r y)\<close> for w
by blast
thus \<open>AOT_model_term_equiv x y\<close>
by (simp add: Abs_rel_inverse AOT_model_proposition_choice_simp
fix_irregular_denoting[OF assms(1)] AOT_model_term_equiv_part_equivp
fix_irregular_denoting[OF assms(2)] assms equivp_reflp)
qed
text\<open>Denoting relations among terms of type @{typ \<kappa>} correspond to urrelations.\<close>
definition rel_to_urrel :: \<open><\<kappa>> \<Rightarrow> urrel\<close> where
\<open>rel_to_urrel \<equiv> \<lambda> \<Pi> . Abs_urrel (\<lambda> u . Rep_rel \<Pi> (SOME x . \<kappa>\<upsilon> x = u))\<close>
definition urrel_to_rel :: \<open>urrel \<Rightarrow> <\<kappa>>\<close> where
\<open>urrel_to_rel \<equiv> \<lambda> \<phi> . Abs_rel (\<lambda> x . Rep_urrel \<phi> (\<kappa>\<upsilon> x))\<close>
definition AOT_rel_equiv :: \<open><'a::AOT_IndividualTerm> \<Rightarrow> <'a> \<Rightarrow> bool\<close> where
\<open>AOT_rel_equiv \<equiv> \<lambda> f g . AOT_model_denotes f \<and> AOT_model_denotes g \<and> f = g\<close>
lemma urrel_quotient3: \<open>Quotient3 AOT_rel_equiv rel_to_urrel urrel_to_rel\<close>
proof (rule Quotient3I)
have \<open>(\<lambda>u. Rep_urrel a (\<kappa>\<upsilon> (SOME x. \<kappa>\<upsilon> x = u))) = (\<lambda>u. Rep_urrel a u)\<close> for a
by (rule ext) (metis (mono_tags, lifting) \<kappa>\<upsilon>_surj surj_f_inv_f verit_sko_ex')
thus \<open>rel_to_urrel (urrel_to_rel a) = a\<close> for a
by (simp add: Abs_rel_inverse rel_to_urrel_def urrel_to_rel_def
Rep_urrel_inverse)
next
show \<open>AOT_rel_equiv (urrel_to_rel a) (urrel_to_rel a)\<close> for a
unfolding AOT_rel_equiv_def urrel_to_rel_def
by transfer (simp add: AOT_model_regular_\<kappa>_def AOT_model_denotes_\<kappa>_def
AOT_model_term_equiv_\<kappa>_def urrel_null_false)
next
{
fix a
assume \<open>\<forall>w x. AOT_model_valid_in w (a x) \<longrightarrow> \<not> is_null\<kappa> x\<close>
hence \<open>(\<lambda>u. a (SOME x. \<kappa>\<upsilon> x = u)) \<in>
{\<phi>. \<forall>x w. \<not> AOT_model_valid_in w (\<phi> (null\<upsilon> x))}\<close>
by (simp; metis (mono_tags, lifting) \<kappa>.exhaust_disc \<kappa>\<upsilon>.simps \<upsilon>.disc(1,3,5)
\<upsilon>.disc(6) is_\<alpha>\<kappa>_def is_\<omega>\<kappa>_def someI_ex)
} note 1 = this
{
fix r s :: \<open>\<kappa> \<Rightarrow> \<o>\<close>
assume A: \<open>\<forall>x y. AOT_model_term_equiv x y \<longrightarrow> r x = r y\<close>
assume \<open>\<forall>w x. AOT_model_valid_in w (r x) \<longrightarrow> AOT_model_denotes x\<close>
hence 2: \<open>(\<lambda>u. r (SOME x. \<kappa>\<upsilon> x = u)) \<in>
{\<phi>. \<forall>x w. \<not> AOT_model_valid_in w (\<phi> (null\<upsilon> x))}\<close>
using 1 AOT_model_denotes_\<kappa>_def by meson
assume B: \<open>\<forall>x y. AOT_model_term_equiv x y \<longrightarrow> s x = s y\<close>
assume \<open>\<forall>w x. AOT_model_valid_in w (s x) \<longrightarrow> AOT_model_denotes x\<close>
hence 3: \<open>(\<lambda>u. s (SOME x. \<kappa>\<upsilon> x = u)) \<in>
{\<phi>. \<forall>x w. \<not> AOT_model_valid_in w (\<phi> (null\<upsilon> x))}\<close>
using 1 AOT_model_denotes_\<kappa>_def by meson
assume \<open>Abs_urrel (\<lambda>u. r (SOME x. \<kappa>\<upsilon> x = u)) =
Abs_urrel (\<lambda>u. s (SOME x. \<kappa>\<upsilon> x = u))\<close>
hence 4: \<open>r (SOME x. \<kappa>\<upsilon> x = u) = s (SOME x::\<kappa>. \<kappa>\<upsilon> x = u)\<close> for u
unfolding Abs_urrel_inject[OF 2 3] by metis
have \<open>r x = s x\<close> for x
using 4[of \<open>\<kappa>\<upsilon> x\<close>]
by (metis (mono_tags, lifting) A B AOT_model_term_equiv_\<kappa>_def someI_ex)
hence \<open>r = s\<close> by auto
}
thus \<open>AOT_rel_equiv r s = (AOT_rel_equiv r r \<and> AOT_rel_equiv s s \<and>
rel_to_urrel r = rel_to_urrel s)\<close> for r s
unfolding AOT_rel_equiv_def rel_to_urrel_def
by transfer auto
qed
lemma urrel_quotient:
\<open>Quotient AOT_rel_equiv rel_to_urrel urrel_to_rel
(\<lambda>x y. AOT_rel_equiv x x \<and> rel_to_urrel x = y)\<close>
using Quotient3_to_Quotient[OF urrel_quotient3] by auto
text\<open>Unary individual terms are always regular and equipped with encoding and
concreteness. The specification of the type class anticipates the required
properties for deriving the axiom system.\<close>
class AOT_UnaryIndividualTerm =
fixes AOT_model_enc :: \<open>'a \<Rightarrow> <'a::AOT_IndividualTerm> \<Rightarrow> bool\<close>
and AOT_model_concrete :: \<open>w \<Rightarrow> 'a \<Rightarrow> bool\<close>
assumes AOT_model_unary_regular:
\<open>AOT_model_regular x\<close> \<comment> \<open>All unary individual terms are regular.\<close>
and AOT_model_enc_relid:
\<open>AOT_model_denotes F \<Longrightarrow>
AOT_model_denotes G \<Longrightarrow>
(\<And> x . AOT_model_enc x F \<longleftrightarrow> AOT_model_enc x G)
\<Longrightarrow> F = G\<close>
and AOT_model_A_objects:
\<open>\<exists>x . AOT_model_denotes x \<and>
(\<forall>w. \<not> AOT_model_concrete w x) \<and>
(\<forall>F. AOT_model_denotes F \<longrightarrow> AOT_model_enc x F = \<phi> F)\<close>
and AOT_model_contingent:
\<open>\<exists> x w. AOT_model_concrete w x \<and> \<not> AOT_model_concrete w\<^sub>0 x\<close>
and AOT_model_nocoder:
\<open>AOT_model_concrete w x \<Longrightarrow> \<not>AOT_model_enc x F\<close>
and AOT_model_concrete_equiv:
\<open>AOT_model_term_equiv x y \<Longrightarrow>
AOT_model_concrete w x = AOT_model_concrete w y\<close>
and AOT_model_concrete_denotes:
\<open>AOT_model_concrete w x \<Longrightarrow> AOT_model_denotes x\<close>
\<comment> \<open>The following are properties that will only hold in the extended models.\<close>
and AOT_model_enc_indistinguishable_all:
\<open>AOT_ExtendedModel \<Longrightarrow>
AOT_model_denotes a \<Longrightarrow> \<not>(\<exists> w . AOT_model_concrete w a) \<Longrightarrow>
AOT_model_denotes b \<Longrightarrow> \<not>(\<exists> w . AOT_model_concrete w b) \<Longrightarrow>
AOT_model_denotes \<Pi> \<Longrightarrow>
(\<And> \<Pi>' . AOT_model_denotes \<Pi>' \<Longrightarrow>
(\<And> v . AOT_model_valid_in v (Rep_rel \<Pi>' a) =
AOT_model_valid_in v (Rep_rel \<Pi>' b))) \<Longrightarrow>
(\<And> \<Pi>' . AOT_model_denotes \<Pi>' \<Longrightarrow>
(\<And> v x . \<exists> w . AOT_model_concrete w x \<Longrightarrow>
AOT_model_valid_in v (Rep_rel \<Pi>' x) =
AOT_model_valid_in v (Rep_rel \<Pi> x)) \<Longrightarrow>
AOT_model_enc a \<Pi>') \<Longrightarrow>
(\<And> \<Pi>' . AOT_model_denotes \<Pi>' \<Longrightarrow>
(\<And> v x . \<exists> w . AOT_model_concrete w x \<Longrightarrow>
AOT_model_valid_in v (Rep_rel \<Pi>' x) =
AOT_model_valid_in v (Rep_rel \<Pi> x)) \<Longrightarrow>
AOT_model_enc b \<Pi>')\<close>
and AOT_model_enc_indistinguishable_ex:
\<open>AOT_ExtendedModel \<Longrightarrow>
AOT_model_denotes a \<Longrightarrow> \<not>(\<exists> w . AOT_model_concrete w a) \<Longrightarrow>
AOT_model_denotes b \<Longrightarrow> \<not>(\<exists> w . AOT_model_concrete w b) \<Longrightarrow>
AOT_model_denotes \<Pi> \<Longrightarrow>
(\<And> \<Pi>' . AOT_model_denotes \<Pi>' \<Longrightarrow>
(\<And> v . AOT_model_valid_in v (Rep_rel \<Pi>' a) =
AOT_model_valid_in v (Rep_rel \<Pi>' b))) \<Longrightarrow>
(\<exists> \<Pi>' . AOT_model_denotes \<Pi>' \<and> AOT_model_enc a \<Pi>' \<and>
(\<forall> v x . (\<exists> w . AOT_model_concrete w x) \<longrightarrow>
AOT_model_valid_in v (Rep_rel \<Pi>' x) =
AOT_model_valid_in v (Rep_rel \<Pi> x))) \<Longrightarrow>
(\<exists> \<Pi>' . AOT_model_denotes \<Pi>' \<and> AOT_model_enc b \<Pi>' \<and>
(\<forall> v x . (\<exists> w . AOT_model_concrete w x) \<longrightarrow>
AOT_model_valid_in v (Rep_rel \<Pi>' x) =
AOT_model_valid_in v (Rep_rel \<Pi> x)))\<close>
text\<open>Instantiate the class of unary individual terms for our concrete type of
individual terms @{typ \<kappa>}.\<close>
instantiation \<kappa> :: AOT_UnaryIndividualTerm
begin
definition AOT_model_enc_\<kappa> :: \<open>\<kappa> \<Rightarrow> <\<kappa>> \<Rightarrow> bool\<close> where
\<open>AOT_model_enc_\<kappa> \<equiv> \<lambda> x F .
case x of \<alpha>\<kappa> a \<Rightarrow> AOT_model_denotes F \<and> rel_to_urrel F \<in> a
| _ \<Rightarrow> False\<close>
primrec AOT_model_concrete_\<kappa> :: \<open>w \<Rightarrow> \<kappa> \<Rightarrow> bool\<close> where
\<open>AOT_model_concrete_\<kappa> w (\<omega>\<kappa> x) = AOT_model_concrete\<omega> x w\<close>
| \<open>AOT_model_concrete_\<kappa> w (\<alpha>\<kappa> x) = False\<close>
| \<open>AOT_model_concrete_\<kappa> w (null\<kappa> x) = False\<close>
lemma AOT_meta_A_objects_\<kappa>:
\<open>\<exists>x :: \<kappa>. AOT_model_denotes x \<and>
(\<forall>w. \<not> AOT_model_concrete w x) \<and>
(\<forall>F. AOT_model_denotes F \<longrightarrow> AOT_model_enc x F = \<phi> F)\<close> for \<phi>
apply (rule exI[where x=\<open>\<alpha>\<kappa> {f . \<phi> (urrel_to_rel f)}\<close>])
apply (simp add: AOT_model_enc_\<kappa>_def AOT_model_denotes_\<kappa>_def)
by (metis (no_types, lifting) AOT_rel_equiv_def urrel_quotient
Quotient_rep_abs_fold_unmap)
instance proof
show \<open>AOT_model_regular x\<close> for x :: \<kappa>
by (simp add: AOT_model_regular_\<kappa>_def)
next
fix F G :: \<open><\<kappa>>\<close>
assume \<open>AOT_model_denotes F\<close>
moreover assume \<open>AOT_model_denotes G\<close>
moreover assume \<open>\<And>x. AOT_model_enc x F = AOT_model_enc x G\<close>
moreover obtain x where \<open>\<forall>G. AOT_model_denotes G \<longrightarrow> AOT_model_enc x G = (F = G)\<close>
using AOT_meta_A_objects_\<kappa> by blast
ultimately show \<open>F = G\<close> by blast
next
show \<open>\<exists>x :: \<kappa>. AOT_model_denotes x \<and>
(\<forall>w. \<not> AOT_model_concrete w x) \<and>
(\<forall>F. AOT_model_denotes F \<longrightarrow> AOT_model_enc x F = \<phi> F)\<close> for \<phi>
using AOT_meta_A_objects_\<kappa> .
next
show \<open>\<exists> (x::\<kappa>) w. AOT_model_concrete w x \<and> \<not> AOT_model_concrete w\<^sub>0 x\<close>
using AOT_model_concrete_\<kappa>.simps(1) AOT_model_contingent_object by blast
next
show \<open>AOT_model_concrete w x \<Longrightarrow> \<not> AOT_model_enc x F\<close> for w and x :: \<kappa> and F
by (metis AOT_model_concrete_\<kappa>.simps(2) AOT_model_enc_\<kappa>_def \<kappa>.case_eq_if
\<kappa>.collapse(2))
next
show \<open>AOT_model_concrete w x = AOT_model_concrete w y\<close>
if \<open>AOT_model_term_equiv x y\<close>
for x y :: \<kappa> and w
using that by (induct x; induct y; auto simp: AOT_model_term_equiv_\<kappa>_def)
next
show \<open>AOT_model_concrete w x \<Longrightarrow> AOT_model_denotes x\<close> for w and x :: \<kappa>
by (metis AOT_model_concrete_\<kappa>.simps(3) AOT_model_denotes_\<kappa>_def \<kappa>.collapse(3))
(* Extended models only *)
next
fix \<kappa> \<kappa>' :: \<kappa> and \<Pi> \<Pi>' :: \<open><\<kappa>>\<close> and w :: w
assume ext: \<open>AOT_ExtendedModel\<close>
assume \<open>AOT_model_denotes \<kappa>\<close>
moreover assume \<open>\<nexists>w. AOT_model_concrete w \<kappa>\<close>
ultimately obtain a where a_def: \<open>\<alpha>\<kappa> a = \<kappa>\<close>
by (metis AOT_model_\<omega>_concrete_in_some_world AOT_model_concrete_\<kappa>.simps(1)
AOT_model_denotes_\<kappa>_def \<kappa>.discI(3) \<kappa>.exhaust_sel)
assume \<open>AOT_model_denotes \<kappa>'\<close>
moreover assume \<open>\<nexists>w. AOT_model_concrete w \<kappa>'\<close>
ultimately obtain b where b_def: \<open>\<alpha>\<kappa> b = \<kappa>'\<close>
by (metis AOT_model_\<omega>_concrete_in_some_world AOT_model_concrete_\<kappa>.simps(1)
AOT_model_denotes_\<kappa>_def \<kappa>.discI(3) \<kappa>.exhaust_sel)
assume \<open>AOT_model_denotes \<Pi>' \<Longrightarrow> AOT_model_valid_in w (Rep_rel \<Pi>' \<kappa>) =
AOT_model_valid_in w (Rep_rel \<Pi>' \<kappa>')\<close> for \<Pi>' w
hence \<open>AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>)) =
AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>'))\<close> for r
by (metis AOT_rel_equiv_def Abs_rel_inverse Quotient3_rel_rep
iso_tuple_UNIV_I urrel_quotient3 urrel_to_rel_def)
hence \<open>let r = (Abs_urrel (\<lambda> u . \<epsilon>\<^sub>\<o> w . u = \<kappa>\<upsilon> \<kappa>)) in
AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>)) =
AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>'))\<close>
by presburger
hence \<alpha>\<sigma>_eq: \<open>\<alpha>\<sigma> a = \<alpha>\<sigma> b\<close>
unfolding Let_def
apply (subst (asm) (1 2) Abs_urrel_inverse)
using AOT_model_proposition_choice_simp a_def b_def by force+
assume \<Pi>_den: \<open>AOT_model_denotes \<Pi>\<close>
have \<open>\<not>AOT_model_valid_in w (Rep_rel \<Pi> (SOME xa. \<kappa>\<upsilon> xa = null\<upsilon> x))\<close> for x w
by (metis (mono_tags, lifting) AOT_model_denotes_\<kappa>_def
AOT_model_denotes_rel.rep_eq \<kappa>.exhaust_disc \<kappa>\<upsilon>.simps(1,2,3)
\<open>AOT_model_denotes \<Pi>\<close> \<upsilon>.disc(8,9) \<upsilon>.distinct(3)
is_\<alpha>\<kappa>_def is_\<omega>\<kappa>_def verit_sko_ex')
moreover have \<open>Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_rel \<Pi> (SOME y. \<kappa>\<upsilon> y = \<omega>\<upsilon> x)\<close> for x
by (metis (mono_tags, lifting) AOT_model_denotes_rel.rep_eq
AOT_model_term_equiv_\<kappa>_def \<kappa>\<upsilon>.simps(1) \<Pi>_den verit_sko_ex')
ultimately have \<open>Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_urrel (rel_to_urrel \<Pi>) (\<omega>\<upsilon> x)\<close> for x
unfolding rel_to_urrel_def
by (subst Abs_urrel_inverse) auto
hence \<open>\<exists>r . \<forall> x . Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_urrel r (\<omega>\<upsilon> x)\<close>
by (auto intro!: exI[where x=\<open>rel_to_urrel \<Pi>\<close>])
then obtain r where r_prop: \<open>Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_urrel r (\<omega>\<upsilon> x)\<close> for x
by blast
assume \<open>AOT_model_denotes \<Pi>' \<Longrightarrow>
(\<And>v x. \<exists>w. AOT_model_concrete w x \<Longrightarrow>
AOT_model_valid_in v (Rep_rel \<Pi>' x) =
AOT_model_valid_in v (Rep_rel \<Pi> x)) \<Longrightarrow> AOT_model_enc \<kappa> \<Pi>'\<close> for \<Pi>'
hence \<open>AOT_model_denotes \<Pi>' \<Longrightarrow>
(\<And>v x. AOT_model_valid_in v (Rep_rel \<Pi>' (\<omega>\<kappa> x)) =
AOT_model_valid_in v (Rep_rel \<Pi> (\<omega>\<kappa> x))) \<Longrightarrow> AOT_model_enc \<kappa> \<Pi>'\<close> for \<Pi>'
by (metis AOT_model_concrete_\<kappa>.simps(2) AOT_model_concrete_\<kappa>.simps(3)
\<kappa>.exhaust_disc is_\<alpha>\<kappa>_def is_\<omega>\<kappa>_def is_null\<kappa>_def)
hence \<open>(\<And>v x. AOT_model_valid_in v (Rep_urrel r (\<omega>\<upsilon> x)) =
AOT_model_valid_in v (Rep_rel \<Pi> (\<omega>\<kappa> x))) \<Longrightarrow> r \<in> a\<close> for r
unfolding a_def[symmetric] AOT_model_enc_\<kappa>_def apply simp
by (smt (verit, best) AOT_rel_equiv_def Abs_rel_inverse Quotient3_def
\<kappa>\<upsilon>.simps(1) iso_tuple_UNIV_I urrel_quotient3 urrel_to_rel_def)
hence \<open>(\<And>v x. AOT_model_valid_in v (Rep_urrel r' (\<omega>\<upsilon> x)) =
AOT_model_valid_in v (Rep_urrel r (\<omega>\<upsilon> x))) \<Longrightarrow> r' \<in> a\<close> for r'
unfolding r_prop.
hence \<open>\<And>s. urrel_to_\<omega>rel s = urrel_to_\<omega>rel r \<Longrightarrow> s \<in> a\<close>
by (metis urrel_to_\<omega>rel_def)
hence 0: \<open>\<And>s. urrel_to_\<omega>rel s = urrel_to_\<omega>rel r \<Longrightarrow> s \<in> b\<close>
using \<alpha>\<sigma>_eq_ord_exts_all \<alpha>\<sigma>_eq ext \<alpha>\<sigma>_\<alpha>\<sigma>' by blast
assume \<Pi>'_den: \<open>AOT_model_denotes \<Pi>'\<close>
assume \<open>\<exists>w. AOT_model_concrete w x \<Longrightarrow> AOT_model_valid_in v (Rep_rel \<Pi>' x) =
AOT_model_valid_in v (Rep_rel \<Pi> x)\<close> for v x
hence \<open>AOT_model_valid_in v (Rep_rel \<Pi>' (\<omega>\<kappa> x)) =
AOT_model_valid_in v (Rep_rel \<Pi> (\<omega>\<kappa> x))\<close> for v x
using AOT_model_\<omega>_concrete_in_some_world AOT_model_concrete_\<kappa>.simps(1)
by presburger
hence \<open>AOT_model_valid_in v (Rep_urrel (rel_to_urrel \<Pi>') (\<omega>\<upsilon> x)) =
AOT_model_valid_in v (Rep_urrel r (\<omega>\<upsilon> x))\<close> for v x
by (smt (verit, best) AOT_rel_equiv_def Abs_rel_inverse Quotient3_def
\<kappa>\<upsilon>.simps(1) iso_tuple_UNIV_I r_prop urrel_quotient3 urrel_to_rel_def \<Pi>'_den)
hence \<open>urrel_to_\<omega>rel (rel_to_urrel \<Pi>') = urrel_to_\<omega>rel r\<close>
by (metis (full_types) AOT_urrel_\<omega>equiv_def Quotient3_def urrel_\<omega>rel_quot)
hence \<open>rel_to_urrel \<Pi>' \<in> b\<close> using 0 by blast
thus \<open>AOT_model_enc \<kappa>' \<Pi>'\<close>
unfolding b_def[symmetric] AOT_model_enc_\<kappa>_def by (auto simp: \<Pi>'_den)
next
fix \<kappa> \<kappa>' :: \<kappa> and \<Pi> \<Pi>' :: \<open><\<kappa>>\<close> and w :: w
assume ext: \<open>AOT_ExtendedModel\<close>
assume \<open>AOT_model_denotes \<kappa>\<close>
moreover assume \<open>\<nexists>w. AOT_model_concrete w \<kappa>\<close>
ultimately obtain a where a_def: \<open>\<alpha>\<kappa> a = \<kappa>\<close>
by (metis AOT_model_\<omega>_concrete_in_some_world AOT_model_concrete_\<kappa>.simps(1)
AOT_model_denotes_\<kappa>_def \<kappa>.discI(3) \<kappa>.exhaust_sel)
assume \<open>AOT_model_denotes \<kappa>'\<close>
moreover assume \<open>\<nexists>w. AOT_model_concrete w \<kappa>'\<close>
ultimately obtain b where b_def: \<open>\<alpha>\<kappa> b = \<kappa>'\<close>
by (metis AOT_model_\<omega>_concrete_in_some_world AOT_model_concrete_\<kappa>.simps(1)
AOT_model_denotes_\<kappa>_def \<kappa>.discI(3) \<kappa>.exhaust_sel)
assume \<open>AOT_model_denotes \<Pi>' \<Longrightarrow> AOT_model_valid_in w (Rep_rel \<Pi>' \<kappa>) =
AOT_model_valid_in w (Rep_rel \<Pi>' \<kappa>')\<close> for \<Pi>' w
hence \<open>AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>)) =
AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>'))\<close> for r
by (metis AOT_rel_equiv_def Abs_rel_inverse Quotient3_rel_rep
iso_tuple_UNIV_I urrel_quotient3 urrel_to_rel_def)
hence \<open>let r = (Abs_urrel (\<lambda> u . \<epsilon>\<^sub>\<o> w . u = \<kappa>\<upsilon> \<kappa>)) in
AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>)) =
AOT_model_valid_in w (Rep_urrel r (\<kappa>\<upsilon> \<kappa>'))\<close>
by presburger
hence \<alpha>\<sigma>_eq: \<open>\<alpha>\<sigma> a = \<alpha>\<sigma> b\<close>
unfolding Let_def
apply (subst (asm) (1 2) Abs_urrel_inverse)
using AOT_model_proposition_choice_simp a_def b_def by force+
assume \<Pi>_den: \<open>AOT_model_denotes \<Pi>\<close>
have \<open>\<not>AOT_model_valid_in w (Rep_rel \<Pi> (SOME xa. \<kappa>\<upsilon> xa = null\<upsilon> x))\<close> for x w
by (metis (mono_tags, lifting) AOT_model_denotes_\<kappa>_def
AOT_model_denotes_rel.rep_eq \<kappa>.exhaust_disc \<kappa>\<upsilon>.simps(1,2,3)
\<open>AOT_model_denotes \<Pi>\<close> \<upsilon>.disc(8) \<upsilon>.disc(9) \<upsilon>.distinct(3)
is_\<alpha>\<kappa>_def is_\<omega>\<kappa>_def verit_sko_ex')
moreover have \<open>Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_rel \<Pi> (SOME xa. \<kappa>\<upsilon> xa = \<omega>\<upsilon> x)\<close> for x
by (metis (mono_tags, lifting) AOT_model_denotes_rel.rep_eq
AOT_model_term_equiv_\<kappa>_def \<kappa>\<upsilon>.simps(1) \<Pi>_den verit_sko_ex')
ultimately have \<open>Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_urrel (rel_to_urrel \<Pi>) (\<omega>\<upsilon> x)\<close> for x
unfolding rel_to_urrel_def
by (subst Abs_urrel_inverse) auto
hence \<open>\<exists>r . \<forall> x . Rep_rel \<Pi> (\<omega>\<kappa> x) = Rep_urrel r (\<omega>\<upsilon> x)\<close>