# How to evaluate the line integral (checking Stokes Theorem)

Consider the vector field:

$$\vec F = ye^x \hat i + (x^2 + e^x) \hat j + z^2e^z \hat k$$

A closed curve $$C$$ lies in the plane $$x + y + z = 3$$, oriented counterclockwise. The parametric representation of this curve is defined as:

$$C = (1+\ cost) \hat i + (1+\ sint) \hat j + (1 - \ cost - \ sint) \hat k$$

Where $$t\in [0, 2\pi]$$.

Let's check Stokes' Theorem:

$$\int_{a} (\vec \nabla \times \vec F) \cdot d \vec a = \oint_{C} \vec F \cdot d \vec l$$

$$\vec \nabla \times \vec F = 2x \hat k$$

The projection of the curve $$C$$ on the $$xy$$ plane is the circle with radius $$1$$ and center $$(1, 1)$$. Then:

$$d \vec a = \hat k dxdy$$

$$\int_{a} (\vec \nabla \times \vec F) \cdot d \vec a = \int_{a} 2x dxdy = 2\int_{0}^{2\pi}\int_{0}^{1} r^2cos \theta drd \theta = 0$$

OK, so now we know:

$$\int_{a} (\vec \nabla \times \vec F) \cdot d \vec a = \oint_{C} \vec F \cdot d \vec l = 0$$

It's time to check the RHS:

We gotta evaluate the following line integral:

$$\oint_{C} \vec F \cdot d \vec l = \oint_{C}[ye^x dx + (x^2 + e^x)dy + z^2e^z dz]$$

Where:

$$x = 1 + \ cost$$

$$y = 1 + \ sint$$

$$z = 1 - \ cost - \ sint$$

Then we get:

$$\oint_{C} \vec F \cdot d \vec l = C_1 + C_2 + C_3$$

Where:

$$C_1 = \int_{0}^{2\pi} (1+\ sint) e^{1+\ cost}(-\ sint)dt$$

$$C_2 = \int_{0}^{2\pi} [(1+\ cost)^2 + e^{1+\ cost}](\ cost)dt$$

$$C_3 = \int_{0}^{2\pi} (1-\ cost-\ sint)^2e^{1-\ cost-\ sint}(\ sint-\ cost)dt$$

But how can we evaluate these integrals?

I tried to use an Integral Solver but did not find primitives for them... If they have no exact solution, is there a numerical method to evaluate them? We at least know (if I did not get wrong evaluating the LHS) that:

$$\oint_{C} \vec F \cdot d \vec l = C_1 + C_2 + C_3 = 0$$

• $C_3=0$ because if you make the substitution $u=\sin{t}+\cos{t}$ you get an integral of the form $\int_1^1 F(u)du$ Don't see how to handle $C_1$ and $C_2$ though. BTW, your posts will look better if you write \sin and \cos. – saulspatz Apr 19 at 16:27
• Let $E$ be region in the plane $x + y + z = 3$ enclosed by $C$. Then $d\mathbf a = (1, 1, 1) dx dy$ (not $\mathbf k \, dx dy$), and $(x, y) = (1 + \rho \cos t, 1 + \rho \sin t)$ gives $$\int_E (\nabla \times \mathbf F) \cdot d\mathbf a = 2 \pi.$$ This integral happens to be elementary: $$\int e^{\cos t} (\cos t - (1 + \sin t) \sin t) \, dt = e^{\cos t} (1 + \sin t),$$ so the line integral reduces to $\int_0^{2 \pi} (1 + \cos t)^2 \cos t \, dt$. – Maxim May 4 at 18:29
• @Maxim Thanks for your comment. Note that $da$ is a vector and thus must have direction. When you state $d\mathbf a = (1, 1, 1) dx dy$ I think you're lacking of direction $k$ – JD_PM May 4 at 21:15
• $(1, 1, 1) = \mathbf i + \mathbf j + \mathbf k$, just in a different notation. – Maxim May 4 at 21:55
• But the piece of area $dxdy$ has a perpendicular direction (either $k$ or $-k$). I do not see why you include $i$ and $j$ – JD_PM May 4 at 22:08