A problem in functional calculus This is embarrassing, I think it must work, but I can't see how to prove it works. If anyone knows enough functional calculus of operators on a Hilbert space to tell me how to do it, I would be very grateful. Of course, you might also tell me that it is wrong...
Take positive bounded operators $x,y$, and increasing continuous functions $f,g:[0,\infty)\to [0,1]$ with the property that if $f(t)>0$ then $g(t)=1$. Then show that
$$
f(x)\,g(x+y)= g(x+y)\,f(x)=f(x)\ .
$$
Reason why I think it should work: If $f(t)>0$ then $g(t+\mathrm{positive})=1$, so it works... OK, this argument is not legal, but can the statement be proved in functional calculus?
Purpose: This is to be used to show that for a separable C* algebra there is an approximate identity $u_n$ with the property that $u_n u_{n+1}=u_{n+1}\ u_n=u_n$. Maybe someone actually looked at special approximate identities with this sort of property?

OK, the conjecture is false, as noted below. However there was a comment below about the property of approximate identities and whether this might still be true. After some thought I think that the problem is related to functional calculus of several commuting operators. Or rather to this modification: What happens to the functional calculus of several bounded operators which only almost commute, $f(T,S)$ where $\|[T,S]\|<\epsilon$? For an approximate identity we do have for fixed $n$, $\|[u_n,u_m]\|\to 0$ as $m\to\infty$, so it might still be possible to formulate the construction if a small commutator does not matter...
Yes, making this into a general note about functional calculus of two non-commuting operators is a but of an extrapolation.....

NOTE - I have just read the comment on the existence of these approximate identities below - this certainly solves my immediate problem. I now have to find a reference. Many thanks to all involved! I am still curious about the two non-commuting operators though.
 A: [EDITED 2015-07-23 to fix a small error pointed out in comments. EDITED 2015-11-07 to fix a mathematical typo.]
It seem that this can fail even when $x$ and $y$ are 2-by-2 matrices. We'll choose them such that $xy\neq yx$, choose $f$ such that $f(x)=x$ and $g$ such that $g(x+y)=x+y$.
Fix $a>0$ to be determined later. Let
$\newcommand{\twomat}[4]{\begin{bmatrix} #1 & #2 \cr #3 & #4 \end{bmatrix}}$
$$x_0= \twomat{2a}{0}{0}{0} \quad,\quad y_0=\twomat{1}{1}{1}{1} $$
which are both positive semi-definite.
Since $x_0+y_0$ is hermitian with trace $2a+2$ and determinant $2a$, it has eigenvalues
$$ r = (1+a)-\sqrt{1+a^2}\quad,\quad R= (1+a)+\sqrt{1+a^2} $$
both of which are strictly positive. Furthermore, one checks that $r< 2a<R$.
Now let $x=R^{-1}x_0$, $y=R^{-1}y_0$, so that $\sigma(x)=\{0, 2a/R\}$ and $\sigma(x+y)=\{r/R, 1\}$. Pick $t_0$ such that
$$ 0 < r/R < t_0 < 2a/R < 1. $$


*

*Define $f$ to take the value $0$ on the interval $[0,t_0]$ and $2a/R$ on the interval $[2a/R,\infty)$ with the obvious linear interpolation on the interval $[t_0,2a/R]$.

*Define $g(t)=t$ on the interval $[0,r/R]$ and $g(t)=1$ on the interval $[t_0,\infty)$ with the obvious linear interpolation on the interval $[r/R, t_0]$.
Then both $f$ and $g$ are continuous increasing functions $[0,\infty)\to [0,1]$ and by construction $fg=f$. Since
$f(t)=t$ for all $t\in \sigma(x)$ and $g(t)=t$ for all $t\in \sigma(x+y)$, we have
$$ f(x)g(x+y) = x(x+y) = R^{-2} x_0^2+x_0y_0 = \frac{1}{R^2} \twomat{8a^2+1}{2a}{0}{0} $$
$$ g(x+y)f(x) = (x+y)x = R^{-2} x_0^2 + y_0x_0 = \frac{1}{R^2} \twomat{8a^2+1}{0}{2a}{0} $$
$$ f(x) = x = R^{-1} \twomat{2a}{0}{0}{0} $$
so that none of the desired identities hold.
(PS if one desires an example with "nice" numbers then taking $a=3/4$ should give
$$ x = \twomat{1/2}{0}{0}{0}\quad,\quad y = \frac{1}{3}\twomat{1}{1}{1}{1}\quad,\quad x+y = \frac{1}{6} \twomat{5}{2}{2}{2} $$
with $\sigma(x)=\{0,1/2\}$ and $\sigma(x+y) = \{1/6, 1\}$.)
