Contents
Idea
In the same way that one could define equivalence types as types of one-to-one correspondences and function types as types of anafunctions, one could define partial function types as types of partial anafunctions.
Partial anafunctions are type families which comes with a family of witnesses
that for each element , the dependent sum type is a mere proposition. From every partial anafunction, one could derive the partial function
and for every mere proposition-valued type family and every partial function , one could define the partial anafunction as
Defining partial function types requires both identity types and indexed heterogeneous identity types being defined first, which we shall write as and respectively for , , , , and . We use the notation to represent the type of partial functions between and .
Rules for partial function types
The rules for partial function types are as follows:
By the rules for dependent sum types and dependent product types, one could derive that
which is precisely the statement that is a partial anafunction for all partial functions .
See also