Skip to content

Commit

Permalink
meeting notes and TODOs
Browse files Browse the repository at this point in the history
  • Loading branch information
m4lvin committed Oct 9, 2023
1 parent 1e50eac commit 27632fe
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 14 deletions.
4 changes: 4 additions & 0 deletions Pdl/Discon.lean
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,10 @@ theorem disconAnd {XS YS} : discon (XS ⊎ YS) ≡ discon XS ⋀ discon YS :=
· apply satX f f_in_X
· apply satY f f_in_Y

theorem disconOr {XS YS} : discon (XS ∪ YS) ≡ discon XS ⋁ discon YS :=
by
sorry

theorem union_elem_uplus {XS YS : Finset (Finset Formula)} {X Y : Finset Formula} :
X ∈ XS → Y ∈ YS → ((X ∪ Y) ∈ (XS ⊎ YS)) :=
by
Expand Down
11 changes: 7 additions & 4 deletions Pdl/Tableau.lean
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,20 @@ lemma localRuleTruth {W} {M : KripkeModel W} {w : W} {X B} :
case nSt a f aSf_in_X =>
have lemFour := likeLemmaFour M (∗ a)
constructor
· intro lhs
· intro lhs -- invertibility
sorry
· intro Mw_X
· intro Mw_X -- soundness
have w_adiamond_f := Mw_X (~⌈∗a⌉f) aSf_in_X
simp at w_adiamond_f lemFour
rcases w_adiamond_f with ⟨v, w_aS_x, v_nF⟩
rcases w_adiamond_f with ⟨v, w_aS_v, v_nF⟩
-- TODO: update the below when Lemma 4 is updated to demand v ≠ w.
-- a atomic, then done?
-- a not atomic, disitnguish cases if v = w
-- Now we use Lemma 4 here:
specialize lemFour w v X.toList (X.toList ++ {~⌈∗a⌉f}) f rfl
unfold vDash.SemImplies modelCanSemImplyForm at lemFour -- mwah, why simp not do this?
simp at lemFour
specialize lemFour _ w_aS_x v_nF
specialize lemFour _ w_aS_v v_nF
· rw [conEval]
intro g g_in
simp at g_in
Expand Down
40 changes: 30 additions & 10 deletions Pdl/Unravel.lean
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@ import Pdl.Semantics
@[simp]
def unravel : Formula → List (List Formula)
-- diamonds:
| ~⌈·a⌉ P => [[~⌈·a⌉ P]]
| ~⌈Program.union p1 p2⌉ P => unravel (~⌈p1⌉ P) ∪ unravel (~⌈p2⌉ P) -- no theF here. fishy?
| ~⌈✓ Q⌉ P => [[Q]]unravel (~P)
| ~⌈a;b⌉ P => unravel (~⌈a⌉ (⌈b⌉ P))
| ~⌈·a⌉P => [[~⌈·a⌉P]]
| ~⌈Program.union p1 p2⌉P => unravel (~⌈p1⌉P) ∪ unravel (~⌈p2⌉P) -- no theF here. fishy?
| ~⌈✓ Q⌉P => [[Q]]unravel (~P)
| ~⌈a;b⌉P => unravel (~⌈a⌉(⌈b⌉P))
| ~†_ => ∅
| ~⌈∗a⌉ P => unravel (~P) ∪ unravel (~⌈a⌉ (†⌈∗a⌉ P))
| ~⌈∗a⌉P => unravel (~P) ∪ unravel (~⌈a⌉(†⌈∗a⌉P))
-- boxes:
| ⌈·a⌉P => [[⌈·a⌉ P]]
| ⌈Program.union a b⌉ P => unravel (⌈a⌉ P)⊎unravel (⌈b⌉ P)
| ⌈✓ Q⌉ P => [[~Q]] ∪ unravel P
| ⌈a;b⌉ P => unravel (⌈a⌉ (⌈b⌉ P))
| ⌈Program.union a b⌉ P => unravel (⌈a⌉P) ⊎ unravel (⌈b⌉P)
| ⌈✓ Q⌉P => [[~Q]] ∪ unravel P
| ⌈a;b⌉P => unravel (⌈a⌉(⌈b⌉P))
| †P => {∅}
| ⌈∗a⌉ P => unravel Punravel (⌈a⌉ (†⌈∗a⌉ P))
| ⌈∗a⌉P => unravel Punravel (⌈a⌉(†⌈∗a⌉P))
-- all other formulas we do nothing, but let's pattern match them all.
| ·c => [[·c]]
| ~·c => [[~·c]]
Expand Down Expand Up @@ -75,11 +75,28 @@ theorem rel_steps_last {as} : ∀ v w,
-- see https://malv.in/2020/borzechowski-pdl/Borzechowski1988-PDL-translation-Gattinger2020.pdf#lemma.4
-- TODO: maybe simplify by not having a context X' here / still as useful for showing soundness of ~* rule?
-- TODO: analogous lemma for the box case? and * rule?
-- TODO: rename to:
-- - diamondStarSound <<<
-- - diamondStarInvert
-- - boxStarSound
-- - boxStarInvert
-- and more?

theorem likeLemmaFourWithoutX :
∀ M (a : Program) (w v : W) (P : Formula),
-- (M, w) ⊨ (~⌈a⌉P) →
relate M a w v → (M, v)⊨(~P) →
∃ Y ∈ unravel (~⌈a⌉P), (M, w)⊨Con Y
∧ ∃ as : List Program, (~ Formula.boxes as P) ∈ Y
∧ relate M (Program.steps as) w v :=
by
sorry

theorem likeLemmaFour :
∀ M (a : Program) (w v : W) (X' X : List Formula) (P : Formula),
X = X' ++ {~⌈a⌉ P} →
(M, w)⊨Con X → relate M a w v → (M, v)⊨(~P) →
∃ Y ∈ {X'}unravel (~⌈a⌉ P), (M, w)⊨Con Y
∃ Y ∈ {X'}unravel (~⌈a⌉P), (M, w)⊨Con Y
∧ ∃ as : List Program, (~ Formula.boxes as P) ∈ Y
∧ relate M (Program.steps as) w v :=
by
Expand Down Expand Up @@ -235,7 +252,10 @@ theorem likeLemmaFour :
· use as
case star =>
intro w v X' X P X_def w_sat_X w_a_v v_sat_nP; subst X_def
-- TODO next next.

sorry
case test =>
intro w v X' X P X_def w_sat_X w_a_v v_sat_nP; subst X_def
-- TODO next!
sorry

0 comments on commit 27632fe

Please sign in to comment.