TheInfoList

In
mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no general consensus abo ...
, specifically
category theory Category theory formalizes and its concepts in terms of a called a ', whose nodes are called ''objects'', and whose labelled directed edges are called ''arrows'' (or s). A has two basic properties: the ability to the arrows , and the exi ...
, a functor is a
mapping Mapping may refer to: * Mapping (cartography), the process of making a map * Mapping (mathematics), a synonym for a mathematical function and its generalizations ** Mapping (logic), a synonym for functional predicate Types of mapping * Animated ...
between
categories Category, plural categories, may refer to: Philosophy and general uses *Categorization Categorization is the human ability and activity of recognizing shared features or similarities between the elements of the experience of the world (such ...
. Functors were first considered in
algebraic topology 250px, A torus, one of the most frequently studied objects in algebraic topology Algebraic topology is a branch of mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathemat ...
, where algebraic objects (such as the
fundamental group In the mathematical field of algebraic topology, the fundamental group of a topological space is the group of the equivalence class In mathematics, when the elements of some set (mathematics), set have a notion of equivalence (formalized ... ) are associated to
topological space In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no gener ...
s, and maps between these algebraic objects are associated to
continuous Continuity or continuous may refer to: Mathematics * Continuity (mathematics), the opposing concept to discreteness; common examples include ** Continuous probability distribution or random variable in probability and statistics ** Continuous ga ...
maps between spaces. Nowadays, functors are used throughout modern mathematics to relate various categories. Thus, functors are important in all areas within mathematics to which
category theory Category theory formalizes and its concepts in terms of a called a ', whose nodes are called ''objects'', and whose labelled directed edges are called ''arrows'' (or s). A has two basic properties: the ability to the arrows , and the exi ...
is applied. The words ''category'' and ''functor'' were borrowed by mathematicians from the philosophers
Aristotle Aristotle (; grc-gre, Ἀριστοτέλης ''Aristotélēs'', ; 384–322 BC) was a Greek philosopher A philosopher is someone who practices philosophy Philosophy (from , ) is the study of general and fundamental quest ... and
Rudolf Carnap Rudolf Carnap (; ; 18 May 1891 – 14 September 1970) was a German-language philosopher who was active in Europe before 1935 and in the United States thereafter. He was a major member of the Vienna Circle The Vienna Circle (german: Wiener Kreis) ...
, respectively. The latter used ''functor'' in a
linguistic Linguistics is the scientific study of language A language is a structured system of communication used by humans, including speech (spoken language), gestures (Signed language, sign language) and writing. Most languages have a writing ... context; see
function word In linguistics Linguistics is the science, scientific study of language. It encompasses the analysis of every aspect of language, as well as the methods for studying and modeling them. The traditional areas of linguistic analysis include ph ...
.

# Definition

Let ''C'' and ''D'' be
categories Category, plural categories, may refer to: Philosophy and general uses *Categorization Categorization is the human ability and activity of recognizing shared features or similarities between the elements of the experience of the world (such ...
. A functor ''F'' from ''C'' to ''D'' is a mapping that * associates each object $X$ in ''C'' to an object $F\left(X\right)$ in ''D'', * associates each morphism $f \colon X \to Y$ in ''C'' to a morphism $F\left(f\right) \colon F\left(X\right) \to F\left(Y\right)$ in ''D'' such that the following two conditions hold: ** $F\left(\mathrm_\right) = \mathrm_\,\!$ for every object $X$ in ''C'', ** $F\left(g \circ f\right) = F\left(g\right) \circ F\left(f\right)$ for all morphisms $f \colon X \to Y\,\!$ and $g \colon Y\to Z$ in ''C''. That is, functors must preserve
identity morphisms and
composition Composition or Compositions may refer to: Arts * Composition (dance), practice and teaching of choreography * Composition (music), an original piece of music and its creation *Composition (visual arts) The term composition means "putting togethe ...
of morphisms.

## Covariance and contravariance

There are many constructions in mathematics that would be functors but for the fact that they "turn morphisms around" and "reverse composition". We then define a contravariant functor ''F'' from ''C'' to ''D'' as a mapping that *associates to each object $X$ in ''C'' with an object $F\left(X\right)$ in ''D'', *associates to each morphism $f \colon X\to Y$ in ''C'' with a morphism $F\left(f\right) \colon F\left(Y\right) \to F\left(X\right)$ in ''D'' such that the following two conditions hold: **$F\left(\mathrm_X\right) = \mathrm_\,\!$ for every object $X$ in ''C'', **$F\left(g \circ f\right) = F\left(f\right) \circ F\left(g\right)$ for all morphisms $f \colon X\to Y$ and $g \colon Y\to Z$ in ''C''. Note that contravariant functors reverse the direction of composition. Ordinary functors are also called covariant functors in order to distinguish them from contravariant ones. Note that one can also define a contravariant functor as a ''covariant'' functor on the
opposite categoryIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ...
$C^\mathrm$. Some authors prefer to write all expressions covariantly. That is, instead of saying $F \colon C\to D$ is a contravariant functor, they simply write $F \colon C^ \to D$ (or sometimes $F \colon C \to D^$) and call it a functor. Contravariant functors are also occasionally called ''cofunctors''. There is a convention which refers to "vectors"—i.e.,
vector field In vector calculus and physics, a vector field is an assignment of a vector to each point in a subset of space. For instance, a vector field in the plane can be visualised as a collection of arrows with a given magnitude and direction, each att ... s, elements of the space of sections $\Gamma\left(TM\right)$ of a
tangent bundle Image:Tangent bundle.svg, Informally, the tangent bundle of a manifold (which in this case is a circle) is obtained by considering all the tangent spaces (top), and joining them together in a smooth and non-overlapping manner (bottom). In differen ... $TM$—as "contravariant" and to "covectors"—i.e., 1-forms, elements of the space of sections $\Gamma\left(T^*M\right)$ of a
cotangent bundle In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It h ...
$T^*M$—as "covariant". This terminology originates in physics, and its rationale has to do with the position of the indices ("upstairs" and "downstairs") in
expressions Expression may refer to: Linguistics * Expression (linguistics), a word, phrase, or sentence * Fixed expression, a form of words with a specific meaning * Idiom, a type of fixed expression * Metaphor#Common types, Metaphorical expression, a parti ...
such as $x\text{'}^ = \Lambda^i_j x^j$ for $\mathbf\text{'} = \boldsymbol\mathbf$ or $\omega\text{'}_i = \Lambda^j_i \omega_j$ for $\boldsymbol\text{'} = \boldsymbol\boldsymbol^T.$ In this formalism it is observed that the coordinate transformation symbol $\Lambda^j_i$ (representing the matrix $\boldsymbol^T$) acts on the basis vectors "in the same way" as on the "covector coordinates": $\mathbf_i = \Lambda^j_i\mathbf_j$—whereas it acts "in the opposite way" on the "vector coordinates" (but "in the same way" as on the basis covectors: $\mathbf^i = \Lambda^i_j \mathbf^j$). This terminology is contrary to the one used in category theory because it is the covectors that have ''pullbacks'' in general and are thus ''contravariant'', whereas vectors in general are ''covariant'' since they can be ''pushed forward''. See also
Covariance and contravariance of vectors In probability theory Probability theory is the branch of mathematics concerned with probability. Although there are several different probability interpretations, probability theory treats the concept in a rigorous mathematical manner by expre ...
.

## Opposite functor

Every functor $F \colon C\to D$ induces the opposite functor $F^\mathrm \colon C^\mathrm\to D^\mathrm$, where $C^\mathrm$ and $D^\mathrm$ are the opposite categories to $C$ and $D$. By definition, $F^\mathrm$ maps objects and morphisms identically to $F$. Since $C^\mathrm$ does not coincide with $C$ as a category, and similarly for $D$, $F^\mathrm$ is distinguished from $F$. For example, when composing $F \colon C_0\to C_1$ with $G \colon C_1^\mathrm\to C_2$, one should use either $G\circ F^\mathrm$ or $G^\mathrm\circ F$. Note that, following the property of
opposite categoryIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ...
, $\left(F^\mathrm\right)^\mathrm = F$.

## Bifunctors and multifunctors

A bifunctor (also known as a binary functor) is a functor whose domain is a
product category In the mathematical field of category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objec ... . For example, the
Hom functorIn mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ha ... is of the type . It can be seen as a functor in ''two'' arguments. The
Hom functorIn mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ha ... is a natural example; it is contravariant in one argument, covariant in the other. A multifunctor is a generalization of the functor concept to ''n'' variables. So, for example, a bifunctor is a multifunctor with .

# Examples

Diagram A diagram is a symbolic representation Representation may refer to: Law and politics *Representation (politics) Political representation is the activity of making citizens "present" in public policy making processes when political actors act in ...
: For categories ''C'' and ''J'', a diagram of type ''J'' in ''C'' is a covariant functor $D \colon J\to C$. (Category theoretical) presheaf: For categories ''C'' and ''J'', a ''J''-presheaf on ''C'' is a contravariant functor $D \colon C\to J$. Presheaves: If ''X'' is a
topological space In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no gener ...
, then the
open set In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). I ...
s in ''X'' form a
partially ordered set upright=1.15, Fig.1 The Hasse diagram of the Power set, set of all subsets of a three-element set \, ordered by set inclusion, inclusion. Sets connected by an upward path, like \emptyset and \, are comparable, while e.g. \ and \ are not. In mathem ...
Open(''X'') under inclusion. Like every partially ordered set, Open(''X'') forms a small category by adding a single arrow if and only if $U \subseteq V$. Contravariant functors on Open(''X'') are called ''
presheaves In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ...
'' on ''X''. For instance, by assigning to every open set ''U'' the
associative algebra In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). I ...
of real-valued continuous functions on ''U'', one obtains a presheaf of algebras on ''X''. Constant functor: The functor which maps every object of ''C'' to a fixed object ''X'' in ''D'' and every morphism in ''C'' to the identity morphism on ''X''. Such a functor is called a ''constant'' or ''selection'' functor. Endofunctor: A functor that maps a category to that same category; e.g.,
polynomial functorIn algebra, a polynomial functor is an endofunctor on the category \mathcal of finite-dimensional vector spaces that depends polynomially on vector spaces. For example, the symmetric powers V \mapsto \operatorname^n(V) and the exterior powers V \m ...
. Identity functor: in category ''C'', written 1''C'' or id''C'', maps an object to itself and a morphism to itself. The identity functor is an endofunctor. Diagonal functor: The
diagonal functorIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ... is defined as the functor from ''D'' to the functor category ''D''''C'' which sends each object in ''D'' to the constant functor at that object. Limit functor: For a fixed
index categoryIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ...
''J'', if every functor has a
limit Limit or Limits may refer to: Arts and media * Limit (music), a way to characterize harmony * Limit (song), "Limit" (song), a 2016 single by Luna Sea * Limits (Paenda song), "Limits" (Paenda song), 2019 song that represented Austria in the Eurov ...
(for instance if ''C'' is complete), then the limit functor assigns to each functor its limit. The existence of this functor can be proved by realizing that it is the right-adjoint to the
diagonal functorIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ... and invoking the Freyd adjoint functor theorem. This requires a suitable version of the
axiom of choice In , the axiom of choice, or AC, is an of equivalent to the statement that ''a of a collection of non-empty sets is non-empty''. Informally put, the axiom of choice says that given any collection of bins, each containing at least one object ... . Similar remarks apply to the colimit functor (which assigns to every functor its colimit, and is covariant). Power sets functor: The power set functor maps each set to its
power set In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no g ...
and each function $f \colon X \to Y$ to the map which sends $U \in \mathcal\left(X\right)$ to its image $f\left(U\right) \in \mathcal\left(Y\right)$. One can also consider the contravariant power set functor which sends $f \colon X \to Y$ to the map which sends $V \subseteq Y$ to its
inverse image In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). ... $f^\left(V\right) \subseteq X.$ For example, if $X = \$ then $F\left(X\right) = \mathcal\left(X\right) = \$. Suppose $f\left(0\right) = \$ and $f\left(1\right) = X$. Then $F\left(f\right)$ is the function which sends any subset $U$ of $X$ to its image $f\left(U\right)$, which in this case means $\ \mapsto f\left(\\right) = \$, where $\mapsto$ denotes the mapping under $F\left(f\right)$, so this could also be written as $\left(F\left(f\right)\right)\left(\\right)= \$. For the other values, $\ \mapsto f\left(\\right) = \ = \, \ \mapsto f\left(\\right) = \ = \, \ \mapsto f\left(\\right) = \ = \.$ Note that $f\left(\\right)$ consequently generates the
trivial topologyIn topology s, which have only one surface and one edge, are a kind of object studied in topology. In mathematics, topology (from the Greek language, Greek words , and ) is concerned with the properties of a mathematical object, geometric object ...
on $X$. Also note that although the function $f$ in this example mapped to the power set of $X$, that need not be the case in general. : The map which assigns to every
vector space In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). ...
its
dual space In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no gen ...
and to every
linear map In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). I ...
its dual or transpose is a contravariant functor from the category of all vector spaces over a fixed
field Field may refer to: Expanses of open ground * Field (agriculture), an area of land used for agricultural purposes * Airfield, an aerodrome that lacks the infrastructure of an airport * Battlefield * Lawn, an area of mowed grass * Meadow, a grassl ...
to itself. Fundamental group: Consider the category of pointed topological spaces, i.e. topological spaces with distinguished points. The objects are pairs , where ''X'' is a topological space and ''x''0 is a point in ''X''. A morphism from to is given by a
continuous Continuity or continuous may refer to: Mathematics * Continuity (mathematics), the opposing concept to discreteness; common examples include ** Continuous probability distribution or random variable in probability and statistics ** Continuous ga ...
map with . To every topological space ''X'' with distinguished point ''x''0, one can define the
fundamental group In the mathematical field of algebraic topology, the fundamental group of a topological space is the group of the equivalence class In mathematics, when the elements of some set (mathematics), set have a notion of equivalence (formalized ... based at ''x''0, denoted . This is the
group A group is a number A number is a mathematical object used to counting, count, measurement, measure, and nominal number, label. The original examples are the natural numbers 1, 2, 3, 4, and so forth. Numbers can be represented in language with ...
of
homotopy In topology s, which have only one surface and one edge, are a kind of object studied in topology. In mathematics, topology (from the Greek language, Greek words , and ) is concerned with the properties of a mathematical object, geometric o ... classes of loops based at ''x''0, with the group operation of concatenation. If is a morphism of
pointed space In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ...
s, then every loop in ''X'' with base point ''x''0 can be composed with ''f'' to yield a loop in ''Y'' with base point ''y''0. This operation is compatible with the homotopy
equivalence relation In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). ...
and the composition of loops, and we get a
group homomorphism In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no ge ... from to . We thus obtain a functor from the category of pointed topological spaces to the
category of groups In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ...
. In the category of topological spaces (without distinguished point), one considers homotopy classes of generic curves, but they cannot be composed unless they share an endpoint. Thus one has the fundamental
groupoid In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ...
instead of the fundamental group, and this construction is functorial. Algebra of continuous functions: a contravariant functor from the category of
topological spaces In mathematics, a topological space is, roughly speaking, a geometry, geometrical space in which ''closeness'' is defined but, generally, cannot be measured by a numeric distance. More specifically, a topological space is a Set (mathematics), set of ... (with continuous maps as morphisms) to the category of real
associative algebra In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). I ...
s is given by assigning to every topological space ''X'' the algebra C(''X'') of all real-valued continuous functions on that space. Every continuous map induces an
algebra homomorphism In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It h ...
by the rule for every ''φ'' in C(''Y''). Tangent and cotangent bundles: The map which sends every
differentiable manifold In mathematics, a differentiable manifold (also differential manifold) is a type of manifold The real projective plane is a two-dimensional manifold that cannot be realized in three dimensions without self-intersection, shown here as Boy's surfa ...
to its
tangent bundle Image:Tangent bundle.svg, Informally, the tangent bundle of a manifold (which in this case is a circle) is obtained by considering all the tangent spaces (top), and joining them together in a smooth and non-overlapping manner (bottom). In differen ... and every
smooth map is a smooth function with compact support. In mathematical analysis, the smoothness of a function is a property measured by the number of continuous derivatives it has over some domain. At the very minimum, a function could be considered " ...
to its
derivative In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities ... is a covariant functor from the category of differentiable manifolds to the category of
vector bundle In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no gen ... s. Doing this constructions pointwise gives the
tangent space In , the tangent space of a generalizes to higher dimensions the notion of tangent planes to surfaces in three dimensions and tangent lines to curves in two dimensions. In the context of physics the tangent space to a manifold at a point can ...
, a covariant functor from the category of pointed differentiable manifolds to the category of real vector spaces. Likewise,
cotangent space In differential geometry Differential geometry is a Mathematics, mathematical discipline that uses the techniques of differential calculus, integral calculus, linear algebra and multilinear algebra to study problems in geometry. The Differential ...
is a contravariant functor, essentially the composition of the tangent space with the
dual space In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no gen ...
above. Group actions/representations: Every
group A group is a number A number is a mathematical object used to counting, count, measurement, measure, and nominal number, label. The original examples are the natural numbers 1, 2, 3, 4, and so forth. Numbers can be represented in language with ...
''G'' can be considered as a category with a single object whose morphisms are the elements of ''G''. A functor from ''G'' to Set is then nothing but a
group action In mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). ...
of ''G'' on a particular set, i.e. a ''G''-set. Likewise, a functor from ''G'' to the
category of vector spacesIn algebra Algebra (from ar, الجبر, lit=reunion of broken parts, bonesetting, translit=al-jabr) is one of the areas of mathematics, broad areas of mathematics, together with number theory, geometry and mathematical analysis, analysis. In i ...
, Vect''K'', is a
linear representation Linearity is the property of a mathematical relationship ('' function'') that can be graphically represented as a straight line. Linearity is closely related to proportionality. Examples in physics Physics (from grc, φυσική (� ...
of ''G''. In general, a functor can be considered as an "action" of ''G'' on an object in the category ''C''. If ''C'' is a group, then this action is a group homomorphism. Lie algebras: Assigning to every real (complex)
Lie group In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities a ...
its real (complex)
Lie algebra In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities an ...
defines a functor. Tensor products: If ''C'' denotes the category of vector spaces over a fixed field, with linear maps as morphisms, then the
tensor product In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities and ... $V \otimes W$ defines a functor which is covariant in both arguments. Forgetful functors: The functor which maps a
group A group is a number A number is a mathematical object used to counting, count, measurement, measure, and nominal number, label. The original examples are the natural numbers 1, 2, 3, 4, and so forth. Numbers can be represented in language with ...
to its underlying set and a
group homomorphism In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no ge ... to its underlying function of sets is a functor. Functors like these, which "forget" some structure, are termed ''
forgetful functor In mathematics, in the area of category theory, a forgetful functor (also known as a stripping functor) 'forgets' or drops some or all of the input's structure or properties 'before' mapping to the output. For an algebraic structure of a given signa ...
s''. Another example is the functor which maps a ring to its underlying additive
abelian group In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities an ...
. Morphisms in Rng (
ring homomorphism In ring theory, a branch of abstract algebra, a ring homomorphism is a structure-preserving function (mathematics), function between two ring (algebra), rings. More explicitly, if ''R'' and ''S'' are rings, then a ring homomorphism is a function s ...
s) become morphisms in Ab (abelian group homomorphisms). Free functors: Going in the opposite direction of forgetful functors are free functors. The free functor sends every set ''X'' to the
free group for the free group on two generators would look like. Each vertex represents an element of the free group, and each edge represents multiplication by ''a'' or ''b''. In mathematics Mathematics (from Ancient Greek, Greek: ) includes the stud ...
generated by ''X''. Functions get mapped to group homomorphisms between free groups. Free constructions exist for many categories based on structured sets. See
free object In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities and th ...
. Homomorphism groups: To every pair ''A'', ''B'' of
abelian groups Abelian may refer to: Mathematics Group theory * Abelian group, a group in which the binary operation is commutative ** Category of abelian groups (Ab), has abelian groups as objects and group homomorphisms as morphisms * Metabelian group, a group ...
one can assign the abelian group Hom(''A'', ''B'') consisting of all
group homomorphism In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no ge ... s from ''A'' to ''B''. This is a functor which is contravariant in the first and covariant in the second argument, i.e. it is a functor (where Ab denotes the
category of abelian groupsIn mathematics, the category theory, category Ab has the abelian groups as object (category theory), objects and group homomorphisms as morphisms. This is the prototype of an abelian category: indeed, every Small category, small abelian category can ...
with group homomorphisms). If and are morphisms in Ab, then the group homomorphism : is given by . See
Hom functorIn mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ha ... . Representable functors: We can generalize the previous example to any category ''C''. To every pair ''X'', ''Y'' of objects in ''C'' one can assign the set of morphisms from ''X'' to ''Y''. This defines a functor to Set which is contravariant in the first argument and covariant in the second, i.e. it is a functor . If and are morphisms in ''C'', then the map is given by . Functors like these are called
representable functorIn mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ha ...
s. An important goal in many settings is to determine whether a given functor is representable.

# Properties

Two important consequences of the functor
axiom An axiom, postulate or assumption is a statement that is taken to be truth, true, to serve as a premise or starting point for further reasoning and arguments. The word comes from the Greek ''axíōma'' () 'that which is thought worthy or fit' o ... s are: * ''F'' transforms each
commutative diagram 350px, The commutative diagram used in the proof of the five lemma. In mathematics, and especially in category theory, a commutative diagram is a Diagram (category theory), diagram such that all directed paths in the diagram with the same start an ... in ''C'' into a commutative diagram in ''D''; * if ''f'' is an
isomorphism In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities and ... in ''C'', then ''F''(''f'') is an isomorphism in ''D''. One can compose functors, i.e. if ''F'' is a functor from ''A'' to ''B'' and ''G'' is a functor from ''B'' to ''C'' then one can form the composite functor from ''A'' to ''C''. Composition of functors is associative where defined. Identity of composition of functors is the identity functor. This shows that functors can be considered as morphisms in categories of categories, for example in the
category of small categoriesIn mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ha ...
. A small category with a single object is the same thing as a
monoid In abstract algebra In algebra, which is a broad division of mathematics, abstract algebra (occasionally called modern algebra) is the study of algebraic structures. Algebraic structures include group (mathematics), groups, ring (mathemati ...
: the morphisms of a one-object category can be thought of as elements of the monoid, and composition in the category is thought of as the monoid operation. Functors between one-object categories correspond to monoid
homomorphism In algebra Algebra (from ar, الجبر, lit=reunion of broken parts, bonesetting, translit=al-jabr) is one of the areas of mathematics, broad areas of mathematics, together with number theory, geometry and mathematical analysis, analysis. I ...
s. So in a sense, functors between arbitrary categories are a kind of generalization of monoid homomorphisms to categories with more than one object.

# Relation to other categorical concepts

Let ''C'' and ''D'' be categories. The collection of all functors from ''C'' to ''D'' forms the objects of a category: the
functor categoryIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ...
. Morphisms in this category are
natural transformation In category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dir ... s between functors. Functors are often defined by universal properties; examples are the
tensor product In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which they are contained (geometry), and quantities and ... , the
direct sum The direct sum is an operation from abstract algebra In algebra, which is a broad division of mathematics, abstract algebra (occasionally called modern algebra) is the study of algebraic structures. Algebraic structures include group (mathema ...
and
direct productIn mathematics Mathematics (from Ancient Greek, Greek: ) includes the study of such topics as quantity (number theory), mathematical structure, structure (algebra), space (geometry), and calculus, change (mathematical analysis, analysis). It ha ...
of groups or vector spaces, construction of free groups and modules,
direct Direct may refer to: Mathematics * Directed set In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers (arithmetic and number theory), formulas and related structures (algebra), shapes and spaces in which ...
and
inverse Inverse or invert may refer to: Science and mathematics * Inverse (logic), a type of conditional sentence which is an immediate inference made from another conditional sentence * Additive inverse (negation), the inverse of a number that, when add ...
limits. The concepts of limit and colimit generalize several of the above. Universal constructions often give rise to pairs of
adjoint functors In mathematics Mathematics (from Greek: ) includes the study of such topics as numbers ( and ), formulas and related structures (), shapes and spaces in which they are contained (), and quantities and their changes ( and ). There is no gen ...
.

# Computer implementations

Functors sometimes appear in
functional programming In computer science Computer science deals with the theoretical foundations of information, algorithms and the architectures of its computation as well as practical techniques for their application. Computer science is the study of , ...
. For instance, the programming language Haskell has a
class Class or The Class may refer to: Common uses not otherwise categorized * Class (biology), a taxonomic rank * Class (knowledge representation), a collection of individuals or objects * Class (philosophy), an analytical concept used differently f ...
Functor where
fmap is a polytypic function used to map
functions Function or functionality may refer to: Computing * Function key A function key is a key on a computer A computer is a machine that can be programmed to carry out sequences of arithmetic or logical operations automatically. Modern comp ...

*
Functor categoryIn category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dire ...
*
Kan extensionKan extensions are Universal property, universal constructs in category theory, a branch of mathematics. They are closely related to Adjoint functors, adjoints, but are also related to Limit (category theory), limits and End (category theory), ends. ...
* Pseudofunctor

# References

* .

* * see and the variations discussed and linked to there. * André Joyal
CatLab
a wiki project dedicated to the exposition of categorical mathematics * formal introduction to category theory. * J. Adamek, H. Herrlich, G. Stecker
Abstract and Concrete Categories-The Joy of Cats
* Stanford Encyclopedia of Philosophy:
Category Theory
— by Jean-Pierre Marquis. Extensive bibliography.
List of academic conferences on category theory
* Baez, John, 1996

An informal introduction to higher order categories.
WildCats
is a
category theory Category theory formalizes and its concepts in terms of a called a ', whose nodes are called ''objects'', and whose labelled directed edges are called ''arrows'' (or s). A has two basic properties: the ability to the arrows , and the exi ...
package for Mathematica. Manipulation and visualization of objects, morphisms, categories, functors,
natural transformation In category theory Category theory formalizes mathematical structure and its concepts in terms of a Graph labeling, labeled directed graph called a ''Category (mathematics), category'', whose nodes are called ''objects'', and whose labelled dir ... s, universal properties.
The catsters