\input homework_macros.tex

%\distiller
\printer
\def\picture #1 by #2 (#3){
  \vbox to #2{
    \hrule width #1 height 0pt depth 0pt
    \vfill
    \special{picture #3} % this is the low-level interface
    }
  }

\def\scaledpicture #1 by #2 (#3 scaled #4){{
  \dimen0=#1 \dimen1=#2
  \divide\dimen0 by 1000 \multiply\dimen0 by #4
  \divide\dimen1 by 1000 \multiply\dimen1 by #4
  \picture \dimen0 by \dimen1 (#3 scaled #4)}
  }

\def\dd#1#2{\frac{d#1}{d#2}}
\toks0={
9.9  p. 775:   1,  3,  7, 11, 21, 25, 29, 31, 37.
}
\def\Li{\displaystyle\lim_{n\to\infty}}
\def\Sum#1{\displaystyle\sum_{#1}^\infty}
\def\Int{\displaystyle\int}

\SN{\jobname}
\np
Area inside the oval lima\c con $r=4+2\cos\theta$.
To graph, start with $\theta=0$ so $r=6$.
Compute $\dd r\theta=-2\sin\theta$.
Interesting points are where $\dd r\theta$ vanishes, or at
$\theta=0$, $\pi$, $2\pi$, etc.
For these values of $\theta$ we compute $r$:
$(6,0)$, $(2,\pi)$ and the values repeat.
Hence, starting at $\theta=0$ and rotating counterclockwise,
we see the point moving in along the ray starting at $6$ until at
$\theta=\pi$ is has moved into $2$.
As the ray moves from $\theta=\pi$ to $\theta=2\pi$, the point move
out along the ray starting a $2$ and finishing at $6$.
Just to get a good picture it is worthwhile to plug in $\theta=\frac\pi2$
and $\theta=\frac{3\pi}2$ where $r=4$.
Hence the area we want is swept out once as $\theta$ rotates from $0$
to $2\pi$.
\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (limacon scaled 500)\hss}

From the formula in the book
${\bf Area}=\frac12\Int_0^{2\pi}r^2\>d\theta=
\frac12\Int_0^{2\pi}(4+2\cos\theta)^2)d\theta=
\frac12\Bigl(16\Int_0^{2\pi} d\theta+16\Int_0^{2\pi}\cos\theta\>d\theta
+4\Int_0^{2\pi}\cos^2\theta\>d\theta\Bigr)$.
Do the pieces: $\Int_0^{2\pi}d\theta=\theta\Big\vert^{2\pi}_0=2\pi$;
$\Int_0^{2\pi}\cos\theta\>d\theta=\sin\theta\Big\vert^{2\pi}_0=0-0=0$;
$\Int_0^{2\pi}\cos^2\theta\>d\theta=
\Int_0^{2\pi}\Frac{1+\cos(2\theta)}{2}d\theta=
\frac12\Int_0^{2\pi}d\theta+\frac12\Int_0^{2\pi}\cos(2\theta)d\theta$.
Pause to do $\Int_0^{2\pi}\cos(2\theta)d\theta=
\frac12\sin(2\theta)\Big\vert^{2\pi}_0=0-0=0$.
Hence $\Int_0^{2\pi}\cos^2\theta\>d\theta=\frac12\cdot2\pi=\pi$.
Hence the {\bf Area} is $\frac12(16\cdot 2\pi+16\cdot 0+4\cdot\pi)=
18\pi$.
\def\nL{\par\noindent\vrule width\hsize depth .1pt height 0pt\par}
\nL
\np
Area inside one leaf of the four-leafed rose $r=\cos(2\theta)$.
Begin with the graph, starting with $\theta=0$.
$\dd r\theta=-2\sin(2\theta)$ which vanishes when
$2\theta=0$, $\pi$, $2\pi$, $3\pi$, $4\pi$, etc. or when
$\theta=0$, $\frac\pi2$, $\pi$, $\frac{3\pi}2$, $2\pi$, etc.:
$r$ itself vanishes when $\theta=\frac{\pi}{4}$, $\frac{3\pi}{4}$,
$\frac{5\pi}{4}$, $\frac{7\pi}{4}$, etc.
\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (rose scaled 500)\hss}

A remark which is apparent if {\bf you} draw the graph but not if you
just look at it is that from $0$ to $\frac\pi4$ you trace out the top
half of the right-hand leaf, {\bf but} from $\frac\pi4$ to $\frac\pi2$
you trace out the left-half of the lower leaf.
You have many choices for a range of $\theta$ which sweep out
one leaf:
$[\frac\pi4${ to }$\frac{3\pi}4]$ sweeps out the lower leaf;
$[\frac{3\pi}4${ to }$\frac{5\pi}4]$ sweeps out the left-hand leaf;
$[\frac{5\pi}4${ to }$\frac{7\pi}4]$ sweeps out the upper-hand leaf;
$[\frac{7\pi}4${ to }$\frac{9\pi}4]$ sweeps out the right-hand leaf.
We can also sweep out the right-hand leaf with
$[-\frac\pi4${ to }$\frac\pi4]$ and this is the one we choose.
Hence the {\bf Area} is
$\frac12\Int^{\frac\pi4}_{-\frac\pi4}r^2d\theta=
\frac12\Int^{\frac\pi4}_{-\frac\pi4}\cos^2(2\theta)\>d\theta=
\frac12\Int^{\frac\pi4}_{-\frac\pi4}\Frac{1+\cos(4\theta)}{2}d\theta=
\frac14\Bigl(\Int^{\frac\pi4}_{-\frac\pi4}d\theta+
\Int^{\frac\pi4}_{-\frac\pi4}\cos(4\theta)\>d\theta\Bigr)$.
Do the pieces:
$\Int^{\frac\pi4}_{-\frac\pi4}d\theta=
\theta\Big\vert^{\frac\pi4}_{-\frac\pi4}=
\frac\pi4-\bigl(-\frac\pi4\bigr)=\frac\pi4+\frac\pi4=\frac\pi2$;
$\Int^{\frac\pi4}_{-\frac\pi4}\cos(4\theta)\>d\theta=
\frac14\sin(4\theta)\Big\vert^{\frac\pi4}_{-\frac\pi4}=
\frac14\bigl(\sin\pi -\sin(-\pi)\bigr)=0$.
The {\bf Area} is $\frac14\cdot\bigl(\frac\pi2+0\bigr)=\frac\pi8$.

\nL\np
Area shared by the circles $r=2\cos\theta$ and $r=2\sin\theta$.
\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (twocircles scaled 500)\hss}

By drawing the graph, you see each circle can be swept out once by
letting $\theta$ run from $0$ to $\pi$.
The polar coordinates of the intersection point can be found by solving
$2\cos\theta=2\sin\theta$, or $\tan\theta=1$ or $\theta=\frac\pi4$.
While there are many solutions to the equation $\tan\theta=1$,
they are all obtained by adding integer multiples of $\pi$
to $\frac\pi4$ and we see that the only one between $0$ and $\pi$
is $\frac\pi4$.
Hence the {\bf Area} is
$\frac12\Int_0^{\frac\pi4}(2\sin\theta)^2d\theta+
\frac12\Int_{\frac\pi4}^{\frac\pi2}(2\cos\theta)^2d\theta=
2\Int_0^{\frac\pi4}\sin^2\theta\>d\theta+
2\Int_{\frac\pi4}^{\frac\pi2}\cos^2\theta\>d\theta$.
Do the pieces:
$\Int_0^{\frac\pi4}\sin^2\theta\>d\theta=
\Int_0^{\frac\pi4}\Frac{1-\cos(2\theta)}{2}d\theta=
\frac12\Bigl(\Int_0^{\frac\pi4}d\theta-
\Int_0^{\frac\pi4}\cos(2\theta)d\theta\Bigr)=
\frac12\Bigl(\theta\Big\vert_0^{\frac\pi4}-
\frac12\sin(2\theta)\Big\vert_0^{\frac\pi4}\Bigr)=
\frac12\Bigl(\frac\pi4-\frac12\bigl(\sin\frac\pi2-\sin0\bigr)\Bigr)=
\frac12\Bigl(\frac\pi4-\frac12\Bigr)=\frac\pi8-\frac14$;
$\Int_{\frac\pi4}^{\frac\pi2}\cos^2\theta\>d\theta=
\Int_{\frac\pi4}^{\frac\pi2}\Frac{1+\cos(2\theta)}{2}d\theta=
\frac12\Bigl(\Int_{\frac\pi4}^{\frac\pi2}d\theta+
\Int_{\frac\pi4}^{\frac\pi2}\cos(2\theta)d\theta\Bigr)=
\frac12\Bigl(\theta\Big\vert_{\frac\pi4}^{\frac\pi2}+
\frac12\sin(2\theta)\Big\vert_{\frac\pi4}^{\frac\pi2}\Bigr)=
\frac12\Bigl(\bigl(\frac\pi2-\frac\pi4\bigr)+\frac12\bigl(
\sin\pi-\sin\frac\pi2\bigr)\Bigr)=
\frac12\Bigl(\frac\pi4+\frac12(0-1)\Bigr)=\frac\pi8-\frac14$.
Hence the {\bf Area} is
$2\bigl(\frac\pi8-\frac14\bigr)+2\bigl(\frac\pi8-\frac14\bigr)=
\frac\pi2-1$

\nL\np
Inside the lemniscate $r^2=6\cos(2\theta)$ and outside the circle
$r=\sqrt3$.
The lemniscate can be graphed as follows.
It is actually two equations
$r=\pm\sqrt{6\cos(2\theta)}$.
Intervals where $\cos(2\theta)<0$ are excluded: these intervals
are $(\frac\pi4,\frac{3\pi}4)$, $(\frac{5\pi}4,\frac{7\pi}4)$, etc.
The right-hand loop of the lemniscate is traced out by
starting $\theta$ at $-\frac\pi4$ and going to $\frac\pi4$.
The entire lemniscate can be described as the graph of
$r=\sqrt{6\cos(2\theta)}$ where $\theta$ runs over the intervals
$[-\frac\pi4,\frac\pi4]$ and $[\frac{3\pi}4,\frac{5\pi}4]$.
Next we need to find the four points of intersection, so solve
$6\cos(2\theta)=r^2=3$ or
$\cos(2\theta)=\frac12$ so $2\theta=\frac\pi3+2k\pi$, $k$ an integer,
or $2\theta=-\frac\pi3+2k\pi$.
Hence $\theta=\pm\frac\pi6+k\pi$ and the four points are 
$\theta=\frac\pi6$ (1st quadrant); $-\frac\pi6$ (4th quadrant);
$\frac{7\pi}6$ (3rd quadrant); and $\frac{5\pi}6$ (2nd quadrant).

\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (lemniscatecircle scaled 500)\hss}

The desired {\bf Area} is
$\frac12\Int_{-\frac\pi6}^{\frac\pi6}\bigl(6\cos(2\theta)-(\sqrt 3)^2\bigr)
d\theta+
\frac12\Int_{\frac{5\pi}6}^{\frac{7\pi}6}\bigl(6\cos(2\theta)-(\sqrt 3)^2\bigr)
d\theta=
3\Int_{-\frac\pi6}^{\frac\pi6}\cos(2\theta)\>d\theta-
\frac32\Int_{-\frac\pi6}^{\frac\pi6}d\theta+
3\Int_{\frac{5\pi}6}^{\frac{7\pi}6}\cos(2\theta)\>d\theta-
\frac32\Int_{\frac{5\pi}6}^{\frac{7\pi}6}d\theta=
3\sin(2\theta)\Big\vert_{-\frac\pi6}^{\frac\pi6}-
\frac32\theta\Big\vert_{-\frac\pi6}^{\frac\pi6}+
3\sin(2\theta)\Big\vert_{\frac{5\pi}6}^{\frac{7\pi}6}-
\frac32\theta\Big\vert_{\frac{5\pi}6}^{\frac{7\pi}6}=
3\bigl(\sin(\frac\pi3)-\sin(-\frac\pi3)\bigr)-
\frac32\bigl(\frac\pi6-(-\frac\pi6)\bigr)+
3\bigl(\sin(\frac{7\pi}3)-\sin(\frac{5\pi}3)\bigr)-
\frac32\bigl(\frac{7\pi}6-(\frac{5\pi}6)\bigr)$.
Now $\sin(\frac\pi3)=\frac{\sqrt3}2$;
$\sin(-\frac\pi3)=-\sin(\frac\pi3)$.
Since $\frac{7\pi}3=2\pi+\frac\pi3$,
$\sin(\frac{7\pi}3)=\sin(\frac\pi3)$ and
similarly, $\sin(\frac{5\pi}3)=\sin(-\frac\pi3)=-\sin(\frac\pi3)$.
Hence {\bf Area}$=6\frac{\sqrt3}2-\frac32\frac{2\pi}3=3\sqrt3-\pi$.

\nL\np
Find the length of the cardioid $r=1+\cos\theta$.

\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (cardioid scaled 500)\hss}

The graph is swept out once as $\theta$ runs from $0$ to $2\pi$.
{\bf Length}$=\Int_0^{2\pi}\sqrt{
r^2+(r^\prime)^2}\>d\theta$.
Compute as follows.
$\dd r\theta=-\sin\theta$, so $(r^\prime)^2=\sin^2\theta$ so
$r^2+(r^\prime)^2=(1+\cos\theta)^2+\sin^2\theta=
1+2\cos\theta+\cos^2\theta+\sin^2\theta=
2+2\cos\theta=2(1+\cos\theta )=4\Frac{1+\cos\theta}2=
4\cos^2\bigl(\frac\theta2\bigr)$.
Hence ${\bf Length}=\Int_0^{2\pi}\sqrt{4\cos^2\bigl(\frac\theta2\bigr)}\ 
d\theta=2\Int_0^{2\pi}
\Big\vert\cos\bigl(\frac\theta2\bigr)\Big\vert\>d\theta=
2\Int_0^{\pi} \cos\bigl(\frac\theta2\bigr)\>d\theta-
2\Int_{\pi}^{2\pi}\cos\bigl(\frac\theta2\bigr)\>d\theta=
2\biggl(2\sin\Bigl(\frac\theta2\Bigr)\Big\vert^{\pi}_{0}\biggr)-
2\biggl(2\sin\Bigl(\frac\theta2\Bigr)\Big\vert^{2\pi}_{\pi}\biggr)=
2\biggl(2\sin\Bigl(\frac\pi2\Bigr)-2\sin(0)\biggr)-
2\biggl(2\sin(\pi)-2\sin\Bigl(\frac\pi2\Bigr)\biggr)=8$.

\nL\np
Find the length of the curve $r=\cos^3\Bigl(\frac\theta3\Bigr)$
$0\leq\theta\leq\frac\pi4$.
There is no need to graph this curve since we are told the limits of
integration, but just for the record, here is the graph.

\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (notnecessary scaled 500)\hss}

Next compute $\dd r\theta=
3\cos^2\Bigl(\frac\theta3\Bigr)\biggl(-\sin\Bigl(\frac\theta3\Bigr)
\frac13\biggr)=
-\sin\Bigl(\frac\theta3\Bigr)\cos^2\Bigl(\frac\theta3\Bigr)$.
Hence $r^2+(r^\prime)^2=
\cos^6\Bigl(\frac\theta3\Bigr)+\sin^2\Bigl(\frac\theta3\Bigr)
\cos^4\Bigl(\frac\theta3\Bigr)=\cos^4\Bigl(\frac\theta3\Bigr)\biggl(
\cos^2\Bigl(\frac\theta3\Bigr)+\sin^2\Bigl(\frac\theta3\Bigr)\biggr)=
\cos^4\Bigl(\frac\theta3\Bigr)$.
Between $0$ and $\frac\pi4$, $\cos\Bigl(\frac\theta3\Bigr)>0$,
so
${\bf Length}=\Int_0^{\frac\pi4}
\sqrt{r^2+(r^\prime)^2\>}\>d\theta=
\Int^{\frac\pi4}_0\cos^2\Bigl(\frac\theta3\Bigr)\>d\theta=
\Int^{\frac\pi4}_0\Frac{1+\cos(\frac{2\theta}3)}{2}d\theta=
\frac12\Int^{\frac\pi4}_0 d\theta+
\frac12\Int^{\frac\pi4}_0\cos\Bigl(\frac{2\theta}3\Bigr)\>d\theta=
\frac12\theta\Big\vert^{\frac\pi4}_0+\frac12\biggl(
\frac32\sin\Bigl(\frac{2\theta}3\Bigr)\Big\vert^{\frac\pi4}_0\biggr)=
\frac12\bigl(\frac\pi4-0\bigr)+\frac34\Bigl(\sin\bigl(\frac\pi6\bigr)-
\sin(0)\Bigr)=\frac\pi8+\frac38$.

\nL\np
Find the surface area generated by revolving $r=\sqrt{\cos(2\theta)}$,
$0\leq\theta\leq\frac\pi4$ about the $y${--}axis.
Again the graph is not necessary but is included so you may practice if
you wish.
\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (surface scaled 500)\hss}

Compute as follows.
$\dd r\theta=\Frac{-\bigl(\sin(2\theta)\bigr)2}{2\sqrt{\cos(2\theta)}}=
-\Frac{\sin(2\theta)}{\sqrt{\cos(2\theta)}}$;
$r^2+(r^\prime)^2=\cos(2\theta)+\Frac{\sin^2(2\theta)}{\cos(2\theta)}=
\Frac{\cos^2(2\theta)+\sin^2(2\theta)}{\cos(2\theta)}=
\Frac{1}{\cos(2\theta)}$.
Hence $\sqrt{r^2+(r^\prime)^2}=\Frac{1}{\sqrt{\cos(2\theta)}}$.
From the book we have the formula,
${\bf Surface Area}=2\pi\Int_0^{\frac\pi4}
 r\cos\theta\sqrt{r^2+(r^\prime)^2\>}\>d\theta=$\par$
2\pi\Int^{\frac\pi4}_0\sqrt{\cos(2\theta)\>}
\cos\theta\Frac{1}{\sqrt{\cos(2\theta)\>}}\>d\theta=
2\pi\Int^{\frac\pi4}_0\cos\theta\>d\theta=
2\pi\sin\theta\Big\vert^{\frac\pi4}_0=
2\pi\Bigl(\sin\bigl(\frac\pi4\bigr)-\sin(0)\Bigr)=
2\pi\Frac{\sqrt 2}{2}=\pi\sqrt2$


\nL\np
Find the surface area generated by revolving $r^2=\cos(2\theta)$
about the $x${--}axis.
This time a graph is helpful in determining the limits of integration.

\vskip.75in
\hskip3in\hbox to0pt{\scaledpicture 100pt by 100pt (surfaceB scaled 500)\hss}

The function $\cos(2\theta)$ vanishes at $-\frac\pi4$, $\frac\pi4$,
$\frac{3\pi}4$, $\frac{5\pi}4$, etc. so the curve can be described
as $r=\sqrt{\cos(2\theta)}$ for $[-\frac\pi4,\frac\pi4]$ and
$[\frac{3\pi}4,\frac{5\pi}4]$.

A further problem occurs.
To get the surface of revolution, we should only rotate the top half
or the bottom half of the curve.
The right-hand branch can be swept out by letting $\theta$ run from
$0$ to $\frac\pi4$, which sweeps out the top half of the right-hand
piece.  
The top half of the left-hand piece needs $\theta$ to run from
$\frac{3\pi}4$ to $\pi$.

The next step is to compute $\sqrt{r^2+(r^\prime)^2}$.
We just did this in \#29 and we got
$\sqrt{r^2+(r^\prime)^2}=\Frac{1}{\sqrt{\cos(2\theta)}}$.

Hence ${\bf Surface Area}=
2\pi\Int_0^{\frac\pi4}\sqrt{\cos(2\theta)}\ 
\sin\theta\Frac{d\theta}{\sqrt{\cos(2\theta)}}+
2\pi\Int_{\frac{3\pi}4}^{\pi}\sqrt{\cos(2\theta)}\ 
\sin\theta\Frac{d\theta}{\sqrt{\cos(2\theta)}}=
2\pi\Int^{\frac\pi4}_0\sin\theta\>d\theta+
2\pi\Int^{\pi}_{\frac{3\pi}4}\sin\theta\>d\theta=
2\pi\Biggl((-\cos\theta)\Big\vert^{\frac\pi4}_0+
(-\cos\theta)\Big\vert^{\pi}_{\frac{3\pi}4}\Biggr)=
2\pi\Biggl(\Bigl(\bigl(-\cos\bigl(\frac\pi4\bigr)\bigr)-
\bigl(-\cos(0)\bigr)\Bigr)+
\Bigl(\bigl(-\cos(\pi)\bigr)-
\bigl(-\cos\bigl(\frac{3\pi}4\bigr)\bigr)\Bigr)\Biggr)
$.
Since $\cos\bigl(\frac\pi4\bigr)=\frac{\sqrt2}2$;
$\cos(0)=1$; $\cos(\pi)=-1$; and
$\cos\bigl(\frac{3\pi}4\bigr)=-\frac{\sqrt2}2$
we get ${\bf Surface Area}=2\pi(2-\sqrt2)$.

\nL\np
Find the centroid of the region enclosed by the cardioid
$r=a(1+\cos\theta)$.
Look at \#21 for the graph of the cardioid with $a=1$ and 
recall that the cure is swept out once as $\theta$ runs from
$0$ to $2\pi$.

To find the centroid we first calculate the area:
${\bf Area}=\frac12\Int_0^{2\pi}\bigl(a(1+\cos\theta)\bigr)^2d\theta=
\frac{a^2}2\Int_0^{2\pi}(1+2\cos\theta +\cos^2\theta)d\theta=
\frac{a^2}2\Bigl(
\Int^{2\pi}_0 d\theta+2\Int^{2\pi}_0\cos\theta\>d\theta+
\Int^{2\pi}_0\cos^2\theta\>d\theta\Bigr)=
\frac{a^2}2\Bigl(
\Int^{2\pi}_0 d\theta+2\Int^{2\pi}_0\cos\theta\>d\theta+
\Int^{2\pi}_0\Frac{1+\cos(2\theta)}{2}\>d\theta\Bigr)=
\frac{a^2}2\Bigl(
\frac32\Int^{2\pi}_0 d\theta+2\Int^{2\pi}_0\cos\theta\>d\theta+
\frac12\Int^{2\pi}_0\cos(2\theta)\>d\theta\Bigr)$.
The integral involving $\cos\theta$ is $0$ as is the integral
involving $\cos(2\theta)$ so
${\bf Area}=\Frac{6\pi a^2}{4}$.
Now we turn to the moments.

The {\bf moment about the $x${--}axis} is
$\frac13\Int^{2\pi}_0r^3\sin\theta\>d\theta=
\frac13\Int^{2\pi}_0a^3(1+\cos\theta)^3\sin\theta\>d\theta$.
Substitute $u=1+\cos\theta$, $du=-\sin\theta\> d\theta$.
$\Int^{2\pi}_0a^3(1+\cos\theta)^3\sin\theta\>d\theta=
-\Int^{2}_2a^3u^3\>du=0$.
Once can also argue from symmetry: there is as much of the curve
above the $x${--}axis as below it.

The {\bf moment about the $y${--}axis} is
$\frac13\Int^{2\pi}_0r^3\cos\theta\>d\theta=
\frac13\Int^{2\pi}_0a^3(1+\cos\theta)^3\cos\theta\>d\theta=
\frac{a^3}3\Int^{2\pi}_0(1+3\cos\theta+
3\cos^2\theta+\cos^3\theta)\cos\theta\>d\theta=
\frac{a^3}3\Int^{2\pi}_0(\cos\theta+3\cos^2\theta+
3\cos^3\theta+\cos^4\theta)\>d\theta=
$.

We can do $\Int\cos^4\>d\theta$ by parts as follows.
Let $u=\cos^3\theta$, $dv=\cos\theta\>d\theta$.
Then $du=-3\cos^2\theta\sin\theta\>d\theta$ and 
$v=\sin\theta$.
Hence $\Int\cos^4\>d\theta=\cos^3\theta\sin\theta-
\int(\sin\theta(-3\cos^2\theta\sin\theta)d\theta=
\cos^3\theta\sin\theta+3\Int\cos^2\theta\sin^2\theta\>d\theta
$.
Now write $\sin^2\theta=1-\cos^2\theta$ so
$\Int\cos^2\theta\sin^2\theta\>d\theta=
\Int\cos^2\theta\>d\theta-\Int\cos^4\theta\>d\theta$.
Plug back in and solve for $\Int\cos^4\theta\>d\theta$:
$4\Int\cos^4\theta\>d\theta=
\cos^3\theta\sin\theta+3\Int\cos^2\theta\>d\theta$, or
$\Int\cos^4\theta\>d\theta=
\Frac{\cos^3\theta\sin\theta}4+\frac34\Int\cos^2\theta\>d\theta$.

A similar Integration by Parts and solving for the integral gives
$\Int\cos^3\theta\>d\theta=
\Frac{\cos^2\theta\sin\theta}{3}+\frac23\Int\cos\theta\>d\theta$.


Hence 
$\Int^{2\pi}_0(\cos\theta+3\cos^2\theta+
3\cos^3\theta+\cos^4\theta)\>d\theta=
\Int^{2\pi}_0(3\cos\theta+\frac{15}4\cos^2\theta)\>d\theta
+\cos^2\theta\sin\theta\Big\vert^{2\pi}_0+
\Frac{\cos^3\theta\sin\theta}4\Big\vert^{2\pi}_0$.
Further $\Int^{2\pi}_0\cos\theta\>d\theta=0$ and
$\Int^{2\pi}_0\cos^2\theta\>d\theta=
\Int^{2\pi}_0\Frac{1+\cos(2\theta)}{2}\>d\theta=
\pi$.
Hence the {\bf moment about the $y${--}axis} $=\frac{a^3}3\frac{15\pi}4=
\frac{5\pi a^3}{4}$.

Therefore, the $x$ coordinate of the center of mass is
$\Frac{\frac{5\pi a^3}{4}}{\frac{6\pi a^2}{4}}=\Frac{5a}{6}$.
The $y$ coordinate of the center of mass is $0$.
\end