请输入您要查询的字词:

 

单词 17CoproductTypes
释义

1.7 Coproduct types


Given A,B:𝒰, we introduce their coproductMathworldPlanetmath type A+B:𝒰.This corresponds to the disjoint unionMathworldPlanetmathPlanetmath in set theoryMathworldPlanetmath, and we may also use that name for it.In type theoryPlanetmathPlanetmath, as was the case with functions and productsPlanetmathPlanetmathPlanetmath, the coproduct must be a fundamental construction, since there is no previously given notion of “union of types”.We also introduce anullary version: the empty type 𝟎:U.

There are two ways to construct elements of A+B, either as 𝗂𝗇𝗅(a):A+B for a:A, or as𝗂𝗇𝗋(b):A+B for b:B. There are no ways to construct elements of the empty type.

To construct a non-dependent function f:A+BC, we needfunctions g0:AC and g1:BC. Then f is definedvia the defining equations

f(𝗂𝗇𝗅(a)):g0(a),
f(𝗂𝗇𝗋(b)):g1(b).

That is, the function f is defined by case analysis.As before, we can derive the recursor:

𝗋𝖾𝖼A+B:(C:𝒰)(AC)(BC)A+BC

with the defining equations

𝗋𝖾𝖼A+B(C,g0,g1,𝗂𝗇𝗅(a)):g0(a),
𝗋𝖾𝖼A+B(C,g0,g1,𝗂𝗇𝗋(b)):g1(b).

We can always construct a function f:𝟎C withouthaving to give any defining equations, because there are no elements of 𝟎 on which to define f.Thus, the recursor for 𝟎 is

𝗋𝖾𝖼𝟎:(C:𝒰)𝟎C,

which constructs the canonical function from the empty type to any other type.Logically, it corresponds to the principle ex falso quodlibet.

To construct a dependent function f:(x:A+B)C(x) out of a coproduct, we assume as given the familyC:(A+B)𝒰, andrequire

g0:a:AC(𝗂𝗇𝗅(a)),
g1:b:BC(𝗂𝗇𝗋(b)).

This yields f with the defining equations:

f(𝗂𝗇𝗅(a)):g0(a),
f(𝗂𝗇𝗋(b)):g1(b).

We package this scheme into the inductionMathworldPlanetmath principle for coproducts:

𝗂𝗇𝖽A+B:(C:(A+B)𝒰)((a:A)C(𝗂𝗇𝗅(a)))((b:B)C(𝗂𝗇𝗋(b)))(x:A+B)C(x).

As before, the recursor arises in the case that the family C isconstant.

The induction principle for the empty type

𝗂𝗇𝖽𝟎:(C:𝟎𝒰)(z:𝟎)C(z)

gives us a way to define a trivial dependent function out of theempty type.

随便看

 

数学辞典收录了18232条数学词条,基本涵盖了常用数学知识及数学英语单词词组的翻译及用法,是数学学习的有利工具。

 

Copyright © 2000-2023 Newdu.com.com All Rights Reserved
更新时间:2025/5/4 19:23:05