4

The standard definition of function composition is:

Let $f : A \to B$, $g : B \to C$ then there is a composite function $g \circ f : A \to C$, given by $(g \circ f)(a) = g(f(a))$ with $a \in A$

Why could not be given a less restrictive definition like the following?

If $f : A \to B$, $g : D \to C$, $\operatorname{rg}(f) \subseteq D$ then there is a composite function $g \circ f : A \to C$, given by $(g \circ f)(a) = g(f(a))$ with $ a \in A$

  • 5
    Or maybe the domain of $g \circ f$ should just be ${ x \in A \mid f(x) \in D }$. Then we don't even need to assume the range of $f$ is a subset of $D$. I think people commonly use your less restrictive definition. – littleO Jul 17 '15 at 08:56

1 Answers1

1

The standard definition (say from Wolfram) is in fact the second one. Also, the standard definition allows the range of the function to be a subset of the stated codomain. Note that if you want the composition to be surjective onto the codomain of the second function, then the range of the first must be the domain of the second, and the range of the second must be its codomain.

user21820
  • 57,693
  • 9
  • 98
  • 256
  • I was referring to the definition given in the book "Category Theory", written by Steve Awodey - Carnegie Mellon University (pag. 4) However, thank you for you answer. – Alberto Capitani Jul 17 '15 at 11:01
  • 1
    @AlbertoCapitani: In any case you could always expand the codomain of the first function to match the domain of the second function before composing. – user21820 Jul 17 '15 at 11:07