Functions as Sets
Every function f : R ? S can be represented by its graph:
- graph(f) = {(x, f(x))| x ? R} ? R x S
Successor function on Z {…,(-2,-1), (-1,0), (0,1), (1,2), …}
Function application
- f(a) = b ? (a,b) ? graph f
- f(a) = apply(graph(f), a)
Function composition
- graph(g o f) =
{(x, z)| x ? R and, for some y ? S,
(x, y) ? graph(f) and (y, z) ? graph(g)}