# Function declaration for set-valued functions

Let $g$ be the square function:

$$g : \mathbb{R} \rightarrow \mathbb{R}$$ $$g(x) = x^2$$

Let $f$ be a function which takes a real-valued function of one real variable (such as $g$ as input), and returns a set of that functions fixed points. For example,

$$f(g) = \{0,1\}.$$

My questions are:

1. Is this a well-defined function?
2. Is this a set-valued function?
3. How would we declare its domain and co-domain?

If I were to write this in Haskell, whose notation often mimics that used in mathematics, I would write something like

f :: Float a => (a -> a) -> [a]


That is, it's a function that takes as input a function (a -> a), which itself takes a float and returns a float, and returns a list of floats. However, I don't recall seeing a similar notation in mathematics.

• Mathematically, the set of all functions from $\mathbb R$ to $\mathbb R$ is denoted with: $\mathbb R ^ {\mathbb R}$. Thus : $f : \mathbb R ^ {\mathbb R} \to \{ 0,1 \}$. – Mauro ALLEGRANZA Sep 5 '17 at 14:26

Yes, for example by writing $$f: \mathbb R^{\mathbb R} \to \mathcal P(\mathbb R)\\ f(g) = \{x \in \mathbb R \mid g(x) = x\}$$ (This also answers 3.) The set $\mathbb R^{\mathbb R}$ is the set of functions $\mathbb R \to \mathbb R$. The set $\mathcal P(\mathbb R)$ is the power set of $\mathbb R$, i.e. the set of all subsets of $\mathbb R$.
Your Haskell notation is an appropriate analogue, but note that [a] is not exactly the same as the power set (since you can have repeated elements, and order matters), and note that it's not possible to compute the fixed points of a general function.