Can one function feed another?
Diagram
Composition maps into reached subsets
In fg, apply g first and f second. The direct composite arrow reaches the same output as the two successive arrows.
Apply g, then f
This mapping uses the whole domain of g only when every output reached by g is accepted by f.
- Intermediate outputsA subset of the outer domain
: only inputs reached by g are passed into f. They need not fill the whole domain of f.
- Final outputsA subset of the outer range
. The composite’s reached outputs can form a smaller set than the whole range of f.
If the inclusion fails, fg does not exist on the whole stated domain of g. Any restriction must be stated explicitly. Changing the order requires a different range–domain check.