A restriction of a function is a new function obtained by limiting the domain: if f:A→Bf:A\to B is a and S⊆AS\subseteq A, then the restriction f∣S:S→Bf|_S:S\to B is defined by

f∣S(s)=f(s)for all s∈S.f|_S(s)=f(s)\quad\text{for all }s\in S.
Remarks

A restriction changes the while keeping the same . The of f∣Sf|_S is obtained by intersecting the graph of ff with the subset S×BS\times B of the A×BA\times B.

Examples
  • If f:R→Rf:\mathbb{R}\to\mathbb{R} is f(x)=x2f(x)=x^2 and S=Z⊆RS=\mathbb{Z}\subseteq\mathbb{R}, then f∣S:Z→Rf|_S:\mathbb{Z}\to\mathbb{R} is the squaring function on integers.
  • If AA is a set and S⊆AS\subseteq A, then idA∣S:S→A\mathrm{id}_A|_S:S\to A is the inclusion map s↦ss\mapsto s.