I have a big problem to solve this system:


$\Delta f−hf^2=0$


$p|\nabla f|^2+hf^3=0$


where $h$ and $p$ are constants (with $h \neq 0$ and $p \neq 0$, $p \neq -1$), $f$ is a scalar function defined on a 4-manifold ($f:M \rightarrow \mathbb{R}$) where $M$ is a 4-manifold not compact and where $\Delta f$ is the Laplacian of $f$ (trace of Hessian of $f$, with positive sign, not negative), and $\nabla f$ is the gradient of $f$ for the metric $g$ (where $g$ is the metric of 
$M$).


Should I find $f$ and $g$ excluding cases of flat metric $g$.


1) Are there solutions?


2) Can the metric $g$ admit a scalar curvature ($S$) equal to $-p(p+1)x$, i.e., $S=-p(p+1)x$, for some negative constant $p$ ?



Metric and particular system of PDE
As in my previous solution in the 3-dimensional case (discussed [here](https://mathoverflow.net/questions/334414/pde-system-problem-to-find-the-metric)), we can set $f=-(p/h)x$ for a function $x$ that satisfies
$$
\Delta x + p\,x^2 = |\nabla x|^2 - x^3 = 0.\tag 1
$$ 
Conversely, if $x$ satisfies this system for a metric $g$, then $f = -(p/h)x$ will satisfy the original equations.


Again, the same argument as before shows that the $1$-form $\omega\_1 = x^{-3/2}\, \mathrm{d}x$ is a $1$-form of $g$-norm equal to 1, so one can write $g$ locally in the form
$$
g = {\omega\_1}^2 + {\omega\_2}^2 + \cdots + {\omega\_n}^2. 
$$
Again, fixing the orientation so that $\omega\_1\wedge\cdots\wedge\omega\_n$ is the oriented volume form, we have $\ast\_g\omega\_1 = \omega\_2\wedge\cdots\wedge\omega\_n$, and the definition of the Laplacian gives us $\mathrm{d}(\ast\_g\mathrm{d}x) = -\Delta x\,\,{\ast\_g}1$. Just as before, we now compute, using $\mathrm{d}x = x^{3/2}\,\omega\_1$ that
$$
\mathrm{d}(x^{3/2-p}\,\omega\_2\wedge\cdots\wedge\omega\_n) = 0,
$$
and hence, locally, one can write
$$
x^{3/2-p}\,\omega\_2\wedge\cdots\wedge\omega\_n = \mathrm{d}y^2\wedge\cdots\wedge\mathrm{d}y^n\tag2
$$
for some functions $y^2,\ldots,y^n$ that, with $x$, gives a local coordinate system. Moreover, (2) implies that 
$$
{\omega\_2}^2 + \cdots + {\omega\_n}^2 = x^{(2p-3)/(n-1)}\,g\_{ij}(x,y)\,\mathrm{d}y^i\mathrm{d}y^j,
$$
for some function $g\_{ij}$ satisfying $\det(g\_{ij}) = 1$. 


Conversely, given functions $g\_{ij}$ on a domain in $\mathbb{R}^n$ so that $(g\_{ij})>0$ and $\det(g\_{ij}) = 1$, we have that the metric
$$
g = x^{-3}\,(\mathrm{d}x)^2 + x^{(2p-3)/(n-1)}\,\bigl(g\_{ij}(x,y)\,\mathrm{d}y^i\mathrm{d}y^j\bigr)
$$
and the function $x$ satisfy the equation (1).


Finally, the equation $S =-p(p+1) f$ is a second order PDE for the functions $g\_{ij}$, and the existence of solutions should be fairly straightforward as long as $n>2$. It's not clear that it's worth writing out the details.


