Which functions satisfy $ g(x) d^n f(x)/dx^n = x^n/n!$ for all positive $n$? Are there any $f(x)$ and $g(x)$ real functions which satisfy $$ g(x) \frac{d^n}{dx^n} f(x)= \frac{x^n}{n!}$$ for all positive $n$? 
EDIT:
More generally, are there functions which satisfy $$ h(x)\left(g(x) \frac{d}{dx}\right)^n f(x)= \frac{x^n}{n!}$$ for all positive $n$? 
Here $$\left(g(x) \frac{d}{dx}\right)^n = g(x)\frac{d}{dx} \left\{ g(x) \frac{d}{dx} \left[g(x)\frac{d}{dx} \left( \dots f(x)\right)\right]\right\}$$
 A: Setting $n=1$ gives us $g(x)=x/f'(x)$.
Setting $n=2$ then gives $x\frac{f''(x)}{f'(x)}=\frac{x^2}2$ whose full solution for $f'$ is $f'(x)=ce^{x^2/4}$.
Now setting $n=3$ requires
$$ x\frac{f'''(x)}{f'(x)} = \frac{x^3}{6} $$
but actually
$$ x\frac{f'''(x)}{f'(x)} = x\frac{\frac12 ce^{x^2/4}+\frac14 c x^2e^{x^2/4}}{ce^{x^2/4}} = \frac12 x + \frac14 x^3 $$
which is not the $x^3/6$ demanded by your equation. Therefore there's no solution that satisfies the property for all $n$.

The edited question can be attacked in a similar way. Set $k(x)=f'(x)$. Divide the equation for $n=2$ with the equation for $n=1$ to eliminate $h$. This allows you to express $g$ as a function of $k$ and its derivative -- in fact $g(x)=\frac{xk(k)}{2k'(x)}$.
Then divide the $n=3$ case with the $n=2$ case, giving you an equation you can use to find $k$ up to a constant factor. Without checking carefully along the way, I get something like $k(x)=ce^{-x^2/3}$.
Next, divide the $n=4$ case by the $n=3$ case (again eliminating $h$) and insert this formula for $k$. See if it comes out right. I haven't bothered to do the algebra here, but I expect that it doesn't.
A: Not sure there is a solution. Here is my reasoning:
First consider $n=1$. We have $g f' = x$. Hence $g=\frac{x}{f'}$ 
Now consider $n=2$. Let $h=f'$. Then for $n=2$ we have
$$ \frac{x}{h} h' = \frac{x^2}{2}$$
Integrating
$$ \log(h) = \frac{x^2}{4} + C$$
or 
$$ h = C e^{x^2/4}$$.
Now consider n=3
$$
\frac{x}{h} \frac{d^2 h}{d x^2} = x^3/6
$$
However, if we substitute $h=C e^{x^2/4}$ the left hand side is $\frac{x^3+2x}{4}$
Hence no solution is possible that will hold for any positive $n$.
