Are these two functions identical? Suppose $f,g$ are functions on $\mathbb{R} \rightarrow \mathbb{R}$ satisfying the following property:
For all points $x \in \mathbb{R}$, and for all $ h > 0$, the neighborhood $(x-h,x+h)$ contains points $c_{1},c_{2}$ such that $|f(c_{1})-g(c_{2})|< h$.
Is it true that $f = g$ everywhere on $\mathbb{R}$? If so, why? If not, counterexample?
This question is motivated by the technique used by my textbook to prove the symmetry of second derivatives for twice differentiable maps on $R^{n}$. The answer to this question would provide much insight on the technique.
 A: If you assume that $f,g$ are both continuous, then yes: they must coincide. A proof follows:
fix any $x \in \Bbb{R}$. Since $f,g$ are continuous at $x$, both the limits $\lim_{t \to x} f(t)=f(x)$ and $\lim_{t \to x} g(t)=g(x)$ exist. Your condition implies that these two limits coincide; in fact it is sufficient to show that for all $\varepsilon > 0$
$$|f(x)-g(x)| < 3 \varepsilon$$
In order to show this, pick some $c_1,c_2$ such that $|f(c_1)-g(c_2)| < \varepsilon$ and use
$$|f(x)-g(x)| \le |f(x)-f(c_1)|+|f((c_1)-g(c_2)|+|g(c_2)-g(c_2)| < 3 \varepsilon$$
A: The contrapositive of this says that if $f \neq g$, then there is $x\in \mathbb R$, and an $h > 0$ so that $(x-h, x+h)$ contains a pair of points $c_1, c_2$ so that $|f(c_1) - g(c_2)| > h$. Since we are not requiring these points to be different, we'll just take them to be the same - I can only imagine that you can choose nearby points and do essentially the same as what follows if they must be different.
Suppose $f,g$ to be continuous, their coincidence set is closed, so the set on which they disagree is open. Every open set in $\mathbb R$ is an at most countalbe collection of open intervals, so choose one of those and work in that set. Now choose a point from this interval, and compute the difference there of $f$ and $g$. Then take $h$ to be sufficiently small, like say, half the difference. Since the points are the same, they obviously lie in the interval, but their difference is larger than the chosen value for $h$.
