For a function f:X→Y and a subset A⊆X, the restriction of f to A is the function, denoted f|A, with domain A and codomain Y, such that f|A(a) = f(a) for all a in A. Thus, f|A is essentially the same assignment as f but applied to a restricted set of inputs.