# Antiderivative of function composed with gradient of another function

Let's say I have a differentiable function $$F: \mathbb{R}^n \to \mathbb{R}$$ with Lipschitz continuous gradient $$\nabla F$$. Then I take a function $$\phi:\mathbb{R} \to \mathbb{R}$$, and consider the vector where $$\phi$$ has been applied to each of the components of $$\nabla F$$, i.e., $$\left( \phi \left(\frac{\partial F(x)}{\partial x_1} \right), \dots, \phi \left(\frac{\partial F(x)}{\partial x_n} \right) \right).$$ Are there any requirements (except trivial like $$\phi$$ being linear) that I can put on $$\phi$$ for there to exist a function $$F_{\phi}: \mathbb{R}^n \to \mathbb{R}$$ such that the partial derivatives of $$F_{\phi}$$ are given by $$\frac{\partial F_{\phi}(x)}{\partial x_n} = \phi \left(\frac{\partial F(x)}{\partial x_n} \right) ?$$

This is an interesting question. Unfortunately, I think the answer is "no". In the one dimensional case, any $$\phi$$ which has an integral should work. You mention that $$\nabla F$$ is Lipschitz continuous. This means that at least the weak second derivatives exist. In particular this means that

$$\frac{\partial^2 F_\phi(\mathbf{x})}{\partial x_1 \partial x_2} = \phi'\left(\frac{\partial F(\mathbf{x})}{\partial x_1}\right) \frac{\partial^2 F(\mathbf{x})}{\partial x_1 \partial x_2} = \phi'\left(\frac{\partial F(\mathbf{x})}{\partial x_2}\right) \frac{\partial^2 F(\mathbf{x})}{\partial x_2 \partial x_1}$$

Now, in particular if $$F$$ and $$F_\phi$$ are well behaved such that we can interchange mixed partials, then unless we wish to say each mixed partial of $$F$$ is identically zero, we must have

$$\phi'\left(\frac{\partial F(\mathbf{x})}{\partial x_1}\right) = \phi'\left(\frac{\partial F(\mathbf{x})}{\partial x_2}\right) = ... = \phi'\left(\frac{\partial F(\mathbf{x})}{\partial x_n}\right)$$

From here it seems pretty clear that at least sometimes $$\phi'$$ must be constant, and $$\phi$$ linear, at least on the union of the ranges of the partial derivatives. For example take the $$2D$$ example

$$F(x,y) = x^2y$$

Now we have

$$\phi'\left(2xy\right) = \phi'\left(x^2\right)$$

If we take $$y=0$$ we immediately get that $$\phi(s) = \phi(0)$$ for any positive $$s$$. But then since $$x^2$$ is nonnegative, $$\phi'(2xy) = \phi'(x^2) = \phi'(0)$$. Thus $$\phi$$ is linear.