Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quelle  TAO_99_SanityTests.thy   Sprache: Isabelle

 

(*<*)
theory TAO_99_SanityTests
imports TAO_7_Axioms
begin
(*>*)

section‹Sanity Tests›
text‹\label{TAO_SanityTests}›

locale SanityTests
begin
  interpretation MetaSolver.
  interpretation Semantics.

subsection‹Consistency›
text‹\label{TAO_SanityTests_Consistency}›

  lemma "True"
    nitpick[expect=genuine, user_axioms, satisfy]
    by auto

subsection‹Intensionality›
text‹\label{TAO_SanityTests_Intensionality}›

  lemma "[(\<lambda>y. (q \<or> \<not>q)) = (\<lambda>y. (p \<or> \<not>p)) in v]"
    unfolding identity_Π1_def conn_defs
    apply (rule Eq1I) apply (simp add: meta_defs)
    nitpick[expect = genuine, user_axioms=true, card i = 2,
            card j = 2, card ψ = 1, card σ = 1,
            sat_solver = MiniSat, verbose, show_all]
    oops ― ‹Countermodel by Nitpick›
  lemma "[(\<lambda>y. (p \<or> q)) = (\<lambda>y. (q \<or> p)) in v]"
    unfolding identity_Π1_def
    apply (rule Eq1I) apply (simp add: meta_defs)
    nitpick[expect = genuine, user_axioms=true,
            sat_solver = MiniSat, card i = 2,
            card j = 2, card σ = 1, card ψ = 1,
            card υ = 2, verbose, show_all]
    oops ― ‹Countermodel by Nitpick›

subsection‹Concreteness coindices with Object Domains›
text‹\label{TAO_SanityTests_Concreteness}›

  lemma OrdCheck:
    "[(\<lambda> x . \<not>\<box>(\<not>(E!, xP)), x) in v] ⟷
     (proper x) ∧ (case (rep x) of ψν y → True | _ → False)"
    using OrdinaryObjectsPossiblyConcreteAxiom
    apply (simp add: meta_defs meta_aux split: ν.split υ.split)
    using νυ_ψν_is_ψυ by fastforce
  lemma AbsCheck:
    "[(\<lambda> x . \<box>(\<not>(E!, xP)), x) in v] ⟷
     (proper x) ∧ (case (rep x) of αν y → True | _ → False)"
    using OrdinaryObjectsPossiblyConcreteAxiom
    apply (simp add: meta_defs meta_aux split: ν.split υ.split)
    using no_αψ by blast

subsection‹Justification for Meta-Logical Axioms›
text‹\label{TAO_SanityTests_MetaAxioms}›

text‹
 begin{remark}
 OrdinaryObjectsPossiblyConcreteAxiom is equivalent to "all ordinary objects are
 possibly concrete".
 end{remark}
 
›
  lemma OrdAxiomCheck:
    "OrdinaryObjectsPossiblyConcrete ⟷
      (∀ x. ([(\<lambda> x . \<not>\<box>(\<not>(E!, xP)), xP) in v]
       ⟷ (case x of ψν y → True | _ → False)))"
    unfolding Concrete_def
    apply (simp add: meta_defs meta_aux split: ν.split υ.split)
    using νυ_ψν_is_ψυ by fastforce

text‹
 begin{remark}
 OrdinaryObjectsPossiblyConcreteAxiom is equivalent to "all abstract objects are
 necessarily not concrete".
 end{remark}
 
›

  lemma AbsAxiomCheck:
    "OrdinaryObjectsPossiblyConcrete ⟷
      (∀ x. ([(\<lambda> x . \<box>(\<not>(E!, xP)), xP) in v]
       ⟷ (case x of αν y → True | _ → False)))"
    apply (simp add: meta_defs meta_aux split: ν.split υ.split)
    using νυ_ψν_is_ψυ no_αψ by fastforce
  
text‹
 begin{remark}
 PossiblyContingentObjectExistsAxiom is equivalent to the corresponding statement
 in the embedded logic.
 end{remark}
 
›

  lemma PossiblyContingentObjectExistsCheck:
    "PossiblyContingentObjectExists ⟷ [\<not>(\<box>(\<forall> x. (E!,xP) \<rightarrow> \<box>(E!,xP))) in v]"
     apply (simp add: meta_defs forall_ν_def meta_aux split: ν.split υ.split)
     by (metis ν.simps(5) νυ_def υ.simps(1) no_σψ υ.exhaust)

text‹
 begin{remark}
 PossiblyNoContingentObjectExistsAxiom is equivalent to the corresponding statement
 in the embedded logic.
 end{remark}
 
›

  lemma PossiblyNoContingentObjectExistsCheck:
    "PossiblyNoContingentObjectExists ⟷ [\<not>(\<box>(\<not>(\<forall> x. (E!,xP) \<rightarrow> \<box>(E!,xP)))) in v]"
    apply (simp add: meta_defs forall_ν_def meta_aux split: ν.split υ.split)
    using νυ_ψν_is_ψυ by blast

subsection‹Relations in the Meta-Logic›
text‹\label{TAO_SanityTests_MetaRelations}›

text‹
 begin{remark}
 Material equality in the embedded logic corresponds to
 equality in the actual state in the meta-logic.
 end{remark}
 
›

  lemma mat_eq_is_eq_dj:
    "[\<forall> x . \<box>((F,xP) \<equiv> (G,xP)) in v] ⟷
     ((λ x . (evalΠ1 F) x dj) = (λ x . (evalΠ1 G) x dj))"
  proof
    assume 1: "[\<forall>x. \<box>((F,xP) \<equiv> (G,xP)) in v]"
    {
      fix v
      fix y
      obtain x where y_def: "y = νυ x"
        by (meson νυ_surj surj_def)
      have "(∃r o1. Some r = d1 F ∧ Some o1 = d\<kappa> (xP) ∧ o1 ∈ ex1 r v) =
            (∃r o1. Some r = d1 G ∧ Some o1 = d\<kappa> (xP) ∧ o1 ∈ ex1 r v)"
            using 1 apply - by meta_solver
      moreover obtain r where r_def: "Some r = d1 F"
        unfolding d1_def by auto
      moreover obtain s where s_def: "Some s = d1 G"
        unfolding d1_def by auto
      moreover have "Some x = d\<kappa> (xP)"
        using d\κ_proper by simp
      ultimately have "(x ∈ ex1 r v) = (x ∈ ex1 s v)"
        by (metis option.inject)
      hence "(evalΠ1 F) y dj v = (evalΠ1 G) y dj v"
        using r_def s_def y_def by (simp add: d1.rep_eq ex1_def)
    }
    thus "(λx. evalΠ1 F x dj) = (λx. evalΠ1 G x dj)"
      by auto
  next
    assume 1: "(λx. evalΠ1 F x dj) = (λx. evalΠ1 G x dj)"
    {
      fix y v
      obtain x where x_def: "x = νυ y"
        by simp
      hence "evalΠ1 F x dj = evalΠ1 G x dj"
        using 1 by metis
      moreover obtain r where r_def: "Some r = d1 F"
        unfolding d1_def by auto
      moreover obtain s where s_def: "Some s = d1 G"
        unfolding d1_def by auto
      ultimately have "(y ∈ ex1 r v) = (y ∈ ex1 s v)"
        by (simp add: d1.rep_eq ex1_def νυ_surj x_def)
      hence "[(F,yP) \<equiv> (G,yP) in v]"
        apply - apply meta_solver
        using r_def s_def by (metis Semantics.d\κ_proper option.inject)
    }
    thus "[\<forall>x. \<box>((F,xP) \<equiv> (G,xP)) in v]"
      using T6 T8 by fast
  qed

text‹
 begin{remark}
 Materially equivalent relations are equal in the embedded logic
 if and only if they also coincide in all other states.
 end{remark}
 
›

  lemma mat_eq_is_eq_if_eq_forall_j:
    assumes "[\<forall> x . \<box>((F,xP) \<equiv> (G,xP)) in v]"
    shows "[F = G in v] ⟷
           (∀ s . s ≠ dj ⟶ (∀ x . (evalΠ1 F) x s = (evalΠ1 G) x s))"
    proof
      interpret MetaSolver .
      assume "[F = G in v]"
      hence "F = G"
        apply - unfolding identity_Π1_def by meta_solver
      thus "∀s. s ≠ dj ⟶ (∀x. evalΠ1 F x s = evalΠ1 G x s)"
        by auto
    next
      interpret MetaSolver .
      assume "∀s. s ≠ dj ⟶ (∀x. evalΠ1 F x s = evalΠ1 G x s)"
      moreover have "((λ x . (evalΠ1 F) x dj) = (λ x . (evalΠ1 G) x dj))"
        using assms mat_eq_is_eq_dj by auto
      ultimately have "∀s x. evalΠ1 F x s = evalΠ1 G x s"
        by metis
      hence "evalΠ1 F = evalΠ1 G"
        by blast
      hence "F = G"
        by (metis evalΠ1_inverse)
      thus "[F = G in v]"
        unfolding identity_Π1_def using Eq1I by auto
    qed

text‹
 begin{remark}
 Under the assumption that all properties behave in all states like in the actual state
 the defined equality degenerates to material equality.
 end{remark}
 
›

  lemma assumes "∀ F x s . (evalΠ1 F) x s = (evalΠ1 F) x dj"
    shows "[\<forall> x . \<box>((F,xP) \<equiv> (G,xP)) in v] ⟷ [F = G in v]"
    by (metis (no_types) MetaSolver.Eq1S assms identity_Π1_def
                         mat_eq_is_eq_dj mat_eq_is_eq_if_eq_forall_j)

subsection‹Lambda Expressions›
text‹\label{TAO_SanityTests_MetaLambda}›

  lemma lambda_interpret_1:
  assumes "[a = b in v]"
  shows "(\<lambda>x. (R,xP,a)) = (\<lambda>x . (R,xP, b))"
  proof -
    have "a = b"
      using MetaSolver.EqκS Semantics.d\κ_inject assms
            identity_κ_def by auto
    thus ?thesis by simp
  qed

  lemma lambda_interpret_2:
  assumes "[a = (\<iota>y. (G,yP)) in v]"
  shows "(\<lambda>x. (R,xP,a)) = (\<lambda>x . (R,xP, \<iota>y. (G,yP)))"
  proof -
    have "a = (\<iota>y. (G,yP))"
      using MetaSolver.EqκS Semantics.d\κ_inject assms
            identity_κ_def by auto
    thus ?thesis by simp
  qed

end

(*<*)
end
(*>*)

Messung V0.5 in Prozent
C=75 H=100 G=88

¤ Dauer der Verarbeitung: 0.12 Sekunden  (vorverarbeitet am  2026-09-29) ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Statistik
#Sources=1126438
#Domains=1867298