Using Symbolic Logic to keep track of domain and codomain I'm working on Spivak's Calculus, and trying to throw Symbolic Logic at it to make its exercises a little more formal. Chapter 3, Problem 1 VII is:

Let $f(x) = \frac{1}{1+x}$. For which numbers is $c$ is it true that $f(cx) = f(x)$ for two different numbers $x$?

For my own edification, I'm going to be as explicit as possible about the domains:
$$
\begin{array} { a b }
f: x &\mapsto \frac{1}{1+x} & f: \mathbb{R} \setminus \left\{-1\right\} &\to \mathbb{R} \setminus\left\{ 0 \right\} \\
g: \left\{c,x\right\} &\mapsto \frac{1}{cx} & g : \left\{ c \in \mathbb{R} \ \middle|\ c \neq 0 \right\} \cup \left\{ x \in \mathbb{R} \middle|\ x \neq 0 \right\} &\to \mathbb{R} \setminus \left\{ 0 \right\}
\end{array}
$$
Now, we have something like a base case for finding numbers $c$ where $f(cx) = f(x)$ is true for two different numbers $x$.
Next, starting with the proposition that we are to assume is true and working backwards, we have:
$$
\begin{array} {a b }
g(cx) = f(x) & f \cup g : \mathbb{R} \setminus \left\{ -1 \right\} \cup \left\{ c \in \mathbb{R}\ \middle|\ c \neq 0 \right\} \cup \left\{ x \in \mathbb{R}\ \middle|\ x \neq 0\ \right\} \\
x = cx & f \cup g : \mathbb{R} \setminus \left\{ -1 \right\} \cup \left\{ c \in \mathbb{R}\ \middle|\ c \neq 0 \right\} \cup \left\{ x \in \mathbb{R}\ \middle|\ x \neq 0\ \right\} \\
1 = c & f \cup g : \mathbb{R} \setminus \left\{ -1 \right\} \cup \left\{ c \in \mathbb{R}\ \middle|\ c \neq 0 \right\} \cup \left\{ x \in \mathbb{R}\ \middle|\ x \neq 0\ \right\} \\
\end{array}$$
Is there anything in the above notation that is glaringly wrong?
 A: Interesting approach! 


*

*I think you want to define $g$ slightly differently. If $g(c,x)$ is supposed to be equal to $f(c\cdot x)$, then you'll want


$$g(c,x) = \frac{1}{1+cx}$$
rather than $g(c,x) = 1/(c\cdot x)$.


*Relatedly, there is a bug in the domain of $g$. Since $g$ takes two arguments, its domain must be pairs of numbers. So, you want to use the $\times$ operator rather than the $\cup$ operator:


Formally, $\{x\in \mathbb{R} \,|\, x \neq 0\}\cup \{c \in \mathbb{R}\,|\, c \neq 0\}$ is just the set $(\mathbb{R}\backslash \{0\}) \cup (\mathbb{R}\backslash \{0\}) = (\mathbb{R}\backslash \{0\})$.
Instead, you want something like the set $\{x \in \mathbb{R} \,|\, x \neq 0\} \times \{c \in \mathbb{R} \,|\, c \neq 0\}$. Finally, with the new proposed definition of $g$ above, the condition on the domain is actually $c\cdot x \neq -1$. One way to write it more formally is:
$$\{\langle c, x\rangle \in \mathbb{R}\times \mathbb{R} \,|\, cx\neq -1\}$$
A: In the second domain, g:{c∈ℝ ∣∣ c≠0}∪{x∈ℝ∣∣ x≠0}, that should be a cross product ×, not a union.
For instance, if the space of values for c was {1, 2, 3}, and the space of values for x was {1, 5, 9}, the union would get you {1, 2, 3, 5, 9}. What you want is all the pairs: {(1, 1), (1, 5), (1, 9), (2, 1), (2, 5), (2, 9), (3, 1), (3, 5), (3, 9)}.
The next section is very strange to express in terms of domains. There's a set of c and x pairs that satisfy the relation, but it's not strictly speaking a domain, unless you phrase the relation as a function R from c,x pairs to {True, False}. In that case though, right now you have x listed twice in the domain, as though the two x's are independent; you would have to clean up the domain to be a cross product with the x having two conditions.
So you could have something like this:
R: {c∈ℝ ∣∣ c≠0}×{x∈ℝ ∣∣ x≠0, x≠-1}   →   {True, False}
Personally I wouldn't phrase the second collection of equations in function terms. Can't remember how it's done in symbolic logic though.
