Codomain: Difference between revisions
No edit summary |
imported>AllCatsAreGrey m clean up, typo(s) fixed: For example → For example, |
||
| Line 2: | Line 2: | ||
[[File:Codomain2.SVG|right|thumb|250px|A function {{mvar|f}} from {{mvar|X}} to {{mvar|Y}}. The blue oval {{mvar|Y}} is the codomain of {{mvar|f}}. The yellow oval inside {{mvar|Y}} is the [[Image (mathematics)|image]] of {{mvar|f}}, and the red oval {{mvar|X}} is the [[Domain of a function|domain]] of {{mvar|f}}.]] | [[File:Codomain2.SVG|right|thumb|250px|A function {{mvar|f}} from {{mvar|X}} to {{mvar|Y}}. The blue oval {{mvar|Y}} is the codomain of {{mvar|f}}. The yellow oval inside {{mvar|Y}} is the [[Image (mathematics)|image]] of {{mvar|f}}, and the red oval {{mvar|X}} is the [[Domain of a function|domain]] of {{mvar|f}}.]] | ||
In [[mathematics]], a '''codomain''', '''counter-domain''', or '''set of destination''' of a [[Function (mathematics)|function]] is a [[Set (mathematics)|set]] into which all of the | In [[mathematics]], a '''codomain''', '''counter-domain''', or '''set of destination''' of a [[Function (mathematics)|function]] is a [[Set (mathematics)|set]] into which all of the outputs of the function is constrained to fall. It is the set {{mvar|Y}} in the notation {{math|''f'': ''X'' → ''Y''}}. The term '''''[[Range of a function|range]]''''' is sometimes ambiguously used to refer to either the codomain or the [[Image (mathematics)|''image'']] of a function. | ||
A codomain is part of a function {{mvar|f}} if {{mvar|f}} is defined as a triple {{math|(''X'', ''Y'', ''G'')}} where {{mvar|X}} is called the ''[[Domain of a function|domain]]'' of {{mvar|f}}, {{mvar|Y}} its ''codomain'', and {{mvar|G}} its ''[[Graph of a function|graph]]''.<ref>{{Harvnb|Bourbaki|1970|p=76}}</ref> The set of all elements of the form {{math|''f''(''x'')}}, where {{mvar|x}} ranges over the elements of the domain {{mvar|X}}, is called the ''[[Image (mathematics)|image]]'' of {{mvar|f}}. The image of a function is a [[subset]] of its codomain so it might not coincide with it. Namely, a function that is not [[Surjective function|surjective]] has elements {{mvar|y}} in its codomain for which the equation {{math|1=''f''(''x'') = ''y''}} does not have a solution. | A codomain is part of a function {{mvar|f}} if {{mvar|f}} is defined as a triple {{math|(''X'', ''Y'', ''G'')}} where {{mvar|X}} is called the ''[[Domain of a function|domain]]'' of {{mvar|f}}, {{mvar|Y}} its ''codomain'', and {{mvar|G}} its ''[[Graph of a function|graph]]''.<ref>{{Harvnb|Bourbaki|1970|p=76}}</ref> The set of all elements of the form {{math|''f''(''x'')}}, where {{mvar|x}} ranges over the elements of the domain {{mvar|X}}, is called the ''[[Image (mathematics)|image]]'' of {{mvar|f}}. The image of a function is a [[subset]] of its codomain so it might not coincide with it. Namely, a function that is not [[Surjective function|surjective]] has elements {{mvar|y}} in its codomain for which the equation {{math|1=''f''(''x'') = ''y''}} does not have a solution. | ||
A codomain is not part of a function {{mvar|f}} if {{mvar|f}} is defined as just a graph.<ref>{{Harvnb|Bourbaki|1970|p=77}}</ref><ref>{{Harvnb|Forster|2003}}, [{{Google books|plainurl=y|id=mVeTuaRwWssC|page=10|text=Some mathematical cultures make this explicit, saying that a function}} pp. 10–11]</ref> For example in [[set theory]] it is desirable to permit the domain of a function to be a [[Class (set theory)|proper class]] {{mvar|X}}, in which case there is formally no such thing as a triple {{math|(''X'', ''Y'', ''G'')}}. With such a definition functions do not have a codomain, although some authors still use it informally after introducing a function in the form {{math|''f'': ''X'' → ''Y''}}.<ref>{{Harvnb|Eccles|1997}}, p. 91 ([{{Google books|plainurl=y|id=ImCSX_gm40oC|page=91|text=The reader may wonder at this variety of ways of thinking about a function}} quote 1], [{{Google books|plainurl=y|id=ImCSX_gm40oC|page=91|text=When defining a function using a formula it is important to be clear about which sets are the domain and the codomain of the function}} quote 2]); {{Harvnb|Mac Lane|1998}}, [{{Google books|plainurl=y|id=MXboNPdTv7QC|page=8|text=Here "function" means a function with specified domain and specified codomain}} p. 8]; Mac Lane, in {{Harvnb|Scott|Jech|1967}}, [{{Google books|plainurl=y|id=5mf4Vckj0gEC|page=232|text=Note explicitly that the notion of function is not that customary in axiomatic set theory}} p. 232]; {{Harvnb|Sharma|2004}}, [{{Google books|plainurl=y|id=IGvDpe6hYiQC|page=91|text=Functions as sets of ordered pairs}} p. 91]; {{Harvnb|Stewart|Tall|1977}}, [{{Google books|plainurl=y|id=TLelvnIU2sEC|page=89|text=Strictly speaking we cannot talk of 'the' codomain of a function}} p. 89]</ref> | A codomain is not part of a function {{mvar|f}} if {{mvar|f}} is defined as just a graph.<ref>{{Harvnb|Bourbaki|1970|p=77}}</ref><ref>{{Harvnb|Forster|2003}}, [{{Google books|plainurl=y|id=mVeTuaRwWssC|page=10|text=Some mathematical cultures make this explicit, saying that a function}} pp. 10–11]</ref> For example, in [[set theory]] it is desirable to permit the domain of a function to be a [[Class (set theory)|proper class]] {{mvar|X}}, in which case there is formally no such thing as a triple {{math|(''X'', ''Y'', ''G'')}}. With such a definition functions do not have a codomain, although some authors still use it informally after introducing a function in the form {{math|''f'': ''X'' → ''Y''}}.<ref>{{Harvnb|Eccles|1997}}, p. 91 ([{{Google books|plainurl=y|id=ImCSX_gm40oC|page=91|text=The reader may wonder at this variety of ways of thinking about a function}} quote 1], [{{Google books|plainurl=y|id=ImCSX_gm40oC|page=91|text=When defining a function using a formula it is important to be clear about which sets are the domain and the codomain of the function}} quote 2]); {{Harvnb|Mac Lane|1998}}, [{{Google books|plainurl=y|id=MXboNPdTv7QC|page=8|text=Here "function" means a function with specified domain and specified codomain}} p. 8]; Mac Lane, in {{Harvnb|Scott|Jech|1967}}, [{{Google books|plainurl=y|id=5mf4Vckj0gEC|page=232|text=Note explicitly that the notion of function is not that customary in axiomatic set theory}} p. 232]; {{Harvnb|Sharma|2004}}, [{{Google books|plainurl=y|id=IGvDpe6hYiQC|page=91|text=Functions as sets of ordered pairs}} p. 91]; {{Harvnb|Stewart|Tall|1977}}, [{{Google books|plainurl=y|id=TLelvnIU2sEC|page=89|text=Strictly speaking we cannot talk of 'the' codomain of a function}} p. 89]</ref> | ||
== Examples == | == Examples == | ||
| Line 44: | Line 44: | ||
== See also == | == See also == | ||
* {{annotated link|Bijection}} | * {{annotated link|Bijection}} | ||
* {{ | * {{section link|Morphism|Codomain}} | ||
* {{Annotated link|Endofunction#Endofunctions|Endofunction}} | * {{Annotated link|Endofunction#Endofunctions|Endofunction}} | ||
Latest revision as of 00:24, 13 October 2025
In mathematics, a codomain, counter-domain, or set of destination of a function is a set into which all of the outputs of the function is constrained to fall. It is the set Template:Mvar in the notation Template:Math. The term range is sometimes ambiguously used to refer to either the codomain or the image of a function.
A codomain is part of a function Template:Mvar if Template:Mvar is defined as a triple Template:Math where Template:Mvar is called the domain of Template:Mvar, Template:Mvar its codomain, and Template:Mvar its graph.[1] The set of all elements of the form Template:Math, where Template:Mvar ranges over the elements of the domain Template:Mvar, is called the image of Template:Mvar. The image of a function is a subset of its codomain so it might not coincide with it. Namely, a function that is not surjective has elements Template:Mvar in its codomain for which the equation Template:Math does not have a solution.
A codomain is not part of a function Template:Mvar if Template:Mvar is defined as just a graph.[2][3] For example, in set theory it is desirable to permit the domain of a function to be a proper class Template:Mvar, in which case there is formally no such thing as a triple Template:Math. With such a definition functions do not have a codomain, although some authors still use it informally after introducing a function in the form Template:Math.[4]
Examples
For a function
defined by
- or equivalently
the codomain of Template:Mvar is , but Template:Mvar does not map to any negative number. Thus the image of Template:Mvar is the set ; i.e., the interval Template:Closed-open.
An alternative function Template:Mvar is defined thus:
While Template:Mvar and Template:Mvar map a given Template:Mvar to the same number, they are not, in this view, the same function because they have different codomains. A third function Template:Mvar can be defined to demonstrate why:
The domain of Template:Mvar cannot be but can be defined to be :
The compositions are denoted
On inspection, Template:Math is not useful. It is true, unless defined otherwise, that the image of Template:Mvar is not known; it is only known that it is a subset of . For this reason, it is possible that Template:Mvar, when composed with Template:Mvar, might receive an argument for which no output is defined – negative numbers are not elements of the domain of Template:Mvar, which is the square root function.
Function composition therefore is a useful notion only when the codomain of the function on the right side of a composition (not its image, which is a consequence of the function and could be unknown at the level of the composition) is a subset of the domain of the function on the left side.
The codomain affects whether a function is a surjection, in that the function is surjective if and only if its codomain equals its image. In the example, Template:Mvar is a surjection while Template:Mvar is not. The codomain does not affect whether a function is an injection.
A second example of the difference between codomain and image is demonstrated by the linear transformations between two vector spaces – in particular, all the linear transformations from to itself, which can be represented by the Template:Math matrices with real coefficients. Each matrix represents a map with the domain and codomain . However, the image is uncertain. Some transformations may have image equal to the whole codomain (in this case the matrices with rank Template:Math) but many do not, instead mapping into some smaller subspace (the matrices with rank Template:Math or Template:Math). Take for example the matrix Template:Mvar given by
which represents a linear transformation that maps the point Template:Math to Template:Math. The point Template:Math is not in the image of Template:Mvar, but is still in the codomain since linear transformations from to are of explicit relevance. Just like all Template:Math matrices, Template:Mvar represents a member of that set. Examining the differences between the image and codomain can often be useful for discovering properties of the function in question. For example, it can be concluded that Template:Mvar does not have full rank since its image is smaller than the whole codomain.
See also
Notes
References
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- Script error: No such module "citation/CS1".
- ↑ Script error: No such module "Footnotes".
- ↑ Script error: No such module "Footnotes".
- ↑ Script error: No such module "Footnotes"., [[[:Template:Google books]] pp. 10–11]
- ↑ Script error: No such module "Footnotes"., p. 91 ([[[:Template:Google books]] quote 1], [[[:Template:Google books]] quote 2]); Script error: No such module "Footnotes"., [[[:Template:Google books]] p. 8]; Mac Lane, in Script error: No such module "Footnotes"., [[[:Template:Google books]] p. 232]; Script error: No such module "Footnotes"., [[[:Template:Google books]] p. 91]; Script error: No such module "Footnotes"., [[[:Template:Google books]] p. 89]