3
$\begingroup$

I am trying to evaluate the following integral, but Integrate just returns the input:

Integrate[2 E^(2 t) ExpIntegralEi[-2 t] Log[E^(-t)/t], {t, 0, x}]

enter image description here

Is it possible to find the analytic solution of this integral with Mathematica?

$\endgroup$
3
  • $\begingroup$ Mathematica simplify can't integrate it. So most likely this is not integarable. btw. Your e^(2t) should be Exp[2*t] You start with indefinite integration, then you see it can't solve it. No need to start with definite integration. It is because you have Exp[2*t] in front. If you remove this term, then it can do it. i.sstatic.net/9QiM5CGK.png $\endgroup$
    – Nasser
    Commented Oct 27 at 15:16
  • $\begingroup$ my function have to include the e^(2t) terms, then it should be not integrable? Now I have to use this integral function to calculate, but mathematica said that this integral function cannot be used as a function in the calculation, how can I fix it? $\endgroup$
    – miles
    Commented Oct 27 at 15:52
  • $\begingroup$ @Nasser Mathematica is able to compute certain definite integrals although it can not compute its indefinite variant. $\endgroup$ Commented Oct 27 at 16:09

2 Answers 2

9
$\begingroup$

Another way:

Integrate[
 2 E^(2 t) ExpIntegralEi[-2 t] Log[E^(-t)/t] // PowerExpand,
 {t, 0, x}, Assumptions -> x > 0]

enter image description here

$\endgroup$
9
  • $\begingroup$ Assumptions -> x > t > 0 makes no logical sense, it should be Assumptions -> x > 0. $\endgroup$ Commented Oct 27 at 16:18
  • $\begingroup$ Good trick with PowerExpand Will remove my answer using numerical integration as Mathematica can do it analytically. $\endgroup$
    – Nasser
    Commented Oct 27 at 16:20
  • 2
    $\begingroup$ @azerbajdzan You may find sometimes that x > t > 0 performs better than just x > 0. It may not make logical sense to you, but I have observed it to make a difference in what the internal code produces. And I have observed adding it does not always yield the simplification it should. Further, the edge cases change with each version update, naturally. It may be eventually in some version, it won't make a difference; but I think it should, since the path from 0 to x may be complex, even if x is real. I pass these remarks along as a trick one might try when x > 0 is insufficient. $\endgroup$
    – Michael E2
    Commented Oct 27 at 16:35
  • $\begingroup$ @MichaelE2 Do you have an example when x > 0 fails but x > t > 0 is successful? $\endgroup$ Commented Oct 27 at 17:41
  • 1
    $\begingroup$ @azerbajdzan Nope. Specific examples have not stuck in my memory and such edge cases have not come up very often. There may be some on site among the 750+ answers I've given that involve Integrate. Further, what made a difference in, say, V8 no longer made a difference perhaps in V10 or later. x > t > 0 is just a way to make available the assumption that the path of integration is real. The person who might know is Daniel Lichtblau. Maybe it has become part of the internal code, and over the next few years I will realize that it hasn't helped. Or not. $\endgroup$
    – Michael E2
    Commented Oct 27 at 18:00
5
$\begingroup$

Mathematica is able to evaluate it for small integers x=1, x=2, ...

By substituting such small integers for x you can guess the formula of the integral for general x.

int=(-(EulerGamma*(1 + 2*EulerGamma)) + 2*x - 
  8*x*HypergeometricPFQ[{1, 1, 1}, {2, 2, 2}, 2*x] - 
  2*Log[2]^2 - Log[4]*Log[x] - Log[2*x] - 
  E^(2*x)*ExpIntegralEi[-2*x]*(-1 + 2*x + Log[x^2]) + 
  ExpIntegralEi[2*x]*(2*EulerGamma + Log[4*x^2]) - 
  EulerGamma*Log[16*x^2] + 
  Derivative[2, 0, 0][Hypergeometric1F1][0, 1, 0] - 
  Derivative[2, 0, 0][Hypergeometric1F1][0, 1, 2*x])/2

Which can be verified by numeric integration.

NIntegrate[
 2 E^(2 t) ExpIntegralEi[-2 t] Log[E^-t/t], {t, 0, Pi + Sqrt[2]}]
N[int /. x -> Pi + Sqrt[2]]

1.69802

1.69802
$\endgroup$
2
  • $\begingroup$ It should be noted that your formula is valid only for $x>0$. $\endgroup$
    – Domen
    Commented Oct 27 at 16:11
  • 1
    $\begingroup$ I do not expect OP wants x<0 as he/she surely can confirm. $\endgroup$ Commented Oct 27 at 16:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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