Skip to content
Snippets Groups Projects
Commit cca64185 authored by Ralf Jung's avatar Ralf Jung
Browse files

finish sorting setup.tex

parent f01811c1
No related branches found
No related tags found
No related merge requests found
...@@ -93,27 +93,27 @@ Using these view shifts, we can prove STS variants of the invariant rules \ruler ...@@ -93,27 +93,27 @@ Using these view shifts, we can prove STS variants of the invariant rules \ruler
This holds by our premise. This holds by our premise.
\end{proof} \end{proof}
\begin{proof}[Proof of \ruleref{VSSts}] % \begin{proof}[Proof of \ruleref{VSSts}]
This is similar to above, so we only give the proof in short notation: % This is similar to above, so we only give the proof in short notation:
\hproof{% % \hproof{%
Context: $\knowInv\iname{\STSInv(\STSS, \pred, \gname)}$ \\ % Context: $\knowInv\iname{\STSInv(\STSS, \pred, \gname)}$ \\
\pline[\mask_1 \uplus \{\iname\}]{ % \pline[\mask_1 \uplus \{\iname\}]{
\ownGhost\gname{(s_0, T)} * P % \ownGhost\gname{(s_0, T)} * P
} \\ % } \\
\pline[\mask_1]{% % \pline[\mask_1]{%
\Exists s. \later\pred(s) * \ownGhost\gname{(s, S, T)} * P % \Exists s. \later\pred(s) * \ownGhost\gname{(s, S, T)} * P
} \qquad by \ruleref{StsOpen} \\ % } \qquad by \ruleref{StsOpen} \\
Context: $s \in S \eqdef \upclose(\{s_0\}, T)$ \\ % Context: $s \in S \eqdef \upclose(\{s_0\}, T)$ \\
\pline[\mask_2]{% % \pline[\mask_2]{%
\Exists s', T'. \later\pred(s') * Q(s', T') * \ownGhost\gname{(s, S, T)} % \Exists s', T'. \later\pred(s') * Q(s', T') * \ownGhost\gname{(s, S, T)}
} \qquad by premiss \\ % } \qquad by premiss \\
Context: $(s, T) \ststrans (s', T')$ \\ % Context: $(s, T) \ststrans (s', T')$ \\
\pline[\mask_2 \uplus \{\iname\}]{ % \pline[\mask_2 \uplus \{\iname\}]{
\ownGhost\gname{(s', T')} * Q(s', T') % \ownGhost\gname{(s', T')} * Q(s', T')
} \qquad by \ruleref{StsClose} % } \qquad by \ruleref{StsClose}
} % }
\end{proof} % \end{proof}
\subsection{Authoritative monoids with interpretation}\label{sec:authinterp} \subsection{Authoritative monoids with interpretation}\label{sec:authinterp}
...@@ -185,3 +185,8 @@ The view shifts in the specification follow immediately from \ruleref{GhostUpd} ...@@ -185,3 +185,8 @@ The view shifts in the specification follow immediately from \ruleref{GhostUpd}
The first implication is immediate from the definition. The first implication is immediate from the definition.
The second implication follows by case distinction on $q_1 + q_2 \in (0, 1]$. The second implication follows by case distinction on $q_1 + q_2 \in (0, 1]$.
%%% Local Variables:
%%% mode: latex
%%% TeX-master: "iris"
%%% End:
...@@ -106,7 +106,7 @@ Let $\mcarp{M} \eqdef |\monoid| \setminus \{\mzero\}$. ...@@ -106,7 +106,7 @@ Let $\mcarp{M} \eqdef |\monoid| \setminus \{\mzero\}$.
\paragraph{Signatures.} \paragraph{Signatures.}
We use a signature to account syntactically for the logic's parameters. We use a signature to account syntactically for the logic's parameters.
A \emph{signature} $\SigNat = (\SigType, \SigFn)$ comprises a set A \emph{signature} $\Sig = (\SigType, \SigFn)$ comprises a set
\[ \[
\SigType \supseteq \{ \textsort{Val}, \textsort{Exp}, \textsort{Ectx}, \textsort{State}, \textsort{Monoid}, \textsort{InvName}, \textsort{InvMask}, \Prop \} \SigType \supseteq \{ \textsort{Val}, \textsort{Exp}, \textsort{Ectx}, \textsort{State}, \textsort{Monoid}, \textsort{InvName}, \textsort{InvMask}, \Prop \}
\] \]
...@@ -120,7 +120,7 @@ to express that $\sigfn$ is a function symbol with the indicated arity. ...@@ -120,7 +120,7 @@ to express that $\sigfn$ is a function symbol with the indicated arity.
\dave{Say something not-too-shabby about adequacy: We don't spell out what it means.} \dave{Say something not-too-shabby about adequacy: We don't spell out what it means.}
\paragraph{Syntax.} \paragraph{Syntax.}
Iris syntax is built up from a signature $\SigNat$ and a countably infinite set $\textdom{Var}$ of variables (ranged over by metavariables $x$, $y$, $z$, and $\pvar$): Iris syntax is built up from a signature $\Sig$ and a countably infinite set $\textdom{Var}$ of variables (ranged over by metavariables $x$, $y$, $z$):
\newcommand{\unitterm}{()}% \newcommand{\unitterm}{()}%
\newcommand{\unitsort}{1}% \unit is bold. \newcommand{\unitsort}{1}% \unit is bold.
\begin{align*} \begin{align*}
...@@ -145,9 +145,9 @@ Iris syntax is built up from a signature $\SigNat$ and a countably infinite set ...@@ -145,9 +145,9 @@ Iris syntax is built up from a signature $\SigNat$ and a countably infinite set
\prop * \prop \mid \prop * \prop \mid
\prop \wand \prop \mid \prop \wand \prop \mid
\\& \\&
\MU \pvar. \pred \mid \MU \var. \pred \mid
\Exists x:\sort. \prop \mid \Exists \var:\sort. \prop \mid
\All x:\sort. \prop \mid \All \var:\sort. \prop \mid
\\& \\&
\knowInv{\term}{\prop} \mid \knowInv{\term}{\prop} \mid
\ownGGhost{\term} \mid \ownGGhost{\term} \mid
...@@ -164,7 +164,7 @@ Iris syntax is built up from a signature $\SigNat$ and a countably infinite set ...@@ -164,7 +164,7 @@ Iris syntax is built up from a signature $\SigNat$ and a countably infinite set
\sort \times \sort \mid \sort \times \sort \mid
\sort \to \sort \sort \to \sort
\end{align*} \end{align*}
Recursive predicates must be \emph{guarded}: in $\MU \pvar. \pred$, the variable $\pvar$ can only appear under the later $\later$ modality. Recursive predicates must be \emph{guarded}: in $\MU \var. \pred$, the variable $\var$ can only appear under the later $\later$ modality.
\paragraph{Metavariable conventions.} \paragraph{Metavariable conventions.}
We introduce additional metavariables ranging over terms and generally let the choice of metavariable indicate the term's sort: We introduce additional metavariables ranging over terms and generally let the choice of metavariable indicate the term's sort:
...@@ -196,13 +196,13 @@ We omit type annotations in binders, when the type is clear from context. ...@@ -196,13 +196,13 @@ We omit type annotations in binders, when the type is clear from context.
\subsection{Types}\label{sec:types} \subsection{Types}\label{sec:types}
Iris terms are simply-typed. Iris terms are simply-typed.
The judgment $\vctx \proves_\SigNat \wtt{\term}{\sort}$ expresses that, in signature $\SigNat$ and variable context $\vctx$, the term $\term$ has sort $\sort$. The judgment $\vctx \proves_\Sig \wtt{\term}{\sort}$ expresses that, in signature $\Sig$ and variable context $\vctx$, the term $\term$ has sort $\sort$.
In giving the rules for this judgment, we omit the signature (which does not change). In giving the rules for this judgment, we omit the signature (which does not change).
A variable context, $\vctx = x_1:\sort_1, \dots, x_n:\sort_n$, declares a list of variables and their sorts. A variable context, $\vctx = x_1:\sort_1, \dots, x_n:\sort_n$, declares a list of variables and their sorts.
In writing $\vctx, x:\sort$, we presuppose that $x$ is not already declared in $\vctx$. In writing $\vctx, x:\sort$, we presuppose that $x$ is not already declared in $\vctx$.
\judgment{Well-typed terms}{\vctx \proves_\SigNat \wtt{\term}{\sort}} \judgment{Well-typed terms}{\vctx \proves_\Sig \wtt{\term}{\sort}}
\begin{mathparpagebreakable} \begin{mathparpagebreakable}
%%% variables and function symbols %%% variables and function symbols
\axiom{x : \sort \proves \wtt{x}{\sort}} \axiom{x : \sort \proves \wtt{x}{\sort}}
...@@ -274,10 +274,10 @@ In writing $\vctx, x:\sort$, we presuppose that $x$ is not already declared in $ ...@@ -274,10 +274,10 @@ In writing $\vctx, x:\sort$, we presuppose that $x$ is not already declared in $
{\vctx \proves \wtt{\prop \wand \propB}{\Prop}} {\vctx \proves \wtt{\prop \wand \propB}{\Prop}}
\and \and
\infer{ \infer{
\vctx, \pvar:\sort\to\Prop \proves \wtt{\pred}{\sort\to\Prop} \and \vctx, \var:\sort\to\Prop \proves \wtt{\pred}{\sort\to\Prop} \and
\text{$\pvar$ is guarded in $\pred$} \text{$\var$ is guarded in $\pred$}
}{ }{
\vctx \proves \wtt{\MU \pvar. \pred}{\sort\to\Prop} \vctx \proves \wtt{\MU \var. \pred}{\sort\to\Prop}
} }
\and \and
\infer{\vctx, x:\sort \proves \wtt{\prop}{\Prop}} \infer{\vctx, x:\sort \proves \wtt{\prop}{\Prop}}
...@@ -410,31 +410,31 @@ Soundness follows from the theorem that ${\cal U}(\any, \textdom{Prop}) ...@@ -410,31 +410,31 @@ Soundness follows from the theorem that ${\cal U}(\any, \textdom{Prop})
{\pfctx \proves \exists X: \sort. \prop} {\pfctx \proves \exists X: \sort. \prop}
\and \and
\infer[$\forall_2$I] \infer[$\forall_2$I]
{\pfctx, \pvar: \Pred(\sort) \proves \prop} {\pfctx, \var: \Pred(\sort) \proves \prop}
{\pfctx \proves \forall \pvar\in \Pred(\sort).\; \prop} {\pfctx \proves \forall \var\in \Pred(\sort).\; \prop}
\and \and
\infer[$\forall_2$E] \infer[$\forall_2$E]
{\pfctx \proves \forall \pvar. \prop \\ {\pfctx \proves \forall \var. \prop \\
\pfctx \proves \propB: \Prop} \pfctx \proves \propB: \Prop}
{\pfctx \proves \prop[\propB/\pvar]} {\pfctx \proves \prop[\propB/\var]}
\and \and
\infer[$\exists_2$E] \infer[$\exists_2$E]
{\pfctx \proves \exists \pvar \in \Pred(\sort).\prop \\ {\pfctx \proves \exists \var \in \Pred(\sort).\prop \\
\pfctx, \pvar : \Pred(\sort), \prop \proves \propB} \pfctx, \var : \Pred(\sort), \prop \proves \propB}
{\pfctx \proves \propB} {\pfctx \proves \propB}
\and \and
\infer[$\exists_2$I] \infer[$\exists_2$I]
{\pfctx \proves \prop[\propB/\pvar] \\ {\pfctx \proves \prop[\propB/\var] \\
\pfctx \proves \propB: \Prop} \pfctx \proves \propB: \Prop}
{\pfctx \proves \exists \pvar. \prop} {\pfctx \proves \exists \var. \prop}
\and \and
\inferB[Elem] \inferB[Elem]
{\pfctx \proves \term \in (X \in \sort). \prop} {\pfctx \proves \term \in (X \in \sort). \prop}
{\pfctx \proves \prop[\term/X]} {\pfctx \proves \prop[\term/X]}
\and \and
\inferB[Elem-$\mu$] \inferB[Elem-$\mu$]
{\pfctx \proves \term \in (\mu\pvar \in \Pred(\sort). \pred)} {\pfctx \proves \term \in (\mu\var \in \Pred(\sort). \pred)}
{\pfctx \proves \term \in \pred[\mu\pvar \in \Pred(\sort). \pred/\pvar]} {\pfctx \proves \term \in \pred[\mu\var \in \Pred(\sort). \pred/\var]}
\end{mathpar} \end{mathpar}
\subsection{Axioms from the logic of (affine) bunched implications} \subsection{Axioms from the logic of (affine) bunched implications}
......
...@@ -149,36 +149,36 @@ For a set $X$, write $\Delta X$ for the discrete c.o.f.e.\ with $x \nequiv{n} ...@@ -149,36 +149,36 @@ For a set $X$, write $\Delta X$ for the discrete c.o.f.e.\ with $x \nequiv{n}
x'$ iff $n = 0$ or $x = x'$ x'$ iff $n = 0$ or $x = x'$
\[ \[
\begin{array}[t]{@{}l@{\ }c@{\ }l@{}} \begin{array}[t]{@{}l@{\ }c@{\ }l@{}}
\semSort{\textsort{Unit}} &\eqdef& \Delta \{ \star \} \\ \Sem{\textsort{Unit}} &\eqdef& \Delta \{ \star \} \\
\semSort{\textsort{InvName}} &\eqdef& \Delta \mathbb{N} \\ \Sem{\textsort{InvName}} &\eqdef& \Delta \mathbb{N} \\
\semSort{\textsort{InvMask}} &\eqdef& \Delta \pset{\mathbb{N}} \\ \Sem{\textsort{InvMask}} &\eqdef& \Delta \pset{\mathbb{N}} \\
\semSort{\textsort{Monoid}} &\eqdef& \Delta |\monoid| \Sem{\textsort{Monoid}} &\eqdef& \Delta |\monoid|
\end{array} \end{array}
\qquad\qquad \qquad\qquad
\begin{array}[t]{@{}l@{\ }c@{\ }l@{}} \begin{array}[t]{@{}l@{\ }c@{\ }l@{}}
\semSort{\textsort{Val}} &\eqdef& \Delta \textdom{Val} \\ \Sem{\textsort{Val}} &\eqdef& \Delta \textdom{Val} \\
\semSort{\textsort{Exp}} &\eqdef& \Delta \textdom{Exp} \\ \Sem{\textsort{Exp}} &\eqdef& \Delta \textdom{Exp} \\
\semSort{\textsort{Ectx}} &\eqdef& \Delta \textdom{Ectx} \\ \Sem{\textsort{Ectx}} &\eqdef& \Delta \textdom{Ectx} \\
\semSort{\textsort{State}} &\eqdef& \Delta \textdom{State} \\ \Sem{\textsort{State}} &\eqdef& \Delta \textdom{State} \\
\end{array} \end{array}
\qquad\qquad \qquad\qquad
\begin{array}[t]{@{}l@{\ }c@{\ }l@{}} \begin{array}[t]{@{}l@{\ }c@{\ }l@{}}
\semSort{\sort \times \sort'} &\eqdef& \semSort{\sort} \times \semSort{\sort} \\ \Sem{\sort \times \sort'} &\eqdef& \Sem{\sort} \times \Sem{\sort} \\
\semSort{\sort \to \sort'} &\eqdef& \semSort{\sort} \to \semSort{\sort} \\ \Sem{\sort \to \sort'} &\eqdef& \Sem{\sort} \to \Sem{\sort} \\
\semSort{\Prop} &\eqdef& \textdom{Prop} \\ \Sem{\Prop} &\eqdef& \textdom{Prop} \\
\end{array} \end{array}
\] \]
The balance of our signature $\SigNat$ is interpreted as follows. The balance of our signature $\Sig$ is interpreted as follows.
For each base type $\type$ not covered by the preceding table, we pick an object $X_\type$ in $\cal U$ and define For each base type $\type$ not covered by the preceding table, we pick an object $X_\type$ in $\cal U$ and define
\[ \[
\semSort{\type} \eqdef X_\type \Sem{\type} \eqdef X_\type
\] \]
For each function symbol $\sigfn : \type_1, \dots, \type_n \to \type_{n+1} \in \SigFn$, we pick an arrow $\Sem{\sigfn} : \semSort{\type_1} \times \dots \times \semSort{\type_n} \to \semSort{\type_{n+1}}$ in $\cal U$. For each function symbol $\sigfn : \type_1, \dots, \type_n \to \type_{n+1} \in \SigFn$, we pick an arrow $\Sem{\sigfn} : \Sem{\type_1} \times \dots \times \Sem{\type_n} \to \Sem{\type_{n+1}}$ in $\cal U$.
An environment $\vctx$ is interpreted as the set of An environment $\vctx$ is interpreted as the set of
maps $\rho$, with $\dom(\rho) = \dom(\vctx)$ and maps $\rho$, with $\dom(\rho) = \dom(\vctx)$ and
$\rho(x)\in\semSort{\vctx(x)}$, $\rho(x)\in\Sem{\vctx(x)}$,
and and
$\rho\nequiv{n} \rho' \iff n=0 \lor \bigl(\dom(\rho)=\dom(\rho') \land $\rho\nequiv{n} \rho' \iff n=0 \lor \bigl(\dom(\rho)=\dom(\rho') \land
\All x\in\dom(\rho). \rho(x) \nequiv{n} \rho'(x)\bigr)$. \All x\in\dom(\rho). \rho(x) \nequiv{n} \rho'(x)\bigr)$.
...@@ -420,89 +420,89 @@ $\rho\nequiv{n} \rho' \iff n=0 \lor \bigl(\dom(\rho)=\dom(\rho') \land ...@@ -420,89 +420,89 @@ $\rho\nequiv{n} \rho' \iff n=0 \lor \bigl(\dom(\rho)=\dom(\rho') \land
\[ \mathit{wp}_\mask(\val, q) = \mathit{vs}_{\mask}^{\mask}(q \: \val) \] \[ \mathit{wp}_\mask(\val, q) = \mathit{vs}_{\mask}^{\mask}(q \: \val) \]
\end{lem} \end{lem}
\typedsection{Interpretation of terms}{\Sem{\vctx \proves \term : \sort} : \Sem{\vctx} \to \semSort{\sort} \in {\cal U}} \typedsection{Interpretation of terms}{\Sem{\vctx \proves \term : \sort} : \Sem{\vctx} \to \Sem{\sort} \in {\cal U}}
%A term $\vctx \proves \term : \sort$ is interpreted as a non-expansive map from $\Sem{\vctx}$ to $\semSort{\sort}$. %A term $\vctx \proves \term : \sort$ is interpreted as a non-expansive map from $\Sem{\vctx}$ to $\Sem{\sort}$.
\begin{align*} \begin{align*}
\semTerm{\vctx \proves x : \sort}_\gamma &= \gamma(x) \\ \Sem{\vctx \proves x : \sort}_\gamma &= \gamma(x) \\
\semTerm{\vctx \proves \sigfn(\term_1, \dots, \term_n) : \type_{n+1}}_\gamma &= \Sem{\sigfn}(\semTerm{\vctx \proves \term_1 : \type_1}_\gamma, \dots, \semTerm{\vctx \proves \term_n : \type_n}_\gamma) \ \WHEN \sigfn : \type_1, \dots, \type_n \to \type_{n+1} \in \SigFn \\ \Sem{\vctx \proves \sigfn(\term_1, \dots, \term_n) : \type_{n+1}}_\gamma &= \Sem{\sigfn}(\Sem{\vctx \proves \term_1 : \type_1}_\gamma, \dots, \Sem{\vctx \proves \term_n : \type_n}_\gamma) \ \WHEN \sigfn : \type_1, \dots, \type_n \to \type_{n+1} \in \SigFn \\
\semTerm{\vctx \proves \Lam x. \term : \sort \to \sort'}_\gamma &= \Sem{\vctx \proves \Lam x. \term : \sort \to \sort'}_\gamma &=
\Lam v : \semSort{\sort}. \semTerm{\vctx, x : \sort \proves \term : \sort'}_{\gamma[x \mapsto v]} \\ \Lam v : \Sem{\sort}. \Sem{\vctx, x : \sort \proves \term : \sort'}_{\gamma[x \mapsto v]} \\
\semTerm{\vctx \proves \term~\termB : \sort'}_\gamma &= \Sem{\vctx \proves \term~\termB : \sort'}_\gamma &=
\semTerm{\vctx \proves \term : \sort \to \sort'}_\gamma(\semTerm{\vctx \proves \termB : \sort}_\gamma) \\ \Sem{\vctx \proves \term : \sort \to \sort'}_\gamma(\Sem{\vctx \proves \termB : \sort}_\gamma) \\
\semTerm{\vctx \proves \unitterm : \unitsort}_\gamma &= \star \\ \Sem{\vctx \proves \unitterm : \unitsort}_\gamma &= \star \\
\semTerm{\vctx \proves (\term_1, \term_2) : \sort_1 \times \sort_2}_\gamma &= (\semTerm{\vctx \proves \term_1 : \sort_1}_\gamma, \semTerm{\vctx \proves \term_2 : \sort_2}_\gamma) \\ \Sem{\vctx \proves (\term_1, \term_2) : \sort_1 \times \sort_2}_\gamma &= (\Sem{\vctx \proves \term_1 : \sort_1}_\gamma, \Sem{\vctx \proves \term_2 : \sort_2}_\gamma) \\
\semTerm{\vctx \proves \pi_i~\term : \sort_1}_\gamma &= \pi_i(\semTerm{\vctx \proves \term : \sort_1 \times \sort_2}_\gamma) \Sem{\vctx \proves \pi_i~\term : \sort_1}_\gamma &= \pi_i(\Sem{\vctx \proves \term : \sort_1 \times \sort_2}_\gamma)
\end{align*} \end{align*}
% %
\begin{align*} \begin{align*}
\semTerm{\vctx \proves \mzero : \textsort{Monoid}}_\gamma &= \mzero \\ \Sem{\vctx \proves \mzero : \textsort{Monoid}}_\gamma &= \mzero \\
\semTerm{\vctx \proves \munit : \textsort{Monoid}}_\gamma &= \munit \\ \Sem{\vctx \proves \munit : \textsort{Monoid}}_\gamma &= \munit \\
\semTerm{\vctx \proves \melt \mtimes \meltB : \textsort{Monoid}}_\gamma &= \Sem{\vctx \proves \melt \mtimes \meltB : \textsort{Monoid}}_\gamma &=
\semTerm{\vctx \proves \melt : \textsort{Monoid}}_\gamma \mtimes \semTerm{\vctx \proves \meltB : \textsort{Monoid}}_\gamma \Sem{\vctx \proves \melt : \textsort{Monoid}}_\gamma \mtimes \Sem{\vctx \proves \meltB : \textsort{Monoid}}_\gamma
\end{align*} \end{align*}
% %
\begin{align*} \begin{align*}
\semTerm{\vctx \proves t =_\sort u : \Prop}_\gamma &= \Sem{\vctx \proves t =_\sort u : \Prop}_\gamma &=
\Lam W. \{\, (n, r) \mid \semTerm{\vctx \proves t : \sort}_\gamma \nequiv{n+1} \semTerm{\vctx \proves u : \sort}_\gamma \,\} \\ \Lam W. \{\, (n, r) \mid \Sem{\vctx \proves t : \sort}_\gamma \nequiv{n+1} \Sem{\vctx \proves u : \sort}_\gamma \,\} \\
\semTerm{\vctx \proves \FALSE : \Prop}_\gamma &= \Lam W. \emptyset \\ \Sem{\vctx \proves \FALSE : \Prop}_\gamma &= \Lam W. \emptyset \\
\semTerm{\vctx \proves \TRUE : \Prop}_\gamma &= \Lam W. \mathbb{N} \times \textdom{Res} \\ \Sem{\vctx \proves \TRUE : \Prop}_\gamma &= \Lam W. \mathbb{N} \times \textdom{Res} \\
\semTerm{\vctx \proves P \land Q : \Prop}_\gamma &= \Sem{\vctx \proves P \land Q : \Prop}_\gamma &=
\Lam W. \semTerm{\vctx \proves P : \Prop}_\gamma(W) \cap \semTerm{\vctx \proves Q : \Prop}_\gamma(W) \\ \Lam W. \Sem{\vctx \proves P : \Prop}_\gamma(W) \cap \Sem{\vctx \proves Q : \Prop}_\gamma(W) \\
\semTerm{\vctx \proves P \lor Q : \Prop}_\gamma &= \Sem{\vctx \proves P \lor Q : \Prop}_\gamma &=
\Lam W. \semTerm{\vctx \proves P : \Prop}_\gamma(W) \cup \semTerm{\vctx \proves Q : \Prop}_\gamma(W) \\ \Lam W. \Sem{\vctx \proves P : \Prop}_\gamma(W) \cup \Sem{\vctx \proves Q : \Prop}_\gamma(W) \\
\semTerm{\vctx \proves P \Ra Q : \Prop}_\gamma &= \Sem{\vctx \proves P \Ra Q : \Prop}_\gamma &=
\Lam W. \begin{aligned}[t] \Lam W. \begin{aligned}[t]
\{\, (n, r) &\mid \All n' \leq n. \All W' \geq W. \All r' \geq r. \\ \{\, (n, r) &\mid \All n' \leq n. \All W' \geq W. \All r' \geq r. \\
&\qquad &\qquad
(n', r') \in \semTerm{\vctx \proves P : \Prop}_\gamma(W')~ \\ (n', r') \in \Sem{\vctx \proves P : \Prop}_\gamma(W')~ \\
&\qquad &\qquad
\implies (n', r') \in \semTerm{\vctx \proves Q : \Prop}_\gamma(W') \,\} \implies (n', r') \in \Sem{\vctx \proves Q : \Prop}_\gamma(W') \,\}
\end{aligned} \\ \end{aligned} \\
\semTerm{\vctx \proves \All x : \sort. P : \Prop}_\gamma &= \Sem{\vctx \proves \All x : \sort. P : \Prop}_\gamma &=
\Lam W. \{\, (n, r) \mid \All v \in \semSort{\sort}. (n, r) \in \semTerm{\vctx, x : \sort \proves P : \Prop}_{\gamma[x \mapsto v]}(W) \,\} \\ \Lam W. \{\, (n, r) \mid \All v \in \Sem{\sort}. (n, r) \in \Sem{\vctx, x : \sort \proves P : \Prop}_{\gamma[x \mapsto v]}(W) \,\} \\
\semTerm{\vctx \proves \Exists x : \sort. P : \Prop}_\gamma &= \Sem{\vctx \proves \Exists x : \sort. P : \Prop}_\gamma &=
\Lam W. \{\, (n, r) \mid \Exists v \in \semSort{\sort}. (n, r) \in \semTerm{\vctx, x : \sort \proves P : \Prop}_{\gamma[x \mapsto v]}(W) \,\} \Lam W. \{\, (n, r) \mid \Exists v \in \Sem{\sort}. (n, r) \in \Sem{\vctx, x : \sort \proves P : \Prop}_{\gamma[x \mapsto v]}(W) \,\}
\end{align*} \end{align*}
% %
\begin{align*} \begin{align*}
\semTerm{\vctx \proves \always{\prop} : \Prop}_\gamma &= \always{\semTerm{\vctx \proves \prop : \Prop}_\gamma} \\ \Sem{\vctx \proves \always{\prop} : \Prop}_\gamma &= \always{\Sem{\vctx \proves \prop : \Prop}_\gamma} \\
\semTerm{\vctx \proves \later{\prop} : \Prop}_\gamma &= \later \semTerm{\vctx \proves \prop : \Prop}_\gamma\\ \Sem{\vctx \proves \later{\prop} : \Prop}_\gamma &= \later \Sem{\vctx \proves \prop : \Prop}_\gamma\\
\semTerm{\vctx \proves \MU x. \pred : \sort \to \Prop}_\gamma &= \Sem{\vctx \proves \MU x. \pred : \sort \to \Prop}_\gamma &=
\mathit{fix}(\Lam v : \semSort{\sort \to \Prop}. \semTerm{\vctx, x : \sort \to \Prop \proves \pred : \sort \to \Prop}_{\gamma[x \mapsto v]}) \\ \mathit{fix}(\Lam v : \Sem{\sort \to \Prop}. \Sem{\vctx, x : \sort \to \Prop \proves \pred : \sort \to \Prop}_{\gamma[x \mapsto v]}) \\
\semTerm{\vctx \proves \prop * \propB : \Prop}_\gamma &= \Sem{\vctx \proves \prop * \propB : \Prop}_\gamma &=
\begin{aligned}[t] \begin{aligned}[t]
\Lam W. \{\, (n, r) &\mid \Exists r_1, r_2. r = r_1 \bullet r_2 \land{} \\ \Lam W. \{\, (n, r) &\mid \Exists r_1, r_2. r = r_1 \bullet r_2 \land{} \\
&\qquad &\qquad
(n, r_1) \in \semTerm{\vctx \proves \prop : \Prop}_\gamma \land{} \\ (n, r_1) \in \Sem{\vctx \proves \prop : \Prop}_\gamma \land{} \\
&\qquad &\qquad
(n, r_2) \in \semTerm{\vctx \proves \propB : \Prop}_\gamma \,\} (n, r_2) \in \Sem{\vctx \proves \propB : \Prop}_\gamma \,\}
\end{aligned} \\ \end{aligned} \\
\semTerm{\vctx \proves \prop \wand \propB : \Prop}_\gamma &= \Sem{\vctx \proves \prop \wand \propB : \Prop}_\gamma &=
\begin{aligned}[t] \begin{aligned}[t]
\Lam W. \{\, (n, r) &\mid \All n' \leq n. \All W' \geq W. \All r'. \\ \Lam W. \{\, (n, r) &\mid \All n' \leq n. \All W' \geq W. \All r'. \\
&\qquad &\qquad
(n', r') \in \semTerm{\vctx \proves \prop : \Prop}_\gamma(W') \land r \sep r' \\ (n', r') \in \Sem{\vctx \proves \prop : \Prop}_\gamma(W') \land r \sep r' \\
&\qquad &\qquad
\implies (n', r \bullet r') \in \semTerm{\vctx \proves \propB : \Prop}_\gamma(W') \implies (n', r \bullet r') \in \Sem{\vctx \proves \propB : \Prop}_\gamma(W')
\} \}
\end{aligned} \\ \end{aligned} \\
\semTerm{\vctx \proves \knowInv{\iname}{\prop} : \Prop}_\gamma &= \Sem{\vctx \proves \knowInv{\iname}{\prop} : \Prop}_\gamma &=
inv(\semTerm{\vctx \proves \iname : \textsort{InvName}}_\gamma, \semTerm{\vctx \proves \prop : \Prop}_\gamma) \\ inv(\Sem{\vctx \proves \iname : \textsort{InvName}}_\gamma, \Sem{\vctx \proves \prop : \Prop}_\gamma) \\
\semTerm{\vctx \proves \ownGGhost{\melt} : \Prop}_\gamma &= \Sem{\vctx \proves \ownGGhost{\melt} : \Prop}_\gamma &=
\Lam W. \{\, (n, \rs) \mid \rs.\ghostRes \geq \semTerm{\vctx \proves \melt : \textsort{Monoid}}_\gamma \,\} \\ \Lam W. \{\, (n, \rs) \mid \rs.\ghostRes \geq \Sem{\vctx \proves \melt : \textsort{Monoid}}_\gamma \,\} \\
\semTerm{\vctx \proves \ownPhys{\state} : \Prop}_\gamma &= \Sem{\vctx \proves \ownPhys{\state} : \Prop}_\gamma &=
\Lam W. \{\, (n, \rs) \mid \rs.\pres = \semTerm{\vctx \proves \state : \textsort{State}}_\gamma \,\} \Lam W. \{\, (n, \rs) \mid \rs.\pres = \Sem{\vctx \proves \state : \textsort{State}}_\gamma \,\}
\end{align*} \end{align*}
% %
\begin{align*} \begin{align*}
\semTerm{\vctx \proves \pvsA{\prop}{\mask_1}{\mask_2} : \Prop}_\gamma &= \Sem{\vctx \proves \pvsA{\prop}{\mask_1}{\mask_2} : \Prop}_\gamma &=
\textdom{vs}^{\semTerm{\vctx \proves \mask_2 : \textsort{InvMask}}_\gamma}_{\semTerm{\vctx \proves \mask_1 : \textsort{InvMask}}_\gamma}(\semTerm{\vctx \proves \prop : \Prop}_\gamma) \\ \textdom{vs}^{\Sem{\vctx \proves \mask_2 : \textsort{InvMask}}_\gamma}_{\Sem{\vctx \proves \mask_1 : \textsort{InvMask}}_\gamma}(\Sem{\vctx \proves \prop : \Prop}_\gamma) \\
\semTerm{\vctx \proves \dynA{\expr}{\pred}{\mask} : \Prop}_\gamma &= \Sem{\vctx \proves \dynA{\expr}{\pred}{\mask} : \Prop}_\gamma &=
\textdom{wp}_{\semTerm{\vctx \proves \mask : \textsort{InvMask}}_\gamma}(\semTerm{\vctx \proves \expr : \textsort{Exp}}_\gamma, \semTerm{\vctx \proves \pred : \textsort{Val} \to \Prop}_\gamma) \\ \textdom{wp}_{\Sem{\vctx \proves \mask : \textsort{InvMask}}_\gamma}(\Sem{\vctx \proves \expr : \textsort{Exp}}_\gamma, \Sem{\vctx \proves \pred : \textsort{Val} \to \Prop}_\gamma) \\
\semTerm{\vctx \proves \wtt{\timeless{\prop}}{\Prop}}_\gamma &= \Sem{\vctx \proves \wtt{\timeless{\prop}}{\Prop}}_\gamma &=
\textdom{timeless}(\semTerm{\vctx \proves \prop : \Prop}_\gamma) \textdom{timeless}(\Sem{\vctx \proves \prop : \Prop}_\gamma)
\end{align*} \end{align*}
\typedsection{Interpretation of entailment}{\Sem{\vctx \mid \pfctx \proves \prop} : 2 \in \mathit{Sets}} \typedsection{Interpretation of entailment}{\Sem{\vctx \mid \pfctx \proves \prop} : 2 \in \mathit{Sets}}
...@@ -514,10 +514,10 @@ $\rho\nequiv{n} \rho' \iff n=0 \lor \bigl(\dom(\rho)=\dom(\rho') \land ...@@ -514,10 +514,10 @@ $\rho\nequiv{n} \rho' \iff n=0 \lor \bigl(\dom(\rho)=\dom(\rho') \land
\forall n \in \mathbb{N}.\; \forall n \in \mathbb{N}.\;
\forall W \in \textdom{World}.\; \forall W \in \textdom{World}.\;
\forall \rs \in \textdom{Res}.\; \forall \rs \in \textdom{Res}.\;
\forall \gamma \in \semSort{\vctx},\; \forall \gamma \in \Sem{\vctx},\;
\\& \\&
\bigl(\All \propB \in \pfctx. (n, \rs) \in \semTerm{\vctx \proves \propB : \Prop}_\gamma(W)\bigr) \bigl(\All \propB \in \pfctx. (n, \rs) \in \Sem{\vctx \proves \propB : \Prop}_\gamma(W)\bigr)
\implies (n, \rs) \in \semTerm{\vctx \proves \prop : \Prop}_\gamma(W) \implies (n, \rs) \in \Sem{\vctx \proves \prop : \Prop}_\gamma(W)
\end{aligned} \end{aligned}
\] \]
......
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment