# Area of Surface Revolution of $y = \sin(\pi x)$ From 0 to 1

I have been trying to solve this problem and I am making a mistake somewhere that I can't discern.

To begin with, $y = \sin(\pi x)$ and thus $\frac{dy}{dx} = \pi\cos(\pi x)$, and $(\frac{dy}{dx})^2 = \pi^2\cos^2(\pi x)$

So, the formula for the surface of revolution should be $2\pi\int_0^1 \sin(\pi x)\sqrt{1+\pi^2\cos^2(\pi x)} dx$

A substitution of $u=\pi \cos(\pi x)$ and $du=-\pi^2 \sin(\pi x)dx$ yields:

$-\frac{2 \pi}{\pi^2} \int_1^{-1} \sqrt{1+u^2}du$ which is also $\frac{2}{\pi} \int_{-1}^{1} \sqrt{1+u^2}du$

From here I set $u = \tan(\theta)$ and $du = \sec^2(\theta)d \theta$. Along with the trig substitution, I changed the limits of limits of integration to: $-\frac\pi 4$ (lower) and $\frac\pi 4$ (upper).

Following that trig substitution eventually took me to $\frac2\pi\int_{-\frac\pi 4}^{\frac\pi 4} \sec^3(\theta) d \theta$.

The above integral resolves to: $$\frac2\pi \left[{\frac{ \sec(\theta) \tan(\theta) + \ln{|\sec(\theta) + \tan(\theta)|}}{2}}\right] _{-\frac\pi 4}^{\frac\pi 4}$$ ...which I don't believe correctly evaluates to the answer to the original question. I believe my error was made earlier in the problem.

I've done something wrong, I'm interested in solving it with my method, but I need to know what my mistake(s) is/are. Can anyone help me figure out what I've done wrong?

When you change variables the first time putting $u$ in terms of $x,$ when $x=0$ you should have $u=\pi \cos 0=\pi,$ and for $x=1$ it is $u=\pi \cos (\pi)=-\pi.$ With this change it comes out $7.77939,$ which agrees with what maple found for the original integral without any initial substitution.