Apply Green's theorem for $\iint_D (x+2y)dxdy$ on region bounded with $x = t- \sin (t), y = 1 - \cos (t)$. Basically, I am stuck with his exercise. It asks to compute the integral: 

$$\int_C P\,dx + Q\,dy =  \iint_D \left(\frac{\partial Q}{\partial x} - \frac{\partial P}{\partial y}\right)dxdy = \iint_D (x+2y)dxdy $$
  where D is the region bounded by the x axis and the arc of $$ x = t- \sin (t),\;\;\; y = 1 - \cos (t),\;\; 0 \leq t \leq 2\pi $$

I have tried calculating F by knowing its 2D curl, but I never get the right solution: $$ -2\pi(3\pi+2) $$
Can you please tell me how to solve this problem?
 A: The idea behind Green's Theorem is that the curl of a vector field is a measure of the infinitisimal circulation ("swirl") caused by the vector field at a point. So Green's theorem states that, if we want the circulation along a closed path, we can take the area integral of all the "swirl" inside the curve, which all in a sense cancels out, leaving only the circulation on the boundary.


The curl for a vector field $\vec{F} = \langle F_x, F_y, F_Z \rangle$ is defined as:
$$ \nabla \times \vec{F} = \begin{vmatrix} \vec{i} & \vec{j} & \vec{k} \\ \frac{\partial}{\partial x} & \frac{\partial}{\partial y} & \frac{\partial}{\partial z} \\ F_x & F_y & F_z \end{vmatrix} $$
its direction gives the axis of rotation of the infinitisimal circulation (oriented by the right-hard rule), and its magnitude is the infinitisimal circulation.
Green's Theorem is the application of this to a 2D case where we take $F_z = 0$, working with a vector field in the $x$-$y$ plane. In this case, the curl points in the $\vec{k}$ direction and we simply use the scalar curl, the magnitude of the curl:
$$ \nabla \times \vec{F} = \frac{\partial F_y}{\partial x} - \frac{\partial F_x}{\partial y} $$
In this problem, you have the area integral
$$ \iint_{D} (x + 2y)\, dA $$
where $D$ is the region enclosed by the plane curve mentioned and the x-axis.
In order to use Green's theorem, we need a vector field whose curl is $x + 2y$.
One such vector field is
$$ \vec{F}(x,y) = \left\langle -y^2 ,\frac{x^2}{2} \right\rangle $$
and so take the the line integral:
$$ \int_{\partial D} \vec{F}(\vec{x}) \cdot d\vec{s}$$
where $\partial D$ is the oriented boundary of the region $D$. It is important to note that it is oriented:

we must traverse the boundary in a counterclockwise direction, and the parametrization given is (1) only the arc, not the flat line, and (2) clockwise starting from the origin to the right. So we parametrize the lower line as:
$$ \vec{x}_1(t) = \langle t,0 \rangle \qquad t \text{ from } 0 \text{ to } 2\pi $$
and the curve as
$$ \vec{x}_2(t) = \langle t-\sin t,1 - \cos t \rangle \qquad t \text{ from } 2\pi \text{ to } 0 $$
so we have:
\begin{align*}
\iint_{D} (x + 2y)\, dA &= \int_{\partial D} \vec{F}(\vec{x}) \cdot d\vec{s} \\
&= \int_0^{2\pi} \vec{F}(\vec{x}_1(t)) \cdot \vec{x}_1'(t) dt + \int_{2\pi}^0 \vec{F}(\vec{x}_2(t)) \cdot \vec{x}_2'(t) dt \\
&= \int_0^{2\pi} \langle 0, t^2/2 \rangle \cdot \langle 1,0 \rangle \, dt - \int_0^{2\pi} \langle -(1-\cos t)^2, (t-\sin t)^2/2 \rangle \cdot \langle 1 - \cos t, \sin t \rangle \, dt \\
&= \int_0^{2\pi} 0 \, dt - \int_0^{2\pi} \left[\sin t (t- \sin t)^2/2 -(1-\cos t)^3 \right] dt \\
&= \int_0^{2\pi} \left[(1-\cos t)^3 - \sin t (t- \sin t)^2/2 \right] dt \\
&= \pi(3\pi + 5) \\
\end{align*}
A: It’s a bit tedious, but not too hard, to compute the double integral directly, but if you’re interested in recovering $F$, you can use a technique for finding antiderivatives of differential forms that are defined in star-shaped regions relative to the origin.  
The integrand is equivalent to the 2-form $x+2y\,dx\wedge dy$. To find an antiderivative: 


*

*Make the substitutions $x\to tx$, $dx\to(x\,dt+t\,dx)$ and similarly for $y$: $$(tx+2ty)\,(x\,dt+t\,dx)\wedge(y\,dt+t\,dy)$$

*Expand, moving $dt$ to the left and discarding any terms that don’t involve it: $$(tx+2ty)(tx\,dt\wedge dy-ty\,dt\wedge dx)$$

*Integrate over $t$ from $0$ to $1$, treating the integrand as an ordinary function of $t$: $$\int_0^1(tx+2ty)(tx\,dy-ty\,dx)\,dt=-{xy+2y^2\over3}dx+{x^2+2xy\over3}dy$$  


In short, integrate $\left(-f(tx,ty)ty,f(tx,ty)tx\right)$, where $f(x,y)$ is the integrand in the double integral.
So, one possible vector field that has the given curl is $$F(x,y)=\left(\frac13(xy+2y^2),\frac13(x^2+2xy)\right).$$  
As with integration of single-variable functions, you can add a “constant” of integration, which here is any vector field with vanishing curl. For example, adding $\left(\frac13(xy-y^2),\frac16(x^2-4xy)\right)$ to this gives the vector field in Manuel Guillen’s answer.
