Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Integration by parts; the error of my ways

  1. Aug 23, 2008 #1
    Hi all,

    I'm working on an ODE and ran into this integration by parts. My calculus is terrible. Can someone help?

    [tex] e^{2t}x = \int e^{2t}cos(t) \ dt = \frac{1}{2}cos(t) \ e^{2t} + \frac{1}{2}\int e^{2t}sin(t)\ dt = \frac{1}{2}cos(t)\ e^{2t} + \frac{1}{2}\left(-e^{2t}cos(t) + 2\int cos(t)\ e^{2t} \right) = \frac{1}{2}cos(t) \e^{2t} - \frac{1}{2}cos(t)\ e^{2t} + 2\int cos(t)\ e^{2t} dt [/tex]

    Now that can't be right. Where did I go wrong?
  2. jcsd
  3. Aug 23, 2008 #2


    User Avatar
    Homework Helper

    [tex]\int u \frac{dv}{dt} \ dt=uv- \int v \frac{du}{dt} \ dt[/tex]

    [tex]\int e^{2t}cos(t) \ dt[/tex]

    u=e-2t so that [itex]du=-2e^{-2t}dt[/itex]
    dv=cos(t) dt => v=-sin(t).

    So it should be -2e-2tsin(t). I think the mistake you kept on making is when you put back the functions into the formula. It's uv, you kept putting 'u*dv' if you get what I'm saying.
    Last edited: Aug 23, 2008
  4. Aug 23, 2008 #3
    I'm not sure where x comes in, but I think you want to calculate

    [tex]\int e^{2t}cos(t) \ dt[/tex]

    Anyways I found the antiderivative but I let u = e^(2x) and dv = cos(t)dt whereas you choose differently. I'm not sure if my way is easier or less messier but I will try to find out where you went wrong.
  5. Aug 23, 2008 #4
    OK, I did the problem letting u be the trig function and dv be the exponential and got the same antiderivative (as I should). It wasn't that much messier.


    [tex]\int e^{2t}cos(t) \ dt = \frac{1}{2}cos(t) \ e^{2t} + \frac{1}{2}\int e^{2t}sin(t)dt[/tex]

    is correct.

    Actually here:

    [tex]\frac{1}{2}cos(t) \ e^{2t} + \frac{1}{2}\int e^{2t}sin(t)\ dt = \frac{1}{2}cos(t)\ e^{2t} + \frac{1}{2}\left(-e^{2t}cos(t) + 2\int cos(t)\ e^{2t} \right)[/tex]

    it looks as though you're still correct

    Hmmmm, does it have to do with inconsistency in choosing u's and dv's?


    Hmm ok I think I finally get it. Well to be honest I only know how to derive the integration by parts formula and apply it in simple situations. But it looks like you first let u = cos(t) and dv = e^(2t) dt. But then for the next integration by parts, you choose u = e^(2t) and dv = sin(t) dt.

    This inconsistency leads to a true statement. In fact you end up with 0 = 0. But this is a pretty trivial result. I'm not sure why this happens but I think to find the actual antiderivative in this case, you have to be consistent (let u be be e^(2x) both times or let u be the trig function both times). If you're consistent, I guarantee you'll find the antiderivative if you can do the algebra. I guess it's not really an error since you end up with 0 = 0 but perhaps someone else could explain why it happened.
    Last edited: Aug 23, 2008
  6. Aug 24, 2008 #5
    Hi everybody!

    Somefantastik, there's a way to calculate this integral without using integration by parts!

    Just transform the cos-function in the complex e-function, do the calculations and take the real part of the final solution! - Here's how it works:

    [tex]\displaystyle{\int}e^{2t}\cos t dt=\displaystyle{\int}e^{2t} Re(e^{it}) dt=Re\displaystyle}{(\int}e^{(2+i)t} dt)=Re(\frac{e^{(2+i)t}}{2+i})[/tex]

    now, taking the real part of it:

    [tex]Re(\frac{e^{(2+i)t}}{2+i})=Re(\frac{2-i}{4+1}e^{2t}e^{it})=Re(\frac{e^{2t}}{5}(2-i)(cost+i\sin t))=\frac{e^{2t}}{5}Re((2-i)(\cos t+i\sin t))=\frac{e^{2t}}{5}(2\cos t+\sin t)[/tex]

    In the end, adding the arbitrary constant we finally get:

    [tex]\displaystyle{\int}e^{2t}\cos t dt=\frac{e^{2t}}{5}(2\cos t+\sin t)+C[/tex]

    ** How does one make the parenthesis big? And how does one get the following type of brackets "{ }"? (Thanks a lot)
  7. Aug 24, 2008 #6

    Right. And because that started out being equal to x*e^2t, then:
    x = 1/5 sin(t) + 2/5 cos(t) + Ae^-2t
    You can also get this by using cyclic integration by parts and an algebraic
    substitution for the integral.

    My latex is Much worse than yours, sorry can't help you there!:uhh:
  8. Aug 24, 2008 #7


    User Avatar
    Science Advisor
    Homework Helper


    Hi Marin! :smile:

    You use \left and \right before each bracket (but it only make them large enough to fit what you've typed inside, so it makes no difference if it's all on one line):

    [tex]\frac{e^{2t}}{5}\left(2\cos t+\sin t\right)[/tex]

    [tex]{e^{2t}\left(\frac{2\cos t+\sin t}{5}\right)[/tex]

    [tex]{e^{2t}\left[\frac{2\cos t+\sin t}{5}\right][/tex]

    [tex]{e^{2t}\left<\frac{2\cos t+\sin t}{5}\right>[/tex]

    [tex]{e^{2t}\left|\frac{2\cos t+\sin t}{5}\right|[/tex]

    And you must put \ in front to get { or }:

    [tex]{e^{2t}\left\{\frac{2\cos t+\sin t}{5}\right\}[/tex]

    see http://www.physics.udel.edu/~dubois/lshort2e/node54.html#SECTION00830000000000000000 [Broken] :smile:
    Last edited by a moderator: May 3, 2017
  9. Aug 24, 2008 #8
    Thanks a lot, tiny-tim!

    I've been using LaTeX for a month and it's quite extraordinary to me still :)

    but I'm gonna get used to it :) - I caught up the main commands but there are still some I'm missing out :)
  10. Aug 24, 2008 #9
    Whoa that's pretty cool Marin. It's probably a lot shorter than cyclic IBP and then solving for the original integral. Anyways I never learned that in my high school calc class. Is this a topic in complex analysis?
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook