Poincare's lemma for 1-form Let $\omega=f(x,y,z)dx+g(x,y,z)dy+h(x,y,z)dz$ be a differentiable 1-form in $\mathbb{R}^{3}$ such that $d\omega=0$. Define $\hat{f}:\mathbb{R}^{3}\to\mathbb{R}$ by 
$$\hat{f}(x,y,z)=\int_{0}^{1}{(f(tx,ty,tz)x+g(tx,ty,tz)y+h(tx,ty,tz)z)dt}.$$ 
Show that $d\hat{f}=\omega$.
My approach: If $d\omega=0$, then 
$$\left(\dfrac{\partial g}{\partial x}-\dfrac{\partial f}{\partial y}\right)dx\wedge dy+\left(\dfrac{\partial h}{\partial x}-\dfrac{\partial f}{\partial z}\right)dx\wedge dz+\left(\dfrac{\partial h}{\partial y}-\dfrac{\partial g}{\partial z}\right)dy\wedge dz=0,$$
therefore $\dfrac{\partial g}{\partial x}=\dfrac{\partial f}{\partial y}, \dfrac{\partial h}{\partial x}=\dfrac{\partial f}{\partial z},\dfrac{\partial h}{\partial y}=\dfrac{\partial g}{\partial z}$.
For the other hand, note that 
$$f(x,y,z)=\int_{0}^{1}{\dfrac{d}{dt}(f(tx,ty,tz)t)dt}=\int_{0}^{1}{f(tx,ty,tz)dt}+\int_{0}^{1}{t\dfrac{d}{dt}(f(tx,ty,tz))dt}$$
where 
$$\dfrac{d}{dt}(f(tx,ty,tz))=x\dfrac{df}{dx}(tx,ty,tz)+y\dfrac{df}{dy}(tx,ty,tz)+z\dfrac{df}{dz}(tx,ty,tz).$$
But now, I have trouble with the differential of $\hat{f}$. Then for the above equations I think we can prove $d\hat{f}=\omega$. 
 A: Note that $$d\hat{f} = \frac{\partial\hat{f}}{\partial x}dx + \frac{\partial\hat{f}}{\partial y}dy + \frac{\partial\hat{f}}{\partial z}dz.$$
First we have
\begin{align*}
\frac{\partial\hat{f}}{\partial x} &= \frac{\partial}{\partial x}\int_{0}^{1}(f(tx,ty,tz)x+g(tx,ty,tz)y+h(tx,ty,tz)z)dt\\
&= \int_{0}^{1}\frac{\partial}{\partial x}(f(tx,ty,tz)x+g(tx,ty,tz)y+h(tx,ty,tz)z)dt\\
&= \int_0^1\left(\frac{\partial f}{\partial x}(tx, ty, tz)tx + f(tx, ty, tz) + \frac{\partial g}{\partial x}(tx, ty, tz)ty + \frac{\partial h}{\partial x}(tx, ty, tz)tz\right)dt\\
&= \int_0^1\left(\frac{\partial f}{\partial x}(tx, ty, tz)tx + f(tx, ty, tz) + \frac{\partial f}{\partial y}(tx, ty, tz)ty + \frac{\partial f}{\partial z}(tx, ty, tz)tz\right)dt\\
&= \int_0^1\left(f(tx, ty, tz) + t\left(\frac{\partial f}{\partial x}(tx, ty, tz)x + \frac{\partial f}{\partial y}(tx, ty, tz)y + \frac{\partial f}{\partial z}(tx, ty, tz)z\right)\right)dt\\
&= \int_0^1\left(f(tx, ty, tz) + t\frac{d}{dt}(f(tx, ty, tz))\right)dt\\
&= \int_0^1\frac{d}{dt}\left(f(tx, ty, tz)t\right)dt\\
&= [f(tx, ty, tz)t]_0^1\\
&= f(x, y, z).
\end{align*}
A similar calculation shows $\dfrac{\partial\hat{f}}{\partial y} = g$ and $\dfrac{\partial\hat{f}}{\partial z} = h$, so $d\hat{f} = \omega$.
