Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
sgdt
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
gradual-typing
sgdt
Commits
8122aca7
Commit
8122aca7
authored
1 year ago
by
Eric Giovannini
Browse files
Options
Downloads
Patches
Plain Diff
updates to Later.agda
parent
5b0250dc
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
formalizations/guarded-cubical/Common/Later.agda
+24
-8
24 additions, 8 deletions
formalizations/guarded-cubical/Common/Later.agda
with
24 additions
and
8 deletions
formalizations/guarded-cubical/Common/Later.agda
+
24
−
8
View file @
8122aca7
...
...
@@ -99,7 +99,7 @@ postulate
-- There is likely a better way to do this, see
-- https://arxiv.org/pdf/2102.01969.pdf (in particular Section 3.2).
postulate
tick-irrelevance : {ℓ : Level} -> {A : Type ℓ} -> (M : ▹ k , A)
(
t t' : Tick k) ->
tick-irrelevance : {ℓ : Level} -> {A : Type ℓ} -> (M : ▹ k , A)
-> ∀ (@tick
t t' : Tick k) ->
M t ≡ M t'
tr' : {A : Type} -> (M : ▹ k , A) ->
...
...
@@ -109,6 +109,9 @@ postulate
tr→tr' : {M : ▹ k , A} -> tick-irrelevance M -> tr' M
-}
{-
-- This doesn't work in Agda 2.6.4
-- The tick constant.
postulate
-- _◇ : (k : Clock) -> Tick k
...
...
@@ -120,7 +123,7 @@ postulate
tick-irrelevance-◇-refl : {A : Type} -> (M : ▹ k , A) ->
(tick-irrelevance M (◇) (◇)) ≡ Cubical.Foundations.Everything.refl
-- Should this use _≣_.refl instead?
-}
-- This relies on tick irrelevance.
next-Mt≡M : {ℓ : Level} -> {A : Type ℓ} -> (M : ▹ k , A) ->
...
...
@@ -128,12 +131,13 @@ next-Mt≡M : {ℓ : Level} -> {A : Type ℓ} -> (M : ▹ k , A) ->
next-Mt≡M M t = later-ext (λ t' → tick-irrelevance M t t')
next-Mt≡M' : {ℓ : Level} -> {A : Type ℓ} -> (M : ▹ k , A) -> (t : Tick k) ->
next-Mt≡M' : {ℓ : Level} -> {A : Type ℓ} -> (M : ▹ k , A) -> (
@tick
t : Tick k) ->
next (M t) ≡ M
next-Mt≡M' M t = next-Mt≡M M t
-- Property of next
next-injective-later : {k : Clock} -> {A : Type} -> (x y : A) ->
next-injective-later : {k : Clock} -> {ℓ : Level} -> {A : Type ℓ} ->
(x y : A) ->
next {k = k} x ≡ next y -> ▸_ {k} λ t -> (x ≡ y)
next-injective-later x y eq = λ t i → eq i t
...
...
@@ -167,14 +171,15 @@ postulate
-- (k : Clock) -> next (force' f k) ≡ f k
force-iso : {A : Clock -> Type} -> Iso (∀ k -> (▹ k , A k)) (∀ k -> A k)
force-iso : {ℓ : Level} -> {A : Clock -> Type ℓ} ->
Iso (∀ k -> (▹ k , A k)) (∀ k -> A k)
force-iso = iso force' (λ f k → next (f k))
force'-beta
next-force'
-- (λ f → clock-ext (λ k → next-force' f k))
-- Using force, we can show that next is injective "globally".
next-∀k-inj : {A : Type} -> (x y : A) ->
next-∀k-inj :
{ℓ : Level} ->
{A : Type
ℓ
} -> (x y : A) ->
((k : Clock) -> next {k = k} x ≡ next y) ->
(∀ (k : Clock) -> (x ≡ y))
next-∀k-inj x y H = force' (λ k' -> next-injective-later x y (H k'))
...
...
@@ -193,6 +198,7 @@ clock-irrel A =
(M : ∀ (k : Clock) -> A) ->
(k k' : Clock) ->
M k ≡ M k'
∀kA->A : {ℓ : Level} -> (A : Type ℓ) ->
...
...
@@ -208,9 +214,13 @@ Iso-∀kA-A {A = A} H-irrel-A = iso
(λ a → refl)
(λ f → clock-ext (λ k → H-irrel-A f k0 k))
∀kA≡A : {A : Type} -> clock-irrel A -> (∀ (k : Clock) -> A) ≡ A
∀kA≡A :
{ℓ : Level}
{A : Type
ℓ
} -> clock-irrel A -> (∀ (k : Clock) -> A) ≡ A
∀kA≡A H = isoToPath (Iso-∀kA-A H)
{-
postulate clk-irrel-beta : {ℓ : Level} -> {A : Type ℓ} -> (H : clock-irrel A) (k k' : Clock) (a : A) -> (λ k -> a) ≣ a
-- clk-irrel-beta H k k' a i = {!!}
...
...
@@ -220,8 +230,14 @@ postulate
nat-clock-irrel : clock-irrel ℕ
bool-clock-irrel : clock-irrel Bool
-- Clock irrelevance over a constant family Clock -> A is equivalent to reflexivity in A
-- TODO: Is this sound?
clock-irrel-beta-const : {ℓ : Level} {A : Type ℓ} -> (H : clock-irrel A) ->
(a : A) (k1 k2 : Clock) -> H (λ k -> a) k1 k2 ≣ refl
-- type-clock-irrel : clock-irrel Type
-- Clock irrelevance where we provide the same clock k0 is equivalent to reflexivity in M k0
clock-irrel-beta-k0 : {ℓ : Level} {A : Type ℓ} -> (H : clock-irrel A) ->
(M : Clock -> A) -> H M k0 k0 ≣ refl
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment