Hey there! Sign in to join this conversationNew here? Join for free

Need help with this tricky integration question Watch

    • Thread Starter
    Offline

    16
    ReputationRep:
    So the question is to integrate

    \displaystyle \int{\frac{sin(x)}{sin(x)+cos(x)  }}dx

    My working out is below
    Note: After I used a second substitution, I realised I was going no one with it and the integration calculators online have strange approaches to this question.
    Name:  integ help.jpg
Views: 24
Size:  54.7 KB

    Spoiler:
    Show


    Answer is -\frac{1}{2}ln|\displaystyle {sin(x)+cos(x)}|+\frac{x}{2}+C

    Offline

    17
    ReputationRep:
    No substitutions required. First step, times top and bottom by (sinx-cosx)/(sinx-cosx) then use the cos2x identity . Tbf I didn't work that out but seeing the answer gave it away for me.
    Offline

    17
    ReputationRep:
    And yeah god cleaning it up at the end is a nightmare too. Do you want me to work through it again in a clear way then post a picture to get past the integrating stage then you can see if you can clean it up to get to that point.
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by black1blade)
    And yeah god cleaning it up at the end is a nightmare too. Do you want me to work through it again in a clear way then post a picture to get past the integrating stage then you can see if you can clean it up to get to that point.
    I understand how the denominator becomes \displaystyle {cos(2x)} but I'm still figuring out the numerator because I have \displaystyle {sin^{2}(x)-sin(x)cos(x)}
    Offline

    17
    ReputationRep:
    (Original post by ManLike007)
    I understand how the denominator becomes \displaystyle {cos(2x)} but I'm still figuring out the numerator because I have \displaystyle {sin^{2}(x)-sin(x)cos(x)}
    At this point it is easiest if you split the fraction. You should be able to deal with the sin^2(x) bit using cos(2x)=1-2sin^2(x). You can then use sin(2x)=2sin(x)cos(x) for the second fraction. After that point you should be able to cancel stuff so you have standard integrals. I guess it's still quite difficult if you don't have a formula book on you with a bunch of standard integrals in it. Where is this question from because it sure as hell ain't a c4 question XD.
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by black1blade)
    At this point it is easiest if you split the fraction. You should be able to deal with the sin^2(x) bit using cos(2x)=1-2sin^2(x). You can then use sin(2x)=2sin(x)cos(x) for the second fraction. After that point you should be able to cancel stuff so you have standard integrals. I guess it's still quite difficult if you don't have a formula book on you with a bunch of standard integrals in it. Where is this question from because it sure as hell ain't a c4 question XD.
    Oh lol no it's not A Level, it's a problem solving sheet from my university
    Offline

    17
    ReputationRep:
    Okay yeah I've gotten to the provided answer .
    Offline

    17
    ReputationRep:
    (Original post by ManLike007)
    Oh lol no it's not A Level, it's a problem solving sheet from my university
    Ah fair fairs. Yeah tbh I wouldn't have know what to do without peaking at the answer. I think the general thought process should be that with trig integrals you are gonna want to use identities and to use identities, most have sin or cos squared so you want to make as much sin or cos squared while getting rid of the cos and sin to the power 1. .
    Offline

    17
    ReputationRep:
    Do the problem solving sheets count for any of your grade or are they just for supervision type thingies?
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by black1blade)
    Do the problem solving sheets count for any of your grade or are they just for supervision type thingies?
    Nah it's just practice, we have 1 hour each week taught by a PhD student and we get as far as we can with the work sheet, same goes for my other modules.
    Offline

    17
    ReputationRep:
    (Original post by ManLike007)
    Nah it's just practice, we have 1 hour each week taught by a PhD student and we get as far as we can with the work sheet, same goes for my other modules.
    Ah fair fairs, sounds fun .
    • Community Assistant
    Offline

    18
    ReputationRep:
    Community Assistant
    (Original post by ManLike007)
    So the question is to integrate

    \displaystyle \int{\frac{sin(x)}{sin(x)+cos(x)  }}dx

    My working out is below
    Note: After I used a second substitution, I realised I was going no one with it and the integration calculators online have strange approaches to this question.
    Name:  integ help.jpg
Views: 24
Size:  54.7 KB

    Spoiler:
    Show



    Answer is -\frac{1}{2}ln|\displaystyle {sin(x)+cos(x)}|+\frac{x}{2}+C


    If you can't recognise what the poster above suggested a tangent half angle substitution would also work, but it is longer.
    Online

    18
    ReputationRep:
    As this integral is for fun, here's a fun method useful for similar integrals:

    Let \displaystyle I = \int \frac{\sin x}{\sin x + \cos x} \mathrm dx and \displaystyle J = \int \frac{\cos x}{\sin x + \cos x}\mathrm dx.

    Consider I+J and I-J to form a system of equations and solve for I and J.
    Online

    18
    ReputationRep:
    (Original post by ManLike007)
    Where does the \frac{1}{2} come in?

    I'm left with -ln|sin(x)+cos(x)|+x+C whereas the answer is -\frac{1}{2}ln|\displaystyle {sin(x)+cos(x)}|+\frac{x}{2}+C
    You have I+J + I - J = \boxed{2}I = x -\ln|\sin x + \cos x| + C.This is probably where you dropped the 1/2.
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by _gcx)
    You have I+J + I - J = \boxed{2}I = x -\ln|\sin x + \cos x| + C.This is probably where you dropped the 1/2.
    I know! I just realised it, my bad, I deleted my comment but then you just replied, thanks for the method by the way.

    Is this method only applicable in cases where you have \displaystyle \int \frac{A}{A \pm B} ? (where A and B are functions) What's this method called as well?
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by NotNotBatman)
    If you can't recognise what the poster above suggested a tangent half angle substitution would also work, but it is longer.
    I'm sorry, I've never heard of this method before but thanks for your time though
    Offline

    10
    ReputationRep:
    (Original post by _gcx)
    As this integral is for fun, here's a fun method useful for similar integrals:

    Let \displaystyle I = \int \frac{\sin x}{\sin x + \cos x} \mathrm dx and \displaystyle J = \int \frac{\cos x}{\sin x + \cos x}\mathrm dx.

    Consider I+J and I-J to form a system of equations and solve for I and J.
    Thanks, I love this method!
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by black1blade)
    Ah fair fairs. Yeah tbh I wouldn't have know what to do without peaking at the answer. I think the general thought process should be that with trig integrals you are gonna want to use identities and to use identities, most have sin or cos squared so you want to make as much sin or cos squared while getting rid of the cos and sin to the power 1. .
    Lol I've given up on this, I shouldn't have spent 2 hours on this question but thanks for your contribution
    Online

    17
    ReputationRep:
    (Original post by ManLike007)
    Lol I've given up on this, I shouldn't have spent 2 hours on this question but thanks for your contribution
    I know you've given up, but another approach that might make sense for you:

    Make the substitution u = x + pi / 4, then

    sin x + cos x = \sqrt{2} \sin u

    and sin x = sin(u-pi/4) = sin u cos pi/4 - cos u sin pi /4 = \dfrac{1}{\sqrt{2}} (\sin u - \cos u)

    This gives you an integral very similar to what you started with, but with numerator and denominator flipped. Since it is much easier to divide sin u and cos u by sin u than it is to divide sin x by (sin x + cos x), this new integral is pretty straightforward.
    • Thread Starter
    Offline

    16
    ReputationRep:
    (Original post by DFranklin)
    I know you've given up, but another approach that might make sense for you:

    Make the substitution u = x + pi / 4, then

    sin x + cos x = \sqrt{2} \sin u

    and sin x = sin(u-pi/4) = sin u cos pi/4 - cos u sin pi /4 = \dfrac{1}{\sqrt{2}} (\sin u - \cos u)

    This gives you an integral very similar to what you started with, but with numerator and denominator flipped. Since it is much easier to divide sin u and cos u by sin u than it is to divide sin x by (sin x + cos x), this new integral is pretty straightforward.
    I perfectly understand what you've done but after you integrate, my answer isn't actually what I want,

    \displaystyle \frac{1}{2} \int \frac{sin(u)-cos(u)}{sin(u)} du

    \displaystyle  \frac{1}{2} \int 1-cot(u) du

    =\frac{1}{2}[u-ln|sin(u)|]+C

    =\frac{1}{2}[x+\frac{\pi}{4}-ln|\frac{1}{\sqrt{2}}sin(x)+(1/\sqrt{2})cos(x)|+C

    (LaTex bugged out towards the end of my last sentence writing cos(x) so I couldn't use a fraction)

    Am I doing something wrong here?
 
 
 
  • See more of what you like on The Student Room

    You can personalise what you see on TSR. Tell us a little about yourself to get started.

  • Poll
    Would you rather give up salt or pepper?
    Useful resources

    Make your revision easier

    Maths

    Maths Forum posting guidelines

    Not sure where to post? Read the updated guidelines here

    Equations

    How to use LaTex

    Writing equations the easy way

    Student revising

    Study habits of A* students

    Top tips from students who have already aced their exams

    Study Planner

    Create your own Study Planner

    Never miss a deadline again

    Polling station sign

    Thinking about a maths degree?

    Chat with other maths applicants

    Can you help? Study help unanswered threads

    Groups associated with this forum:

    View associated groups
  • See more of what you like on The Student Room

    You can personalise what you see on TSR. Tell us a little about yourself to get started.

  • The Student Room, Get Revising and Marked by Teachers are trading names of The Student Room Group Ltd.

    Register Number: 04666380 (England and Wales), VAT No. 806 8067 22 Registered Office: International House, Queens Road, Brighton, BN1 3XE

    Write a reply...
    Reply
    Hide
    Reputation gems: You get these gems as you gain rep from other members for making good contributions and giving helpful advice.