Interesting functional equations problem? $f(x) + 3 f\left( \frac {x-1}{x} \right) = 7x$ 
Find all functions $f:\mathbb R \to \mathbb R$ that satisfy $f(x)  + 3 f\left( \frac {x-1}{x} \right) = 7x$.

How would we solve this? I noticed that if you plug in $\frac{x-1}{x}$ in for $x$, and then again, we can solve $f(x)$ after bashing it out with systems of equations. However, the resulting function has a few values for which it is undefined. I tried finding those values by going back to the original equation, but it doesn't seem like a "good" answer. Since I then wanted to verify that I had the correct function first, I plugged the actual function back into the original equation. However, the LHS and RHS didn't match up. Is there a better way to solve this other than just bashing?
Thanks in advance!
 A: I think this is essentially the solution you came up with, but it's helpful to write out all the details.
Let $y=\frac{x-1}{x}$, $z=\frac{1}{1-x}$. Then, if $g(x)=\frac{x-1}{x}$, we have $y=g(x)$, $z=g(y)$, and $x=g(z)$. So the functional equation implies that
\begin{align}
f(x) + 3f(y)&=7x\\
f(y) + 3f(z)&=7y\\
f(z) + 3f(x)&=7z
\end{align}
Then $f(y)=7y-3f(z)$ and $f(z)=7z-3f(x)$, so $f(y)=7y-3(7z-3f(x))=7y-21z+9f(x)$.
So $f(x)+21y-63z+27f(x)=7x$, meaning that 
\begin{align}
f(x)&=\frac{7x-21y+63z}{28} \\
&=\frac{x-3y+9z}{4}\\
&=\frac{1}{4}\left(x-3+\frac{3}{x}+\frac{9}{1-x}\right)
\end{align}
It's not too hard to check that this satisfies the original functional equation for all $x \neq 0,1$. (Actually, it's easier if you leave everything in terms of $x$, $y$, and $z$.)
What about the value of $f$ at $0$ and $1$? By setting $x=1$ in the original equation, we can see that:
$$
f(1)+3f(0)=7 \tag{1}
$$
Because $\frac{x-1}{x}$ is never equal to $1$ and undefined at $x=0$, this is the only meaningful data the equation gives us about $f(0)$ and $f(1)$, so you can pick any values for them you wanted that satisfy $(1)$. There doesn't seem to be any choice that's much nicer than the others, since $f$ has simple poles at both $0$ and $1$ (e.g., we can never make $f$ continuous).
A: Sorry, this wouldn't fit into a comment, so I had to post this in as an answer, but when I plugged $f$ back into the original equation, I got:
\begin{align*}
f(x) + 3 f\left(\frac{x-1}{x}\right) &= \frac{1}{28}\left(x - 3 - \frac{3}{x} - \frac{9}{x-1}\right) + 3\left(\frac{1}{28}\right)\left(\frac{x-1}{x} - 3 - \frac{3}{\frac{x-1}{x}} - \frac{9}{\frac{x-1}{x}-1}\right)\\
&= \left(\frac{1}{28}\right)\left(x - 3 - \frac{3}{x}-\frac{9}{x-1}+3\left(\frac{x-1}{x}-3-\frac{3x}{x-1}+9x\right)\right)\\
&= \left(\frac{1}{28}\right)\left(x - 3 - \frac{3}{x}-\frac{9}{x-1}+\frac{3x-3}{x} - 3 - \frac{9x}{x-1} + 27x\right)\\
&= \left(\frac{1}{28}\right)\left(28x - 6 + \frac{3x-6}{x}-\frac{9+9x}{x-1}\right)\\
&= \left(\frac{1}{28}\right)\left(28x^3-28x^2-6x^2+6x-3x^2+6x+3x+6-9x+9x^2\right)\\
&= \left(\frac{1}{28}\right)\left(28x^3-28x^2+6x+6\right)\\
&= x^3-x^2+\frac{3x}{14} + \frac{3}{14},
\end{align*}
which doesn't match the given $7x$. If you could tell me where I made my mistake, it would be greatly appreciated. Thanks in advance!
