is it possible for a function $f(x,y)$ satisfying $\nabla f=y\mathbf{i}-x\mathbf{j}$ ?
Since $\frac{\partial^2 f}{\partial x\partial y}=-1$ and $\frac{\partial^2 f}{\partial y\partial x}=1$, thus $f$ should be singular.
I find a similar answer in wikipedia "Symmetry of second derivatives",
$f(x,y)=\frac{xy(x^2-y^2)}{x^2+y^2}$ for $(x,y)\ne(0,0)$ and $f(x,y)=0$ for $(x,y)=(0,0)$, however, this function just satisfies at $(x,y)=(0,0)$.
Does anybody know a function satisfies the condition in the whole variables domain?
You're requiring:
$f_x=y$ and $f_y=-x$
This requires
$f=xy+A(y)$ and $f=-xy+B(x)$
which implies $2xy=B(x)-A(y)$. Try and show this is impossible (remember, no y can appear in B and no x can appear in y). Try and consider some arbitrary function of
xwhile holding y constant, then changing the constant.Now no one says $f$ has to be twice continuously differentiable, so the symmetry of the second derivative doesn't have to hold, but the above already rules a function like this out.