Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
personoj
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
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
koizel
personoj
Commits
70c78a51
Commit
70c78a51
authored
4 years ago
by
gabrielhdt
Browse files
Options
Downloads
Patches
Plain Diff
pairs (dependent and non dependent)
parent
c3b4c18b
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
encodings/pairs.lp
+12
-1
12 additions, 1 deletion
encodings/pairs.lp
encodings/subtype_poly.lp
+5
-4
5 additions, 4 deletions
encodings/subtype_poly.lp
with
17 additions
and
5 deletions
encodings/pairs.lp
+
12
−
1
View file @
70c78a51
...
...
@@ -4,7 +4,18 @@ require open personoj.encodings.bool_hol
require open personoj.encodings.tuple
require open personoj.encodings.prenex
set declared "Σ"
set declared "Σ" // Dependent pairs
set declared "σ" // Non dependent pairs
set declared "σcons"
set declared "σfst"
set declared "σsnd"
constant symbol σ: Set → Set → Set
symbol σcons {t} {u}: η t → η u → η (σ t u)
symbol σfst {t} {u}: η (σ t u) → η t
rule σfst (σcons $x _) ↪ $x
symbol σsnd {t} {u}: η (σ t u) → η u
rule σsnd (σcons _ $y) ↪ $y
constant symbol Σ (t: Set): (η t → Set) → Set
symbol pair_ss {t: Set} {u: η t → Set} (m: η t): η (u m) → η (Σ t u)
...
...
This diff is collapsed.
Click to expand it.
encodings/subtype_poly.lp
+
5
−
4
View file @
70c78a51
...
...
@@ -3,6 +3,7 @@ require open personoj.encodings.lhol
require open personoj.encodings.pvs_cert
require open personoj.encodings.bool_hol
require open personoj.encodings.tuple
require open personoj.encodings.pairs
require open personoj.encodings.prenex
set declared "μ"
...
...
@@ -15,14 +16,14 @@ set declared "↓"
symbol μ: Set → Set
rule μ (psub {$T} _) ↪ μ $T
with μ ($T ~> $U) ↪ $T ~> (μ $U)
with μ (
tuple_t
$T $U) ↪
tuple_t
(μ $T) (μ $U)
with μ (
σ
$T $U) ↪
σ
(μ $T) (μ $U)
with μ (arrd $b) ↪ arrd (λx, μ ($b x))
with μ (μ $T) ↪ μ $T // FIXME: can be proved
symbol π (T: Set): η (μ T) → Bool
rule π ($t ~> $u) ↪ λx: η $t → η (μ $u), ∀ (λy, π $u (x y))
with π (
tuple_t
$t $u)
↪ λx: η (
tuple_t
(μ $t) (μ $u)), π $t (
p1
x) ∧ (λ_, π $u (
p2
x))
with π (
σ
$t $u)
↪ λx: η (
σ
(μ $t) (μ $u)), π $t (
ndfst
x) ∧ (λ_, π $u (
ndsnd
x))
with π (arrd $b)
↪ λx: η (arrd (λx, μ ($b x))), ∀ (λy, π ($b y) (x y))
...
...
@@ -86,7 +87,7 @@ rule ($t1 ~> $u1) ≃ ($t2 ~> $u2)
(eq {μ $t1 ~> bool} (π $t1)
(λx: η (μ $t1), π $t2 (@eqcast $t1 $t2 h x)))
∧ (λ_, $u1 ≃ $u2))
rule
tuple_t
$t1 $u1 ≃
tuple_t
$t2 $u2
rule
σ
$t1 $u1 ≃
σ
$t2 $u2
↪ $t1 ≃ $t2 ∧ (λ_, $u1 ≃ $u2)
with (arrd {$t1} $u1) ≃ (arrd {$t2} $u2)
↪ (μ $t1 ≃ μ $t2)
...
...
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