# Proof that $\int_0^{2\pi}\sin nx\,dx=\int_0^{2\pi}\cos nx\,dx=0$

Prove that $\int_0^{2\pi}\sin nx\,dx=\int_0^{2\pi}\cos nx\,dx=0$ for all integers $n \neq 0$.

I think I'm encouraged to prove this by induction (but a simpler method would probably work, too). Here's what I've attempted: $$\text{1.}\int_0^{2\pi}\sin x\,dx=\int_0^{2\pi}\cos x\,dx=0.\;\checkmark\\\text{2. Assume}\int_0^{2\pi}\sin nx\,dx=\int_0^{2\pi}\cos nx\,dx=0.\;\checkmark\\\text{3. Prove}\int_0^{2\pi}\sin (nx+x)\,dx=\int_0^{2\pi}\cos (nx+x)\,dx=0.\\\text{[From here, I'm lost. I've tried applying a trig identity, but I'm not sure how to proceed.]}\\\text{For the}\sin\text{integral},\int_0^{2\pi}\sin (nx+x)\,dx=\int_0^{2\pi}\sin nx\cos x\,dx+\int_0^{2\pi}\cos nx\sin x\,dx.$$

I hope I'm on the right track. In the last step, I have $\sin nx$ and $\cos nx$ in the integrals, but I'm not sure if that helps me. I would appreciate any help with this. Thanks :)

As I indicated above, it'd be great to find a way to complete this induction proof—probably by, as Arkamis said, "working it like the transcontinental railroad" with trig identities (if that's possible). I think my instructor discouraged a simple $u$-substitution, because we've recently been focused on manipulating trig identities.

• Work it like the transcontinental railroad. Start applying trig identities to the $\sin$ integral, and others to the $\cos$ integral in parallel. Eventually, if you apply identities the right way, you should get something that matches up! – Emily Oct 22 '13 at 21:07
• What integration techniques have you known so far? – Mhenni Benghorbal Oct 22 '13 at 21:42
• @Jackson : this is so trivial to do using substitution, you should find out exactly what tools you are permitted to use. Is induction required? – Stefan Smith Oct 22 '13 at 22:13
• @StefanSmith As far as I know, induction is not required. I'm able to use integrals of polynomials, integrals of $\sin$ and $\cos$, and trig identities. – Jackson Oct 22 '13 at 22:20
• @StefanSmith Sorry if I caused a bit of frustration. I updated the question. – Jackson Oct 25 '13 at 2:51

Why not just compute it directly, using a substitution? If $u = nx$, then $\frac{du}{n} = dx$ and

\begin{align*} \\\int_0^{2\pi} \sin{nx} dx &= \int_{x = 0}^{x = 2\pi} \sin{u} \frac{du}{n} \\ &= -\frac{1}{n} \cos{u} \Big|_{x = 0}^{x = 2\pi} \\ &= -\frac{1}{n} \cos nx \Big|_0^{2\pi} \\ &= \frac{1}{n} \left(\cos{2\pi n} - \cos{0}\right) \\ &= \frac{1}{n} (1 - 1) = 0 \end{align*}

• I'm not allowed to use $u$-substitution in my class, unfortunately—we're taking a different approach, and I wouldn't get credit for that. – Jackson Oct 22 '13 at 21:01

I do not know if you can use $e^{ix}=\cos x+i\sin x$ but here is one solution: $$\int_0^{2\pi}e^{inx}\,dx=\frac 1{in}e^{inx}\left|_0^{2\pi}\right.=0$$

• I appreciate the answer, but this is definitely out of the scope of what I've learned and am able to apply in the class. – Jackson Oct 22 '13 at 21:11
• @Jackson: By the way, what course are you taking now? – Mhenni Benghorbal Oct 22 '13 at 21:41

Hint: $\sin(x+\pi)=-\sin(x)$ and $\cos(x+\pi)=-\cos(x)$.

What does the hint mean for $\int_0^{\pi/n}\sin(nx)\,\mathrm{d}x$ and $\int_{\pi/n}^{2\pi/n}\sin(nx)\,\mathrm{d}x$ ?

For $\int_0^{\pi/n}\cos(nx)\,\mathrm{d}x$ and $\int_{\pi/n}^{2\pi/n}\cos(nx)\,\mathrm{d}x$ ?

The substitution $t=2\pi - x$, $dt=-dx$ gives

$$\int_0^{2\pi} \sin nx\: dx = \int_{2\pi}^0 \sin (-nt) (-dt) = \int_{2\pi}^0 \sin nt\: dt = -\int_0^{2\pi} \sin nx\: dx$$

so $\int_0^{2\pi} \sin nx dx=0$. No need to evaluate the integral!

Can you find a similar trick for $\cos$?

• @StefanSmith Ah. It wasn't written in the question... – Bruno Joyal Oct 22 '13 at 23:25
• @Marie Could you explain the trick for $\cos$? – Jackson Oct 22 '13 at 23:36
• @Marie : OP edited the question, saying the instructor "discouraged a simple $u$ substitution" (see updated question). – Stefan Smith Oct 25 '13 at 18:03

Use the fact that $\sin$ is $2\pi$-periodic gives you

$$\int_0^{2\pi}\sin(nx)\,dx= \int_{-\pi}^{\pi}\sin(nx)=0,$$

because $\sin$ is an odd function. No induction needed. Proving the equation for $\cos$ looks difficult without using $u$-substitution in some form (you wrote in a comment that you weren't supposed to use substitution).

Draw the graphs. The function $x\mapsto \sin(nx)$ has $n$ complete periods on the interval $[0,2\pi]$. Each hump above the graph is geometrically congruent to its neighbor, which is below the $x$-axis. As a result, the signed area under the graph. $$\int_0^{2\pi}\sin(nx)\,dx = 0,$$ is zero.

You can see a similar phenomenon with the cosine function.

This can be turned into a calculaion easily

$$\int_0^{2\pi} \sin(nx)\, dx = \sum_{k=1}^n \int_{2(k-1)\pi/n}^{2k\pi/n} \sin(nx)\,dx = \int_0^{2\pi/n} \sin(x)\,dx = 0$$

• I understand this intuitively, but I'm not sure I could turn this in as a proof. – Jackson Oct 22 '13 at 22:22