Solving integral using residues












1












$begingroup$


I'm trying to find the value of the integral $int_0^{2pi}frac{cos^2u}{2-sin u}du$ using the substitution: $cos u =frac{1}{2}(z+frac{1}{z})$ and $sin u = frac{1}{2i}(z-frac{1}{z})$. Making the substitution, we obtain $int_C(z^2+1)^2/(2z^2(z^2+4iz-1)dz$ where C denotes the unit circle. I leave out the steps inbetween because I do not believe the error was made there.

Next, I found the roots of the polynomial in the denominator, which are the poles of the integrand. I found these to be $z_0=0$, $z_1=i(-2+sqrt3)$, $z_2=i(-2-sqrt3)$. Only $z_0$ and $z_1$ lie inside the unit circle, so the value of the integral will be $2pi i[Res(0)+Res(i(-2+sqrt3))]$. $Res(0)$ is easily obtained. $Res(i(2-sqrt3))$ should be too, since $z_1$ is a first order pole, so I can just take $lim_{zto z_1}[f(z)(z-z_1)]$. The results are $$Res(0)= lim_{zto 0}frac{d}{dz}z^2f(z)=...=-2i$$ and $$Res(i(sqrt3-2))=lim_{zto z_1}(z-z_1)f(z)=...=-3/2+sqrt3$$
What mistake did I make? My answer turns out to be $2pi i(-2i-3/2+sqrt3)$, the solution is $-2pi(sqrt3-2)$.










share|cite|improve this question









$endgroup$

















    1












    $begingroup$


    I'm trying to find the value of the integral $int_0^{2pi}frac{cos^2u}{2-sin u}du$ using the substitution: $cos u =frac{1}{2}(z+frac{1}{z})$ and $sin u = frac{1}{2i}(z-frac{1}{z})$. Making the substitution, we obtain $int_C(z^2+1)^2/(2z^2(z^2+4iz-1)dz$ where C denotes the unit circle. I leave out the steps inbetween because I do not believe the error was made there.

    Next, I found the roots of the polynomial in the denominator, which are the poles of the integrand. I found these to be $z_0=0$, $z_1=i(-2+sqrt3)$, $z_2=i(-2-sqrt3)$. Only $z_0$ and $z_1$ lie inside the unit circle, so the value of the integral will be $2pi i[Res(0)+Res(i(-2+sqrt3))]$. $Res(0)$ is easily obtained. $Res(i(2-sqrt3))$ should be too, since $z_1$ is a first order pole, so I can just take $lim_{zto z_1}[f(z)(z-z_1)]$. The results are $$Res(0)= lim_{zto 0}frac{d}{dz}z^2f(z)=...=-2i$$ and $$Res(i(sqrt3-2))=lim_{zto z_1}(z-z_1)f(z)=...=-3/2+sqrt3$$
    What mistake did I make? My answer turns out to be $2pi i(-2i-3/2+sqrt3)$, the solution is $-2pi(sqrt3-2)$.










    share|cite|improve this question









    $endgroup$















      1












      1








      1





      $begingroup$


      I'm trying to find the value of the integral $int_0^{2pi}frac{cos^2u}{2-sin u}du$ using the substitution: $cos u =frac{1}{2}(z+frac{1}{z})$ and $sin u = frac{1}{2i}(z-frac{1}{z})$. Making the substitution, we obtain $int_C(z^2+1)^2/(2z^2(z^2+4iz-1)dz$ where C denotes the unit circle. I leave out the steps inbetween because I do not believe the error was made there.

      Next, I found the roots of the polynomial in the denominator, which are the poles of the integrand. I found these to be $z_0=0$, $z_1=i(-2+sqrt3)$, $z_2=i(-2-sqrt3)$. Only $z_0$ and $z_1$ lie inside the unit circle, so the value of the integral will be $2pi i[Res(0)+Res(i(-2+sqrt3))]$. $Res(0)$ is easily obtained. $Res(i(2-sqrt3))$ should be too, since $z_1$ is a first order pole, so I can just take $lim_{zto z_1}[f(z)(z-z_1)]$. The results are $$Res(0)= lim_{zto 0}frac{d}{dz}z^2f(z)=...=-2i$$ and $$Res(i(sqrt3-2))=lim_{zto z_1}(z-z_1)f(z)=...=-3/2+sqrt3$$
      What mistake did I make? My answer turns out to be $2pi i(-2i-3/2+sqrt3)$, the solution is $-2pi(sqrt3-2)$.










      share|cite|improve this question









      $endgroup$




      I'm trying to find the value of the integral $int_0^{2pi}frac{cos^2u}{2-sin u}du$ using the substitution: $cos u =frac{1}{2}(z+frac{1}{z})$ and $sin u = frac{1}{2i}(z-frac{1}{z})$. Making the substitution, we obtain $int_C(z^2+1)^2/(2z^2(z^2+4iz-1)dz$ where C denotes the unit circle. I leave out the steps inbetween because I do not believe the error was made there.

      Next, I found the roots of the polynomial in the denominator, which are the poles of the integrand. I found these to be $z_0=0$, $z_1=i(-2+sqrt3)$, $z_2=i(-2-sqrt3)$. Only $z_0$ and $z_1$ lie inside the unit circle, so the value of the integral will be $2pi i[Res(0)+Res(i(-2+sqrt3))]$. $Res(0)$ is easily obtained. $Res(i(2-sqrt3))$ should be too, since $z_1$ is a first order pole, so I can just take $lim_{zto z_1}[f(z)(z-z_1)]$. The results are $$Res(0)= lim_{zto 0}frac{d}{dz}z^2f(z)=...=-2i$$ and $$Res(i(sqrt3-2))=lim_{zto z_1}(z-z_1)f(z)=...=-3/2+sqrt3$$
      What mistake did I make? My answer turns out to be $2pi i(-2i-3/2+sqrt3)$, the solution is $-2pi(sqrt3-2)$.







      complex-analysis residue-calculus






      share|cite|improve this question













      share|cite|improve this question











      share|cite|improve this question




      share|cite|improve this question










      asked Jan 7 at 18:54









      user569579user569579

      826




      826






















          2 Answers
          2






          active

          oldest

          votes


















          1












          $begingroup$

          Let $tanfrac{u}{2}=x$.



          Thus, $$dx=frac{1}{2cos^2frac{u}{2}}du=frac{1}{2}(1+x^2)du,$$ which gives
          $$du=frac{2}{1+x^2}dx.$$
          Hence, $$intfrac{cos^2u}{2-sin{u}}du=intleft(2+sin{u}-frac{3}{2-sin{u}}right)du=$$
          $$=2u-cos{u}-3intfrac{1}{2-frac{2x}{1+x^2}}frac{2}{1+x^2}dx=$$
          $$=2u-cos{u}-3intfrac{1}{1-x+x^2}dx=2u-cos{u}-3intfrac{1}{left(x-frac{1}{2}right)^2+left(frac{sqrt3}{2}right)^2}dx=$$
          $$=2u-cos{u}-2sqrt3arctanfrac{2tanfrac{u}{2}-1}{sqrt3}+C.$$
          Can you end it now?






          share|cite|improve this answer









          $endgroup$













          • $begingroup$
            I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
            $endgroup$
            – user569579
            Jan 7 at 21:29



















          0












          $begingroup$

          After the substitution $z = e^{ix}$, you should be getting the integral



          $$ int_{0}^{2pi}frac{cos^{2}x}{2-sin x},mathrm{d}x = int_{C}frac{(z^{2}+1)^{2}}{4z^{2}}frac{mathrm{d}z}{izleft(2-frac{1}{2i}(z-frac{1}{z})right)} = -frac{1}{2}int_{C}frac{(z^{2}+1)^{2}}{z^{2}(z^{2}-4iz-1)},mathrm{d}z.$$



          Since the original integral is clearly real, your residues need to be purely imaginary. If they are not, then something went wrong in the computation.






          share|cite|improve this answer











          $endgroup$














            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "69"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            noCode: true, onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3065348%2fsolving-integral-using-residues%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            1












            $begingroup$

            Let $tanfrac{u}{2}=x$.



            Thus, $$dx=frac{1}{2cos^2frac{u}{2}}du=frac{1}{2}(1+x^2)du,$$ which gives
            $$du=frac{2}{1+x^2}dx.$$
            Hence, $$intfrac{cos^2u}{2-sin{u}}du=intleft(2+sin{u}-frac{3}{2-sin{u}}right)du=$$
            $$=2u-cos{u}-3intfrac{1}{2-frac{2x}{1+x^2}}frac{2}{1+x^2}dx=$$
            $$=2u-cos{u}-3intfrac{1}{1-x+x^2}dx=2u-cos{u}-3intfrac{1}{left(x-frac{1}{2}right)^2+left(frac{sqrt3}{2}right)^2}dx=$$
            $$=2u-cos{u}-2sqrt3arctanfrac{2tanfrac{u}{2}-1}{sqrt3}+C.$$
            Can you end it now?






            share|cite|improve this answer









            $endgroup$













            • $begingroup$
              I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
              $endgroup$
              – user569579
              Jan 7 at 21:29
















            1












            $begingroup$

            Let $tanfrac{u}{2}=x$.



            Thus, $$dx=frac{1}{2cos^2frac{u}{2}}du=frac{1}{2}(1+x^2)du,$$ which gives
            $$du=frac{2}{1+x^2}dx.$$
            Hence, $$intfrac{cos^2u}{2-sin{u}}du=intleft(2+sin{u}-frac{3}{2-sin{u}}right)du=$$
            $$=2u-cos{u}-3intfrac{1}{2-frac{2x}{1+x^2}}frac{2}{1+x^2}dx=$$
            $$=2u-cos{u}-3intfrac{1}{1-x+x^2}dx=2u-cos{u}-3intfrac{1}{left(x-frac{1}{2}right)^2+left(frac{sqrt3}{2}right)^2}dx=$$
            $$=2u-cos{u}-2sqrt3arctanfrac{2tanfrac{u}{2}-1}{sqrt3}+C.$$
            Can you end it now?






            share|cite|improve this answer









            $endgroup$













            • $begingroup$
              I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
              $endgroup$
              – user569579
              Jan 7 at 21:29














            1












            1








            1





            $begingroup$

            Let $tanfrac{u}{2}=x$.



            Thus, $$dx=frac{1}{2cos^2frac{u}{2}}du=frac{1}{2}(1+x^2)du,$$ which gives
            $$du=frac{2}{1+x^2}dx.$$
            Hence, $$intfrac{cos^2u}{2-sin{u}}du=intleft(2+sin{u}-frac{3}{2-sin{u}}right)du=$$
            $$=2u-cos{u}-3intfrac{1}{2-frac{2x}{1+x^2}}frac{2}{1+x^2}dx=$$
            $$=2u-cos{u}-3intfrac{1}{1-x+x^2}dx=2u-cos{u}-3intfrac{1}{left(x-frac{1}{2}right)^2+left(frac{sqrt3}{2}right)^2}dx=$$
            $$=2u-cos{u}-2sqrt3arctanfrac{2tanfrac{u}{2}-1}{sqrt3}+C.$$
            Can you end it now?






            share|cite|improve this answer









            $endgroup$



            Let $tanfrac{u}{2}=x$.



            Thus, $$dx=frac{1}{2cos^2frac{u}{2}}du=frac{1}{2}(1+x^2)du,$$ which gives
            $$du=frac{2}{1+x^2}dx.$$
            Hence, $$intfrac{cos^2u}{2-sin{u}}du=intleft(2+sin{u}-frac{3}{2-sin{u}}right)du=$$
            $$=2u-cos{u}-3intfrac{1}{2-frac{2x}{1+x^2}}frac{2}{1+x^2}dx=$$
            $$=2u-cos{u}-3intfrac{1}{1-x+x^2}dx=2u-cos{u}-3intfrac{1}{left(x-frac{1}{2}right)^2+left(frac{sqrt3}{2}right)^2}dx=$$
            $$=2u-cos{u}-2sqrt3arctanfrac{2tanfrac{u}{2}-1}{sqrt3}+C.$$
            Can you end it now?







            share|cite|improve this answer












            share|cite|improve this answer



            share|cite|improve this answer










            answered Jan 7 at 21:19









            Michael RozenbergMichael Rozenberg

            111k1896201




            111k1896201












            • $begingroup$
              I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
              $endgroup$
              – user569579
              Jan 7 at 21:29


















            • $begingroup$
              I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
              $endgroup$
              – user569579
              Jan 7 at 21:29
















            $begingroup$
            I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
            $endgroup$
            – user569579
            Jan 7 at 21:29




            $begingroup$
            I probably could, but I am trying to solve this using the Residue Theorem. If I want to use that, is my approach correct? Either way, thank you for your help.
            $endgroup$
            – user569579
            Jan 7 at 21:29











            0












            $begingroup$

            After the substitution $z = e^{ix}$, you should be getting the integral



            $$ int_{0}^{2pi}frac{cos^{2}x}{2-sin x},mathrm{d}x = int_{C}frac{(z^{2}+1)^{2}}{4z^{2}}frac{mathrm{d}z}{izleft(2-frac{1}{2i}(z-frac{1}{z})right)} = -frac{1}{2}int_{C}frac{(z^{2}+1)^{2}}{z^{2}(z^{2}-4iz-1)},mathrm{d}z.$$



            Since the original integral is clearly real, your residues need to be purely imaginary. If they are not, then something went wrong in the computation.






            share|cite|improve this answer











            $endgroup$


















              0












              $begingroup$

              After the substitution $z = e^{ix}$, you should be getting the integral



              $$ int_{0}^{2pi}frac{cos^{2}x}{2-sin x},mathrm{d}x = int_{C}frac{(z^{2}+1)^{2}}{4z^{2}}frac{mathrm{d}z}{izleft(2-frac{1}{2i}(z-frac{1}{z})right)} = -frac{1}{2}int_{C}frac{(z^{2}+1)^{2}}{z^{2}(z^{2}-4iz-1)},mathrm{d}z.$$



              Since the original integral is clearly real, your residues need to be purely imaginary. If they are not, then something went wrong in the computation.






              share|cite|improve this answer











              $endgroup$
















                0












                0








                0





                $begingroup$

                After the substitution $z = e^{ix}$, you should be getting the integral



                $$ int_{0}^{2pi}frac{cos^{2}x}{2-sin x},mathrm{d}x = int_{C}frac{(z^{2}+1)^{2}}{4z^{2}}frac{mathrm{d}z}{izleft(2-frac{1}{2i}(z-frac{1}{z})right)} = -frac{1}{2}int_{C}frac{(z^{2}+1)^{2}}{z^{2}(z^{2}-4iz-1)},mathrm{d}z.$$



                Since the original integral is clearly real, your residues need to be purely imaginary. If they are not, then something went wrong in the computation.






                share|cite|improve this answer











                $endgroup$



                After the substitution $z = e^{ix}$, you should be getting the integral



                $$ int_{0}^{2pi}frac{cos^{2}x}{2-sin x},mathrm{d}x = int_{C}frac{(z^{2}+1)^{2}}{4z^{2}}frac{mathrm{d}z}{izleft(2-frac{1}{2i}(z-frac{1}{z})right)} = -frac{1}{2}int_{C}frac{(z^{2}+1)^{2}}{z^{2}(z^{2}-4iz-1)},mathrm{d}z.$$



                Since the original integral is clearly real, your residues need to be purely imaginary. If they are not, then something went wrong in the computation.







                share|cite|improve this answer














                share|cite|improve this answer



                share|cite|improve this answer








                edited Jan 9 at 13:36

























                answered Jan 9 at 5:54









                IninterrompueIninterrompue

                69019




                69019






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Mathematics Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    Use MathJax to format equations. MathJax reference.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3065348%2fsolving-integral-using-residues%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Wiesbaden

                    Marschland

                    Dieringhausen