Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Trying to evaluate this indefinite integral:

$$ \int (x^2 + 1)\cos2xdx$$

So far I have the following: $u=x^2 + 1 \Rightarrow du = 2xdx$ and $dv=\cos2x \Rightarrow v = \frac {\sin2x}{2}$. So the integral is equal to:

$$\int (x^2+1)\cos2xdx = (x^2+1)\frac{\sin2x}{2}-\int {\frac{\sin2x}{2}}2xdx$$

Next, I make another substitution for the integral on the right hand side; let $ u = x \Rightarrow du = dx$ and let $dv = \sin2x \Rightarrow v = \frac {-\cos2x}{2}$. Now I have the following:

$$\int (x^2+1)\cos2xdx = (x^2+1)\frac{\sin2x}{2}-\left (-\frac {x\cos2x}{2} - \int -\frac {cos2x}{2}dx\right)$$

Which after integrating becomes:

$$\int (x^2+1)\cos2xdx = (x^2+1)\frac{\sin2x}{2}-\left(-\frac {x\cos2x}{4} + \frac {\sin2x}{4}\right)$$

But when solving with the integrator on my calculator, I get a different answer (it looks like I am getting closer, but still off). What am I doing wrong here??

share|improve this question
5  
$du=2x\,dx$, not $du=x$. –  André Nicolas Dec 5 '11 at 6:48
    
Without going through your calculations: did you check if the derivative of your result and the derivative of the calculator's result agree with your original integrand? –  J. M. Dec 5 '11 at 6:49
    
@Andre: Arg. I see that mistake now. Forgot to bring the exponent down from $x^2$ and add $dx$. –  Dylan Dec 5 '11 at 6:52
    
@J.M. they did not agree. I tried again after taking note of the error which Andre pointed out, but this time I am just slightly off... more above. –  Dylan Dec 5 '11 at 7:04
    
"Solve" is the wrong word. You're trying to evaluate the integral. "Solutions" are sought for problems and for equations; values are sought for expressions (including integrals). –  Michael Hardy Dec 5 '11 at 17:54

1 Answer 1

up vote 1 down vote accepted

I see three mistakes in your calculations:

  1. As Andre pointed out in the comments, in the first substitution $du = 2x dx$.
  2. There is a sign error in the second integration by parts: $$-\left(-\frac{x\cos 2x}{2} - \int \frac{-\cos 2x}{2} dx\right) = \frac{x\cos 2x}{2} - \int \frac{\cos 2x}{2} dx.$$
  3. An integration constant should appear as early as the first integration by parts.
share|improve this answer
    
Ah, ok. The sign error fixed it - I should have put parentheses around the second integration by parts to avoid that error. And I added the integration constant. Thanks. –  Dylan Dec 5 '11 at 7:17

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.