# How do I solve $\int4\cos^2(x) dx$? [duplicate]

This question already has an answer here:

I have the basic idea of how to work out the integral of a trig function, but am having trouble in applying the concept. Would really appreciate it if someone could help me. Thanks!

## marked as duplicate by Hans Lundmark, Tom-Tom, Claude Leibovici calculus StackExchange.ready(function() { if (StackExchange.options.isMobile) return; $('.dupe-hammer-message-hover:not(.hover-bound)').each(function() { var$hover = $(this).addClass('hover-bound'),$msg = $hover.siblings('.dupe-hammer-message');$hover.hover( function() { $hover.showInfoMessage('', { messageElement:$msg.clone().show(), transient: false, position: { my: 'bottom left', at: 'top center', offsetTop: -7 }, dismissable: false, relativeToBody: true }); }, function() { StackExchange.helpers.removeMessages(); } ); }); }); Jan 27 '16 at 8:19

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

• $$\cos2A=2\cos^2A-1$$ – lab bhattacharjee Jan 27 '16 at 7:17
• @labbhattacharjee Shouldn't this be an answer, rather than a comment? – 5xum Jan 27 '16 at 7:27
• @HansLundmark Didn't understand that. Sorry! – Krunal Rindani Jan 27 '16 at 7:32
• – Martin Sleziak Jun 17 '16 at 4:19
• See also: How to evaluate $\int \cos^2x \ dx$ – Martin Sleziak Jul 9 '17 at 8:54

## 1 Answer

$\int 4 \cos^2(x) dx$

$\mathrm{Take\:the\:constant\:out}:\quad \int a\cdot f\left(x\right)dx=a\cdot \int f\left(x\right)dx$

$=4\int\cos^2(x) dx$

$\mathrm{Use\:the\:following\:identity}:\quad \cos ^2\left(x\right)=\frac{1+\cos \left(2x\right)}{2}$

$=4\int \frac{1+\cos \left(2x\right)}{2}dx$

$\mathrm{Take\:the\:constant\:out}:\quad \int a\cdot f\left(x\right)dx=a\cdot \int f\left(x\right)dx$

$=4\frac{1}{2}\int \:1+\cos \left(2x\right)dx$

$\mathrm{Apply\:Integral\:Substitution:}\:\int > f\left(g\left(x\right)\right)\cdot g^{'}\left(x\right)dx=\int > f\left(u\right)du,\:\quad u=g\left(x\right)$

$\mathrm{Substitute:}\:u=2x$

$\frac{du}{dx}=2$

$\quad \Rightarrow \:du=2dx$

$\Rightarrow \:dx=\frac{1}{2}du$

$=\int \left(1+\cos \left(u\right)\right)\frac{1}{2}du$

$=4\frac{1}{2}\int \left(1+\cos \left(u\right)\right)\frac{1}{2}du$

$\mathrm{Take\:the\:constant\:out}:\quad \int a\cdot f\left(x\right)dx=a\cdot \int f\left(x\right)dx$

$=4\frac{1}{2}\frac{1}{2}\int \:1+\cos \left(u\right)du$

$\mathrm{Apply\:the\:Sum\:Rule}:\quad \int f\left(x\right)\pm g\left(x\right)dx=\int f\left(x\right)dx\pm \int g\left(x\right)dx$

$=4\frac{1}{2}\frac{1}{2}\left(\int \:1du+\int \cos \left(u\right)du\right)$

$=4\frac{1}{2}\frac{1}{2}\left(u+\sin \left(u\right)\right)$

$\mathrm{Substitute\:back}\:u=2x$

$=4\frac{1}{2}\frac{1}{2}\left(2x+\sin \left(2x\right)\right)$

$\mathrm{Simplify}$

$=2x+\sin \left(2x\right)$

$Add\:a\:constant\:to\:the\:solution$

$=2x+\sin \left(2x\right)+C$

• Mithilesh, I can't thank you enough for such answer. I hope you have a good day. Your answer helped me a lot more than you'd think. Thanks again. – Krunal Rindani Jan 27 '16 at 11:02
• @KrunalRindani, you are welcome :). – 1 0 Jan 27 '16 at 11:49