Another difficult 2D trigonometric integral











up vote
8
down vote

favorite
1












This is a follow-up question to A difficult 2d trigonometric integral. Unfortunately, I had a mistake in my calculations and I need a different (yet similar) seemingly simple integral solved:



$$int_{a}^{b}int_{a}^{y}frac{sin(x-y)}{xy}mathop{mathrm{d}x}mathop{mathrm{d}y}$$



For some $0<a<b$. The same methods as before can not be applied here, and I've been sitting for hours trying to solve this. Solutions (also using $mathop{mathrm{Si}}$ & $mathop{mathrm{Ci}}$ functions) would be very-very-very appreciated.



Thanks!










share|cite|improve this question


























    up vote
    8
    down vote

    favorite
    1












    This is a follow-up question to A difficult 2d trigonometric integral. Unfortunately, I had a mistake in my calculations and I need a different (yet similar) seemingly simple integral solved:



    $$int_{a}^{b}int_{a}^{y}frac{sin(x-y)}{xy}mathop{mathrm{d}x}mathop{mathrm{d}y}$$



    For some $0<a<b$. The same methods as before can not be applied here, and I've been sitting for hours trying to solve this. Solutions (also using $mathop{mathrm{Si}}$ & $mathop{mathrm{Ci}}$ functions) would be very-very-very appreciated.



    Thanks!










    share|cite|improve this question
























      up vote
      8
      down vote

      favorite
      1









      up vote
      8
      down vote

      favorite
      1






      1





      This is a follow-up question to A difficult 2d trigonometric integral. Unfortunately, I had a mistake in my calculations and I need a different (yet similar) seemingly simple integral solved:



      $$int_{a}^{b}int_{a}^{y}frac{sin(x-y)}{xy}mathop{mathrm{d}x}mathop{mathrm{d}y}$$



      For some $0<a<b$. The same methods as before can not be applied here, and I've been sitting for hours trying to solve this. Solutions (also using $mathop{mathrm{Si}}$ & $mathop{mathrm{Ci}}$ functions) would be very-very-very appreciated.



      Thanks!










      share|cite|improve this question













      This is a follow-up question to A difficult 2d trigonometric integral. Unfortunately, I had a mistake in my calculations and I need a different (yet similar) seemingly simple integral solved:



      $$int_{a}^{b}int_{a}^{y}frac{sin(x-y)}{xy}mathop{mathrm{d}x}mathop{mathrm{d}y}$$



      For some $0<a<b$. The same methods as before can not be applied here, and I've been sitting for hours trying to solve this. Solutions (also using $mathop{mathrm{Si}}$ & $mathop{mathrm{Ci}}$ functions) would be very-very-very appreciated.



      Thanks!







      multivariable-calculus definite-integrals trigonometric-integrals






      share|cite|improve this question













      share|cite|improve this question











      share|cite|improve this question




      share|cite|improve this question










      asked Oct 10 at 21:36









      EZSlaver

      13911




      13911






















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          5
          down vote



          accepted
          +50










          First, use the identity $sin (x-y)=sin x cos y - cos x sin y$, and the sum rule to get $$int_a^bleft[int_a^yfrac{sin xcos y}{xy}mathrm{d}x-int_a^yfrac{cos xsin y}{xy} mathrm{d}x right]mathrm{d}y$$
          Pull out the constants and you get $$int_a^bleft[ frac{cos{y}}{y}int_a^yfrac{sin x}{x}mathrm{d}x-frac{sin y}{y}int_a^yfrac{cos x}{x}mathrm{d}x right]mathrm{d}y$$



          This simplifies to $$int_a^bleft[frac{cos y}{y}Bigr[mathrm{Si}(x)Bigr]_a^y-frac{sin y}{y}Bigr[mathrm{Ci}(x)Bigr]_a^yright]mathrm{d}y$$



          $$int_a^bleft[frac{cos y}{y}Bigr(mathrm{Si}(y)-mathrm{Si}(a)Bigr)-frac{sin y}{y}Bigr(mathrm{Ci}(y)-mathrm{Ci}(a)Bigr)right]mathrm{d}y$$



          $$int_a^bleft[frac{mathrm{Si}(y)cos y}{y}-frac{mathrm{Si}(a)cos y}{y}-frac{mathrm{Ci}(y)sin y}{y}+frac{mathrm{Ci}(a)sin y}{y}right]mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Si}(a)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+int_a^bfrac{mathrm{Ci}(a)sin y}{y}mathrm{d}y$$



          $mathrm{Si}(a)$ and $mathrm{Ci}(a)$ are constants, so they come out of their respective integrals, which further simplify. $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)int_a^bfrac{cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)int_a^bfrac{sin y}{y}mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)Bigr[mathrm{Ci}(y)Bigr]_a^b-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)Bigr[mathrm{Si}(y)Bigr]_a^b$$



          $$mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(a)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          Using integration by parts, we can transform $-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$ into the other integral. $$-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y = -Bigr[mathrm{Si}(y)mathrm{Ci}(y)Bigr]_a^b+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          Substituting, we get $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(b)mathrm{Ci}(b)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}$$



          Now, to the best of my knowledge, that integral has no elementary solution. After laboring over it, I finally ran it through Maxima, which uses the Risch Algorithm, and it got nothing as well. However, we can expand the sine integral as a convergent infinite series (source: [Wikipedia][1]), and then solve the integral from there. $$mathrm{Si}(y)=sum_{n=0}^inftyfrac{(-1)^ny^{2n+1}}{(2n+1)(2n+1)!}$$
          Substituting this in, we get $$2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y=sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y$$
          $$sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^b y^{2n}cos y,mathrm{d}y$$
          That integral is solvable, and can be found to be
          $$int_a^b y^{2n}cos y,mathrm{d}y=Bigr[-frac{1}{2}i^{2n+1}big[Gamma(2n+1,-ix)+(-1)^{2n}Gamma(2n+1,ix)big]Bigr]_a^b$$
          Plugging this in we get the final answer.
          $$-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          I have it worked out without the incomplete Gamma function as a double sum. If you want me to write out that solution as well, leave a comment.



          EDIT:
          Here's the solution involving infinite sums.
          Now, because n is discrete, I can describe the integral as an infinite sum. I solved the integrals for the cases $n = 0$, $n=1$, and $n=2$, and constructed the rule
          $$int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y=left[sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]_a^b$$
          $$sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin b}{mathrm{d}x^{q}}b^q-sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin a}{mathrm{d}x^{q}}a^q$$
          (I tested this for the case $n=3$, and it works fine). So, substituting this into the equation, we get
          $$sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$






          share|cite|improve this answer



















          • 1




            Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
            – EZSlaver
            Nov 25 at 12:18










          • No problem. I can type it up now.
            – Tesseract
            Nov 27 at 1:50











          Your Answer





          StackExchange.ifUsing("editor", function () {
          return StackExchange.using("mathjaxEditing", function () {
          StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
          StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
          });
          });
          }, "mathjax-editing");

          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',
          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%2f2950604%2fanother-difficult-2d-trigonometric-integral%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          5
          down vote



          accepted
          +50










          First, use the identity $sin (x-y)=sin x cos y - cos x sin y$, and the sum rule to get $$int_a^bleft[int_a^yfrac{sin xcos y}{xy}mathrm{d}x-int_a^yfrac{cos xsin y}{xy} mathrm{d}x right]mathrm{d}y$$
          Pull out the constants and you get $$int_a^bleft[ frac{cos{y}}{y}int_a^yfrac{sin x}{x}mathrm{d}x-frac{sin y}{y}int_a^yfrac{cos x}{x}mathrm{d}x right]mathrm{d}y$$



          This simplifies to $$int_a^bleft[frac{cos y}{y}Bigr[mathrm{Si}(x)Bigr]_a^y-frac{sin y}{y}Bigr[mathrm{Ci}(x)Bigr]_a^yright]mathrm{d}y$$



          $$int_a^bleft[frac{cos y}{y}Bigr(mathrm{Si}(y)-mathrm{Si}(a)Bigr)-frac{sin y}{y}Bigr(mathrm{Ci}(y)-mathrm{Ci}(a)Bigr)right]mathrm{d}y$$



          $$int_a^bleft[frac{mathrm{Si}(y)cos y}{y}-frac{mathrm{Si}(a)cos y}{y}-frac{mathrm{Ci}(y)sin y}{y}+frac{mathrm{Ci}(a)sin y}{y}right]mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Si}(a)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+int_a^bfrac{mathrm{Ci}(a)sin y}{y}mathrm{d}y$$



          $mathrm{Si}(a)$ and $mathrm{Ci}(a)$ are constants, so they come out of their respective integrals, which further simplify. $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)int_a^bfrac{cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)int_a^bfrac{sin y}{y}mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)Bigr[mathrm{Ci}(y)Bigr]_a^b-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)Bigr[mathrm{Si}(y)Bigr]_a^b$$



          $$mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(a)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          Using integration by parts, we can transform $-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$ into the other integral. $$-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y = -Bigr[mathrm{Si}(y)mathrm{Ci}(y)Bigr]_a^b+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          Substituting, we get $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(b)mathrm{Ci}(b)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}$$



          Now, to the best of my knowledge, that integral has no elementary solution. After laboring over it, I finally ran it through Maxima, which uses the Risch Algorithm, and it got nothing as well. However, we can expand the sine integral as a convergent infinite series (source: [Wikipedia][1]), and then solve the integral from there. $$mathrm{Si}(y)=sum_{n=0}^inftyfrac{(-1)^ny^{2n+1}}{(2n+1)(2n+1)!}$$
          Substituting this in, we get $$2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y=sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y$$
          $$sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^b y^{2n}cos y,mathrm{d}y$$
          That integral is solvable, and can be found to be
          $$int_a^b y^{2n}cos y,mathrm{d}y=Bigr[-frac{1}{2}i^{2n+1}big[Gamma(2n+1,-ix)+(-1)^{2n}Gamma(2n+1,ix)big]Bigr]_a^b$$
          Plugging this in we get the final answer.
          $$-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          I have it worked out without the incomplete Gamma function as a double sum. If you want me to write out that solution as well, leave a comment.



          EDIT:
          Here's the solution involving infinite sums.
          Now, because n is discrete, I can describe the integral as an infinite sum. I solved the integrals for the cases $n = 0$, $n=1$, and $n=2$, and constructed the rule
          $$int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y=left[sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]_a^b$$
          $$sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin b}{mathrm{d}x^{q}}b^q-sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin a}{mathrm{d}x^{q}}a^q$$
          (I tested this for the case $n=3$, and it works fine). So, substituting this into the equation, we get
          $$sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$






          share|cite|improve this answer



















          • 1




            Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
            – EZSlaver
            Nov 25 at 12:18










          • No problem. I can type it up now.
            – Tesseract
            Nov 27 at 1:50















          up vote
          5
          down vote



          accepted
          +50










          First, use the identity $sin (x-y)=sin x cos y - cos x sin y$, and the sum rule to get $$int_a^bleft[int_a^yfrac{sin xcos y}{xy}mathrm{d}x-int_a^yfrac{cos xsin y}{xy} mathrm{d}x right]mathrm{d}y$$
          Pull out the constants and you get $$int_a^bleft[ frac{cos{y}}{y}int_a^yfrac{sin x}{x}mathrm{d}x-frac{sin y}{y}int_a^yfrac{cos x}{x}mathrm{d}x right]mathrm{d}y$$



          This simplifies to $$int_a^bleft[frac{cos y}{y}Bigr[mathrm{Si}(x)Bigr]_a^y-frac{sin y}{y}Bigr[mathrm{Ci}(x)Bigr]_a^yright]mathrm{d}y$$



          $$int_a^bleft[frac{cos y}{y}Bigr(mathrm{Si}(y)-mathrm{Si}(a)Bigr)-frac{sin y}{y}Bigr(mathrm{Ci}(y)-mathrm{Ci}(a)Bigr)right]mathrm{d}y$$



          $$int_a^bleft[frac{mathrm{Si}(y)cos y}{y}-frac{mathrm{Si}(a)cos y}{y}-frac{mathrm{Ci}(y)sin y}{y}+frac{mathrm{Ci}(a)sin y}{y}right]mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Si}(a)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+int_a^bfrac{mathrm{Ci}(a)sin y}{y}mathrm{d}y$$



          $mathrm{Si}(a)$ and $mathrm{Ci}(a)$ are constants, so they come out of their respective integrals, which further simplify. $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)int_a^bfrac{cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)int_a^bfrac{sin y}{y}mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)Bigr[mathrm{Ci}(y)Bigr]_a^b-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)Bigr[mathrm{Si}(y)Bigr]_a^b$$



          $$mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(a)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          Using integration by parts, we can transform $-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$ into the other integral. $$-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y = -Bigr[mathrm{Si}(y)mathrm{Ci}(y)Bigr]_a^b+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          Substituting, we get $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(b)mathrm{Ci}(b)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}$$



          Now, to the best of my knowledge, that integral has no elementary solution. After laboring over it, I finally ran it through Maxima, which uses the Risch Algorithm, and it got nothing as well. However, we can expand the sine integral as a convergent infinite series (source: [Wikipedia][1]), and then solve the integral from there. $$mathrm{Si}(y)=sum_{n=0}^inftyfrac{(-1)^ny^{2n+1}}{(2n+1)(2n+1)!}$$
          Substituting this in, we get $$2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y=sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y$$
          $$sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^b y^{2n}cos y,mathrm{d}y$$
          That integral is solvable, and can be found to be
          $$int_a^b y^{2n}cos y,mathrm{d}y=Bigr[-frac{1}{2}i^{2n+1}big[Gamma(2n+1,-ix)+(-1)^{2n}Gamma(2n+1,ix)big]Bigr]_a^b$$
          Plugging this in we get the final answer.
          $$-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          I have it worked out without the incomplete Gamma function as a double sum. If you want me to write out that solution as well, leave a comment.



          EDIT:
          Here's the solution involving infinite sums.
          Now, because n is discrete, I can describe the integral as an infinite sum. I solved the integrals for the cases $n = 0$, $n=1$, and $n=2$, and constructed the rule
          $$int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y=left[sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]_a^b$$
          $$sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin b}{mathrm{d}x^{q}}b^q-sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin a}{mathrm{d}x^{q}}a^q$$
          (I tested this for the case $n=3$, and it works fine). So, substituting this into the equation, we get
          $$sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$






          share|cite|improve this answer



















          • 1




            Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
            – EZSlaver
            Nov 25 at 12:18










          • No problem. I can type it up now.
            – Tesseract
            Nov 27 at 1:50













          up vote
          5
          down vote



          accepted
          +50







          up vote
          5
          down vote



          accepted
          +50




          +50




          First, use the identity $sin (x-y)=sin x cos y - cos x sin y$, and the sum rule to get $$int_a^bleft[int_a^yfrac{sin xcos y}{xy}mathrm{d}x-int_a^yfrac{cos xsin y}{xy} mathrm{d}x right]mathrm{d}y$$
          Pull out the constants and you get $$int_a^bleft[ frac{cos{y}}{y}int_a^yfrac{sin x}{x}mathrm{d}x-frac{sin y}{y}int_a^yfrac{cos x}{x}mathrm{d}x right]mathrm{d}y$$



          This simplifies to $$int_a^bleft[frac{cos y}{y}Bigr[mathrm{Si}(x)Bigr]_a^y-frac{sin y}{y}Bigr[mathrm{Ci}(x)Bigr]_a^yright]mathrm{d}y$$



          $$int_a^bleft[frac{cos y}{y}Bigr(mathrm{Si}(y)-mathrm{Si}(a)Bigr)-frac{sin y}{y}Bigr(mathrm{Ci}(y)-mathrm{Ci}(a)Bigr)right]mathrm{d}y$$



          $$int_a^bleft[frac{mathrm{Si}(y)cos y}{y}-frac{mathrm{Si}(a)cos y}{y}-frac{mathrm{Ci}(y)sin y}{y}+frac{mathrm{Ci}(a)sin y}{y}right]mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Si}(a)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+int_a^bfrac{mathrm{Ci}(a)sin y}{y}mathrm{d}y$$



          $mathrm{Si}(a)$ and $mathrm{Ci}(a)$ are constants, so they come out of their respective integrals, which further simplify. $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)int_a^bfrac{cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)int_a^bfrac{sin y}{y}mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)Bigr[mathrm{Ci}(y)Bigr]_a^b-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)Bigr[mathrm{Si}(y)Bigr]_a^b$$



          $$mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(a)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          Using integration by parts, we can transform $-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$ into the other integral. $$-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y = -Bigr[mathrm{Si}(y)mathrm{Ci}(y)Bigr]_a^b+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          Substituting, we get $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(b)mathrm{Ci}(b)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}$$



          Now, to the best of my knowledge, that integral has no elementary solution. After laboring over it, I finally ran it through Maxima, which uses the Risch Algorithm, and it got nothing as well. However, we can expand the sine integral as a convergent infinite series (source: [Wikipedia][1]), and then solve the integral from there. $$mathrm{Si}(y)=sum_{n=0}^inftyfrac{(-1)^ny^{2n+1}}{(2n+1)(2n+1)!}$$
          Substituting this in, we get $$2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y=sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y$$
          $$sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^b y^{2n}cos y,mathrm{d}y$$
          That integral is solvable, and can be found to be
          $$int_a^b y^{2n}cos y,mathrm{d}y=Bigr[-frac{1}{2}i^{2n+1}big[Gamma(2n+1,-ix)+(-1)^{2n}Gamma(2n+1,ix)big]Bigr]_a^b$$
          Plugging this in we get the final answer.
          $$-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          I have it worked out without the incomplete Gamma function as a double sum. If you want me to write out that solution as well, leave a comment.



          EDIT:
          Here's the solution involving infinite sums.
          Now, because n is discrete, I can describe the integral as an infinite sum. I solved the integrals for the cases $n = 0$, $n=1$, and $n=2$, and constructed the rule
          $$int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y=left[sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]_a^b$$
          $$sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin b}{mathrm{d}x^{q}}b^q-sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin a}{mathrm{d}x^{q}}a^q$$
          (I tested this for the case $n=3$, and it works fine). So, substituting this into the equation, we get
          $$sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$






          share|cite|improve this answer














          First, use the identity $sin (x-y)=sin x cos y - cos x sin y$, and the sum rule to get $$int_a^bleft[int_a^yfrac{sin xcos y}{xy}mathrm{d}x-int_a^yfrac{cos xsin y}{xy} mathrm{d}x right]mathrm{d}y$$
          Pull out the constants and you get $$int_a^bleft[ frac{cos{y}}{y}int_a^yfrac{sin x}{x}mathrm{d}x-frac{sin y}{y}int_a^yfrac{cos x}{x}mathrm{d}x right]mathrm{d}y$$



          This simplifies to $$int_a^bleft[frac{cos y}{y}Bigr[mathrm{Si}(x)Bigr]_a^y-frac{sin y}{y}Bigr[mathrm{Ci}(x)Bigr]_a^yright]mathrm{d}y$$



          $$int_a^bleft[frac{cos y}{y}Bigr(mathrm{Si}(y)-mathrm{Si}(a)Bigr)-frac{sin y}{y}Bigr(mathrm{Ci}(y)-mathrm{Ci}(a)Bigr)right]mathrm{d}y$$



          $$int_a^bleft[frac{mathrm{Si}(y)cos y}{y}-frac{mathrm{Si}(a)cos y}{y}-frac{mathrm{Ci}(y)sin y}{y}+frac{mathrm{Ci}(a)sin y}{y}right]mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Si}(a)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+int_a^bfrac{mathrm{Ci}(a)sin y}{y}mathrm{d}y$$



          $mathrm{Si}(a)$ and $mathrm{Ci}(a)$ are constants, so they come out of their respective integrals, which further simplify. $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)int_a^bfrac{cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)int_a^bfrac{sin y}{y}mathrm{d}y$$



          $$int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-mathrm{Si}(a)Bigr[mathrm{Ci}(y)Bigr]_a^b-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y+mathrm{Ci}(a)Bigr[mathrm{Si}(y)Bigr]_a^b$$



          $$mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(a)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$$



          Using integration by parts, we can transform $-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y$ into the other integral. $$-int_a^bfrac{mathrm{Ci}(y)sin y}{y}mathrm{d}y = -Bigr[mathrm{Si}(y)mathrm{Ci}(y)Bigr]_a^b+int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          Substituting, we get $$mathrm{Si}(b)mathrm{Ci}(a)-mathrm{Si}(a)mathrm{Ci}(b)+mathrm{Si}(a)mathrm{Ci}(a)-mathrm{Si}(b)mathrm{Ci}(b)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y$$



          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2int_a^bfrac{mathrm{Si}(y)cos y}{y}$$



          Now, to the best of my knowledge, that integral has no elementary solution. After laboring over it, I finally ran it through Maxima, which uses the Risch Algorithm, and it got nothing as well. However, we can expand the sine integral as a convergent infinite series (source: [Wikipedia][1]), and then solve the integral from there. $$mathrm{Si}(y)=sum_{n=0}^inftyfrac{(-1)^ny^{2n+1}}{(2n+1)(2n+1)!}$$
          Substituting this in, we get $$2int_a^bfrac{mathrm{Si}(y)cos y}{y}mathrm{d}y=sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y$$
          $$sum_{n=0}^inftyfrac{2(-1)^n}{(2n+1)(2n+1)!}int_a^b y^{2n}cos y,mathrm{d}y$$
          That integral is solvable, and can be found to be
          $$int_a^b y^{2n}cos y,mathrm{d}y=Bigr[-frac{1}{2}i^{2n+1}big[Gamma(2n+1,-ix)+(-1)^{2n}Gamma(2n+1,ix)big]Bigr]_a^b$$
          Plugging this in we get the final answer.
          $$-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)-sum_{n=0}^inftyfrac{i^{4n+1}}{(2n+1)(2n+1)!}big[Gamma(2n+1,-ib)+(-1)^{2n}Gamma(2n+1,ib)-Gamma(2n+1,-ia)-(-1)^{2n}Gamma(2n+1,ia)big]$$
          I have it worked out without the incomplete Gamma function as a double sum. If you want me to write out that solution as well, leave a comment.



          EDIT:
          Here's the solution involving infinite sums.
          Now, because n is discrete, I can describe the integral as an infinite sum. I solved the integrals for the cases $n = 0$, $n=1$, and $n=2$, and constructed the rule
          $$int_a^bfrac{y^{2n-1}cos y}{y}mathrm{d}y=left[sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]_a^b$$
          $$sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin b}{mathrm{d}x^{q}}b^q-sum_{q=0}^{2n}(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin a}{mathrm{d}x^{q}}a^q$$
          (I tested this for the case $n=3$, and it works fine). So, substituting this into the equation, we get
          $$sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$
          $$big(mathrm{Si}(a)+mathrm{Si}(b)big)big(mathrm{Ci}(a)-mathrm{Ci}(b)big)+2sum_{n=0}^inftyleft[frac{2(-1)^n}{(2n+1)(2n+1)!}left[sum_{q=0}^{2n}left[(-1)^{q+1}frac{2n!}{q!}frac{mathrm{d}^{q}sin x}{mathrm{d}x^{q}}x^qright]right]_a^bright]$$







          share|cite|improve this answer














          share|cite|improve this answer



          share|cite|improve this answer








          edited Nov 27 at 3:19

























          answered Nov 23 at 1:50









          Tesseract

          21615




          21615








          • 1




            Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
            – EZSlaver
            Nov 25 at 12:18










          • No problem. I can type it up now.
            – Tesseract
            Nov 27 at 1:50














          • 1




            Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
            – EZSlaver
            Nov 25 at 12:18










          • No problem. I can type it up now.
            – Tesseract
            Nov 27 at 1:50








          1




          1




          Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
          – EZSlaver
          Nov 25 at 12:18




          Thank you. I award you with the bounty. I would appreciate if you also wrote the other solution as well.
          – EZSlaver
          Nov 25 at 12:18












          No problem. I can type it up now.
          – Tesseract
          Nov 27 at 1:50




          No problem. I can type it up now.
          – Tesseract
          Nov 27 at 1:50


















          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.





          Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


          Please pay close attention to the following guidance:


          • 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.


          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%2f2950604%2fanother-difficult-2d-trigonometric-integral%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

          AnyDesk - Fatal Program Failure

          How to calibrate 16:9 built-in touch-screen to a 4:3 resolution?

          QoS: MAC-Priority for clients behind a repeater