# Finding potential function of a vector field

I have this question and I don't know the answer.

Suppose $U \subset \mathbb{R}^3$ is a convex open set and $\textbf{F} : U\to \mathbb{R}^3$ is a smooth vector field. Show that if $\nabla \times {F}=0$, then $\textbf{F} =\nabla u$ for some smooth function $u: U\to \mathbb{R}$. $F=(F_1,F_2,F_3)$.

The model answer to this question is letting $$u(x,y,z) = \int_{x_0}^x F_1(t,y_0,z_0) dt+\int_{y_0}^y F_2(x_0,y,z_0) dt+\int_{z_0}^z F_3(x_0,y_0,z) dt$$ However, I think it is wrong since $u_x=F_1(x,y_0,z_0)$ instead of $F_1(x,y,z)$.

I tried letting $$u(x,y,z) = \int_{x_0}^x F_1(t,y_0,z_0) dt+\int_{y_0}^y F_2(x,t,z_0) dt+\int_{z_0}^z F_3(x,y,t) dt$$ This is taught by my teacher, to evaluate potential function with a line integral goes to $(x,y,z)$. However, I could figure out how will $u_x=F_1(x,y,z)$.

• @AmitaiYuval yes, I have corrected it – k99731 Nov 30 '14 at 7:41
• In the "model" answer it should read $$u(x,y,z) = \int_{x_0}^x F_1(t,y_0,z_0) dt+\int_{y_0}^y F_2(x,t,z_0) dt+\int_{z_0}^z F_3(x,y,t) dt.$$ In other words the 2nd and the 3rd integrals should have $x$ (and the third also $y$) in place of the coordinates of the starting point $(x_0,y_0,z_0)$. My answer is using that. – Jyrki Lahtonen Nov 30 '14 at 7:57

Your mistake (or that of the model answer, see my comment) is that when differentiating $u(x,y,z)$ w.r.t. $x$ you forgot to take into account the $x$-dependency of $u$ coming from the fact that the second and the third terms have $x$ in the integrand. You can "differentiate inside the integral" when the vector field is smooth enough ($C^1$ should suffice). Those terms will fix the partial derivative.
Another way of seeing this is the following. In a convex open set the path integral of a curl-less vector field is path independent. Therefore \begin{aligned} u(x,y,z) &= \int_{0}^x F_1(t,0,0)\, dt+\int_{0}^y F_2(x,t,0)\, dt+\int_{0}^z F_3(x,y,z)\, dt\\ &=\int_{0}^z F_3(0,0,t)\, dt+\int_{0}^y F_2(0,t,z)\, dt+\int_{0}^x F_1(t,y,z)\, dt, \end{aligned} which may make the end result easier to see.
• therefore we have $u_x = F_1(x,y,z)=F_1(x,0,0)+\int_0^y \frac{\partial}{\partial x}F_2(x,t,0)dt+\int_0^z \frac{\partial}{\partial x}F_3(x,y,t)dt$? – k99731 Nov 30 '14 at 8:11
• Yes. But because $\nabla\times F=0$ you have $\partial F_2/\partial x=\partial F_1/\partial y$ and $\partial F_3/\partial x=\partial F_1/\partial z$. – Jyrki Lahtonen Nov 30 '14 at 8:18