Functions Collected into a Set
A function space begins with a simple set-theoretic idea: collect all functions with the same domain and codomain into one set. This notation is useful even before a topology is placed on that set. It lets us talk about individual functions as points, ask what their values are at selected inputs, and distinguish all functions from the continuous ones.
Unless stated otherwise, \(X\) and \(Y\) below are topological spaces with topologies \(\mathcal{T}_X\) and \(\mathcal{T}_Y\). When only sets or functions are under discussion, the topology will play no role. A map \(f:X\to Y\) is continuous if \(f^{-1}(V)\) is open in \(X\) for every open set \(V\) in \(Y\).
The exponent notation \(Y^X\) describes a set, not by itself a topology. An element of \(Y^X\) is one function \(f\), and \(\operatorname{ev}_x\) reads off its value at the chosen input \(x\). The evaluation map is defined only when \(x\in X\); if \(X=\varnothing\), there are no evaluation maps of this form.
There are useful boundary cases. There is exactly one function \(\varnothing\to Y\), namely the empty function, for every set \(Y\), including \(Y=\varnothing\). If \(X\ne\varnothing\) and \(Y=\varnothing\), there is no function \(X\to Y\), so \(Y^X=\varnothing\). The empty function is continuous because the preimage of every open set is \(\varnothing\), which is open.
Evaluating Functions and Identifying Them
Evaluation gives a direct way to compare functions. Two functions with the same domain and codomain are equal exactly when they agree at every input. This fact is often called extensionality of functions; here it follows directly from what it means for two functions to be equal.
Proof. If \(f=g\), then they assign the same value to each \(x\in X\), so \(\operatorname{ev}_x(f)=f(x)=g(x)=\operatorname{ev}_x(g)\) for every \(x\). Conversely, suppose these evaluations agree for every \(x\in X\). Then \(f(x)=g(x)\) for every input in their common domain. Functions with the same domain and codomain that have the same value at every input are the same function, so \(f=g\). If \(X=\varnothing\), there is only one function from \(X\) to \(Y\), and the conclusion still holds. \(\square\)
This statement is set-theoretic: it does not say that evaluation maps are continuous. Continuity of a map requires a topology on its domain and codomain, and the notation \(Y^X\) alone supplies no topology on \(Y^X\).
Worked Example: Functions on a Finite Discrete Domain
Let \(X=\{p,q\}\) have the discrete topology, whose open sets are all subsets of \(X\), and let \(Y=\mathbb{R}\) have its standard topology. A function \(f:X\to\mathbb{R}\) is determined by the pair \((f(p),f(q))\). For example, define \(f(p)=2\) and \(f(q)=-1\). Then \(\operatorname{ev}_p(f)=2\) and \(\operatorname{ev}_q(f)=-1\).
To check continuity, take any open set \(V\subseteq\mathbb{R}\). Its preimage \(f^{-1}(V)\) can only be one of \(\varnothing,\{p\},\{q\},\{p,q\}\), according to whether \(V\) contains neither, one, or both of the values \(2\) and \(-1\). Each of those subsets is open in the discrete topology on \(X\). Thus \(f\) is continuous. The same argument applies to every function \(X\to\mathbb{R}\), so \(C(X,\mathbb{R})=\mathbb{R}^X\).
Check: for \(V=(1,3)\), the value \(2\) lies in \(V\) and \(-1\) does not. Therefore \(f^{-1}(V)=\{p\}\), which is open in \(X\), as required.
Proof. Let \(f:X\to Y\) be any function, and let \(V\) be open in \(Y\). The preimage \(f^{-1}(V)\) is a subset of \(X\). Every subset of a discrete space is open, so \(f^{-1}(V)\) is open. This holds for every open \(V\), proving that \(f\) is continuous. Hence every element of \(Y^X\) belongs to \(C(X,Y)\); the reverse inclusion follows from the definition of \(C(X,Y)\). If \(X=\varnothing\), the unique empty function is continuous by the same preimage test. If \(Y=\varnothing\) and \(X\ne\varnothing\), both sets are empty because there are no functions \(X\to Y\). \(\square\)
Real-Valued Functions as Elements of \(Y^X\)
For real-valued functions, the notation often records the domain while leaving the functions themselves as the elements. For instance, \(C(\mathbb{R},\mathbb{R})\) is the set of continuous real-valued functions on the real line, where both copies of \(\mathbb{R}\) have the standard topology. In contrast, \(\mathbb{R}^{\mathbb{R}}\) includes every real-valued function on the real line, including discontinuous ones.
Worked Example: A Continuous Function and a Discontinuous One
Let \(X=Y=\mathbb{R}\) with their standard topologies. Define \(f(x)=x^2\). To verify continuity directly, fix \(a\in\mathbb{R}\) and \(\varepsilon>0\). Choose \(\delta=\min(1,\varepsilon/(2|a|+1))\), which is positive. If \(|x-a|<\delta\), then \(|x-a|<1\), so \(|x+a|\leq |x-a|+2|a|<2|a|+1\). Consequently, \[ |f(x)-f(a)|=|x^2-a^2|=|x-a||x+a|<\delta(2|a|+1)\leq\varepsilon. \] Thus \(f\) is continuous at every \(a\), and \(f\in C(\mathbb{R},\mathbb{R})\).
Now define \(g(x)=0\) when \(x<0\), and \(g(x)=1\) when \(x\geq 0\). Take the open set \(V=(1/2,3/2)\) in the codomain. The value \(g(x)\) belongs to \(V\) precisely when \(g(x)=1\), which occurs precisely when \(x\geq0\). Hence \(g^{-1}(V)=[0,\infty)\). This is not open in \(\mathbb{R}\): every open interval about \(0\) contains negative numbers, so no open neighborhood of \(0\) lies in \([0,\infty)\). Therefore \(g\) is not continuous and belongs to \(\mathbb{R}^{\mathbb{R}}\setminus C(\mathbb{R},\mathbb{R})\).
Check by evaluation: at \(x=2\), \(\operatorname{ev}_2(f)=f(2)=2^2=4\), while \(\operatorname{ev}_2(g)=g(2)=1\). The different evaluated values confirm that these are distinct elements of \(\mathbb{R}^{\mathbb{R}}\).
For a restricted domain, the notation records that the functions have a different set of allowed inputs. The interval \(I=[0,1]\) has the subspace topology inherited from the standard topology on \(\mathbb{R}\). Thus \(C(I,\mathbb{R})\) consists of functions defined only on \([0,1]\), with continuity tested using that subspace topology on the domain.
Worked Example: Evaluating a Function on the Unit Interval
Let \(X=I=[0,1]\) with its subspace topology and \(Y=\mathbb{R}\) with its standard topology. Define \(h(t)=3t^2-2t+1\). This polynomial is continuous on \(\mathbb{R}\), so its restriction to \(I\) is continuous; hence \(h\in C(I,\mathbb{R})\).
Evaluation at \(t=1/2\) gives \[ \operatorname{ev}_{1/2}(h)=h(1/2)=3(1/2)^2-2(1/2)+1 =\frac{3}{4}-1+1=\frac{3}{4}. \] For the function \(r(t)=t\), which is also continuous on \(I\), the same evaluation gives \(\operatorname{ev}_{1/2}(r)=r(1/2)=1/2\). The two functions are distinct because their values at \(1/2\) differ.
Check: substituting \(t=1/2\) into the defining expression for \(h\) yields \(3/4-1+1=3/4\), matching the evaluation. Also \(3/4\ne1/2\), so this one input suffices to distinguish \(h\) and \(r\).
Maps into a Function Set
There is a useful set-level way to understand why function sets are convenient. A map into \(Y^X\) assigns to each input \(z\) a whole function on \(X\). Equivalently, it assigns a value in \(Y\) to each pair \((z,x)\). This correspondence uses only sets and functions: the Cartesian product \(Z\times X\) here is the set of ordered pairs, and no topology on it or on \(Y^X\) is being asserted.
Proof. Given \(H:Z\times X\to Y\) and \(z\in Z\), the rule \(x\mapsto H(z,x)\) defines a function from \(X\) to \(Y\), so it is an element of \(Y^X\). Assigning this function to each \(z\) defines \(\widehat{H}:Z\to Y^X\). In the other direction, if \(G:Z\to Y^X\), then \(G(z)\) is a function \(X\to Y\) for every \(z\), so \(H_G(z,x)=G(z)(x)\) defines a function on \(Z\times X\). For every pair \((z,x)\), \(H_{\widehat{H}}(z,x)=\widehat{H}(z)(x)=H(z,x)\). For every \(z\), the functions \(\widehat{H_G}(z)\) and \(G(z)\) agree at every \(x\in X\), so they are equal; therefore \(\widehat{H_G}=G\). These identities show that the assignments are inverse, including when one of the sets is empty: equality of functions is tested at every element of the domain, and the relevant identities then hold vacuously where the domain is empty. \(\square\)
When \(Z\) and \(X\) are topological spaces, this correspondence remains valid as a statement about underlying sets and functions. It does not, by itself, say that continuity of \(H\) is equivalent to continuity of \(\widehat{H}\). Such a claim would require choosing a topology on \(Y^X\), and different choices can give different continuity behavior.
A Common Pitfall: Evaluation Is Not Automatically Continuous
It is tempting to say that \(\operatorname{ev}_x\) is continuous “by definition.” The definition only says how evaluation acts on a function; it does not specify a topology on its domain \(Y^X\). The issue can be checked in a small example.
Let \(X=\{*\}\) be a one-point space with its unique topology, let \(Y=\mathbb{R}\) have the standard topology, and identify each element of \(\mathbb{R}^X\) with its value at \(*\). Give the set \(\mathbb{R}^X\) the indiscrete topology \(\{\varnothing,\mathbb{R}^X\}\). The evaluation map \(\operatorname{ev}_*:\mathbb{R}^X\to\mathbb{R}\) sends the function with value \(u\) to \(u\). For the open set \(V=(0,1)\subseteq\mathbb{R}\), its preimage is the nonempty proper subset consisting of the functions whose value at \(*\) lies in \((0,1)\). That subset is not open in the indiscrete topology, so \(\operatorname{ev}_*\) is not continuous for this choice of domain topology.
By contrast, if the domain \(\mathbb{R}^X\) is given the discrete topology, every map from it to \(\mathbb{R}\) is continuous: the preimage of every open set is a subset of a discrete space, hence open. Thus the same set-theoretic evaluation map can be continuous or not, depending on the topology placed on its domain. The notation \(Y^X\) alone settles neither question.
The distinction matters whenever functions are treated as points in a new space. First specify which functions are present—\(Y^X\) or the subset \(C(X,Y)\)—and then specify a topology if questions about open sets, convergence, or continuity of evaluation are to be asked. The set of maps and the topology on that set are separate pieces of data.
Check Your Understanding
For each question, keep the underlying function set separate from any topology that might later be placed on it.
- If \(X=\{a,b\}\) is discrete and \(Y=\mathbb{R}\), describe an arbitrary element of \(Y^X\), and explain why every such function is continuous.
- For \(X=Y=\mathbb{R}\) with the standard topology, use an open-set preimage to show that \(g(x)=0\) for \(x<0\) and \(g(x)=1\) for \(x\geq0\) is not continuous.
- State what \(\operatorname{ev}_x(f)\) means and explain why an evaluation map is not defined when \(x\notin X\).
- When \(X=\varnothing\), how many functions are in \(Y^X\), and why is the unique such function continuous?
- Explain why the set-theoretic definition of \(Y^X\) does not determine whether \(\operatorname{ev}_x:Y^X\to Y\) is continuous.