Skip to content
This repository has been archived by the owner on Oct 24, 2021. It is now read-only.

Notes 0407 #22

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Notes 0407 #22

wants to merge 2 commits into from

Conversation

remexre
Copy link
Collaborator

@remexre remexre commented Apr 21, 2020

No description provided.

@favonia favonia assigned favonia and unassigned favonia Apr 21, 2020
@favonia favonia self-requested a review April 21, 2020 23:29

Nevertheless, there are two differences between the two operators.
First, the underlying type of a face may change along coercion, but it is not the case for homogeneous composition (as already remarked in Sect.~\ref{HomogeneousComposition}).
Oh the other hand, we may specify faces other than a cap of a box for homogeneous composition (see Sect.~\ref{HomogeneousComposition}), but it is not the case for coercion.
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/Oh/On/

\hypo{\oftype{M}{\dfuntype{x}{A}{B}}}
\hypo{\oftype{r}{\mathbb{I}}}
\infer2{\eqterm{\mathtt{transp}^i\,\parens{\dfuntype{x}{A}{B}}\,r\,M}
{\lam{x}[A]{\mathtt{transp}^i\,B[x \mapsto \text{\texttt{transp-fill}}^{\texttildelow i}\,A\,r\,x]\,r\,\parens{\app{M}{\parens{\text{\texttt{transp-fill}}^1\,A\,r\,x}}}}}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The second transp-fill^1 should be the reversed transp.


\subsection{Positive Types}

Coercion simply ``just works'' for inductive types:
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically, this would not work for List(A) or A+B. You need to push the coercion inside the constructors.

\infer2{\eqterm{\mathtt{transp}^i\,A\,\varphi\,M}{M}{A}}
\end{prooftree*}

Homogeneous composition, on the other hand, requires a bit of a trick; since $N$ might not be constant (i.e., $N[i\mapsto0]\equiv N[i\mapsto1]$ might not hold). Here, $\mathtt{hcomp}$ adds additional values to the type; since type declarations only define an inductive type that's generated by a certain description, this is acceptable. Furthermore, the new values commute with elimination, which makes these new values aren't really ``stuck terms.''
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reason is not because N is not constant (it is constant). The reason is that even if there is a path between two elements of N under some context, they are not provably judgmentally equal in our setting.


%To make homogeneous composition useful in type theory, we extend it to boxes with multiple missing faces.
Let us remark that as long as the cap of a box is present we can apply homogeneous composition to the box \emph{even if the other faces are absent}.
Also, to apply homogeneous composition, the faces of a box must share the \emph{same} type; this point explains the terminology \emph{homogeneous} composition.
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The faces might still have different types. The composition is homogeneous because the type is not changing along the composition dimension, but it can still be changing in other dimensions.


Because of the unit type's simple structure, nothing particularly interesting can happen here.

\subsection{Empty}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you mean the unit type or the empty type? BTW, the empty type should be done in the same way as other inductively defined types.

@favonia
Copy link
Owner

favonia commented Apr 27, 2020

Overall the note looks good. Please see the above comments! :-)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants