# Exponential object

In mathematics, specifically in category theory, an exponential object or map object is the categorical generalization of a function space in set theory. Categories with all finite products and exponential objects are called cartesian closed categories. Categories (such as subcategories of Top) without adjoined products may still have an exponential law.[1][2]

## Definition

Let ${\displaystyle \mathbf {C} }$  be a category, let ${\displaystyle Z}$  and ${\displaystyle Y}$  be objects of ${\displaystyle \mathbf {C} }$ , and let ${\displaystyle \mathbf {C} }$  have all binary products with ${\displaystyle Y}$ . An object ${\textstyle Z^{Y}}$  together with a morphism ${\textstyle \mathrm {eval} \colon (Z^{Y}\times Y)\rightarrow Z}$  is an exponential object if for any object ${\displaystyle X}$  and morphism ${\textstyle g\colon X\times Y\to Z}$  there is a unique morphism ${\textstyle \lambda g\colon X\to Z^{Y}}$  (called the transpose of ${\displaystyle g}$ ) such that the following diagram commutes:

This assignment of a unique ${\displaystyle \lambda g}$  to each ${\displaystyle g}$  establishes an isomorphism of hom-sets, ${\textstyle \mathrm {Hom} (X\times Y,Z)\cong \mathrm {Hom} (X,Z^{Y}).}$

If ${\textstyle Z^{Y}}$ exists for all objects ${\displaystyle Z,Y}$  in ${\displaystyle \mathbf {C} }$ , then the functor ${\displaystyle (-)^{Y}\colon \mathbf {C} \to \mathbf {C} }$  defined on objects by ${\displaystyle Z\mapsto Z^{Y}}$  and on arrows by ${\displaystyle (f\colon X\to Z)\mapsto (f^{Y}\colon X^{Y}\to Z^{Y})}$ , is a right adjoint to the product functor ${\displaystyle -\times Y}$ . For this reason, the morphisms ${\displaystyle \lambda g}$  and ${\displaystyle g}$  are sometimes called exponential adjoints of one another.[3]

### Equational definition

Alternatively, the exponential object may be defined through equations:

• Existence of ${\displaystyle \lambda g}$  is guaranteed by existence of the operation ${\displaystyle \lambda -}$ .
• Commutativity of the diagrams above is guaranteed by the equality ${\displaystyle \forall g\colon X\times Y\to Z,\ \mathrm {eval} \circ (\lambda g\times \mathrm {id} _{Y})=g}$ .
• Uniqueness of ${\displaystyle \lambda g}$  is guaranteed by the equality ${\displaystyle \forall h\colon X\to Z^{Y},\ \lambda (\mathrm {eval} \circ (h\times \mathrm {id} _{Y}))=h}$ .

### Universal property

The exponential ${\displaystyle Z^{Y}}$  is given by a universal morphism from the product functor ${\displaystyle -\times Y}$  to the object ${\displaystyle Z}$ . This universal morphism consists of an object ${\displaystyle Z^{Y}}$  and a morphism ${\textstyle \mathrm {eval} \colon (Z^{Y}\times Y)\rightarrow Z}$ .

## Examples

In the category of sets, an exponential object ${\displaystyle Z^{Y}}$  is the set of all functions ${\displaystyle Y\to Z}$ .[4] The map ${\displaystyle \mathrm {eval} \colon (Z^{Y}\times Y)\to Z}$  is just the evaluation map, which sends the pair ${\displaystyle (f,y)}$  to ${\displaystyle f(y)}$ . For any map ${\displaystyle g\colon (X\times Y)\rightarrow Z}$  the map ${\displaystyle \lambda g\colon X\to Z^{Y}}$  is the curried form of ${\displaystyle g}$ :

${\displaystyle \lambda g(x)(y)=g(x,y).\,}$

A Heyting algebra ${\displaystyle H}$  is just a bounded lattice that has all exponential objects. Heyting implication, ${\displaystyle Y\Rightarrow Z}$ , is an alternative notation for ${\displaystyle Z^{Y}}$ . The above adjunction results translate to implication (${\displaystyle \Rightarrow :H\times H\to H}$ ) being right adjoint to meet (${\displaystyle \wedge :H\times H\to H}$ ). This adjunction can be written as ${\displaystyle (-\wedge Y)\dashv (Y\Rightarrow -)}$ , or more fully as:

${\displaystyle (-\wedge Y):H{\stackrel {\longrightarrow }{\underset {\longleftarrow }{\top }}}H:(Y\Rightarrow -)}$

In the category of topological spaces, the exponential object ${\displaystyle Z^{Y}}$  exists provided that ${\displaystyle Y}$  is a locally compact Hausdorff space. In that case, the space ${\displaystyle Z^{Y}}$  is the set of all continuous functions from ${\displaystyle Y}$  to ${\displaystyle Z}$  together with the compact-open topology. The evaluation map is the same as in the category of sets; it is continuous with the above topology.[5] If ${\displaystyle Y}$  is not locally compact Hausdorff, the exponential object may not exist (the space ${\displaystyle Z^{Y}}$  still exists, but it may fail to be an exponential object since the evaluation function need not be continuous). For this reason the category of topological spaces fails to be cartesian closed. However, the category of locally compact topological spaces is not cartesian closed either, since ${\displaystyle Z^{Y}}$  need not be locally compact for locally compact spaces ${\displaystyle Z}$  and ${\displaystyle Y}$ . A cartesian closed category of spaces is, for example, given by the full subcategory spanned by the compactly generated Hausdorff spaces.

In functional programming languages, the morphism ${\displaystyle \operatorname {eval} }$  is often called ${\displaystyle \operatorname {apply} }$ , and the syntax ${\displaystyle \lambda g}$  is often written ${\displaystyle \operatorname {curry} (g)}$ . The morphism ${\displaystyle \operatorname {eval} }$  here must not to be confused with the eval function in some programming languages, which evaluates quoted expressions.