Codomain

The target set in the definition of a function
Codomain

A codomain is the target set of a function: if f:ABf:A\to B is a , then its codomain is the set BB.

The of ff is always a of the codomain. The function ff is exactly when its image equals its codomain.

Examples:

  • For f:RRf:\mathbb{R}\to\mathbb{R} defined by f(x)=x2f(x)=x^2, the codomain is R\mathbb{R} even though not every real number occurs as a value of ff.
  • Define p:Z{0,1}p:\mathbb{Z}\to\{0,1\} by p(n)=0p(n)=0 if nn is even and p(n)=1p(n)=1 if nn is odd; the codomain is the set {0,1}\{0,1\}.