2
$\begingroup$

I am a beginner in Mathematica. I tried to evaluate this integral, but was unable to do so. Can anybody help me evaluate this integral in Mathematica? Here is my integral: $$\int_{a}^{b} \frac{dx}{G(x)}\sum\limits_{n=0}^{\infty}\Big{[}\frac{1+x}{n-x}\Big{]}e^{-\beta E_{n}(x)}$$ where $G(x)=\sum\limits_{n=0}^{\infty}e^{-\beta E_{n}(x)}$ and $E_{n}(x)=-nx$ and $\beta$ is a constant.

$\endgroup$
  • 1
    $\begingroup$ Can you provide the code you used? $\endgroup$ – thils Oct 31 '15 at 10:41
  • 2
    $\begingroup$ Do you know how to sum a geometric series? $\endgroup$ – J. M. will be back soon Oct 31 '15 at 10:48
1
$\begingroup$

Edited to correct error noted by José Antonio Díaz Navas in the comment below.

As noted by J.M., the series can be summed explicitly.

g = Sum[Exp[β n x], {n, 0, Infinity}]
(* -(1/(-1 + E^(x β))) *)
h = Sum[Exp[β n x] (1 + x)/(n - x), {n, 0, Infinity}]
(* HurwitzLerchPhi[E^(x β), 1, -x] + x HurwitzLerchPhi[E^(x β), 1, -x] *)

Repeating these summations with GenerateConditions -> True indicates that E^Re[x β] < 1 is needed for convergence. In addition, it is necessary to avoid integer values of x, as can be seen from

Plot[Evaluate[(h/g) /. β -> -1], {x, 0, 4}, PlotRange -> {-3, 1}, PlotPoints -> 1000, 
  AxesLabel -> Automatic, LabelStyle -> Directive[Bold, Black, Medium], ImageSize -> Large]

enter image description here

Even with these constraints, attempting to solve the integral by, for instance,

Integrate[h/g, {x, a, b}, Assumptions -> β a < 0 && β b < 0 && 1 < x < 2]

returns unevaluated. To make progress, choose values for the constants and use NIntegrate. For instance,

NIntegrate[h/g /. β -> -1, {x, 1.0001, 1.9999}]
(* -4.96337 *)
$\endgroup$
  • 2
    $\begingroup$ Is not the integrand $h/g$ ? $\endgroup$ – José Antonio Díaz Navas Nov 6 '17 at 9:59
  • $\begingroup$ @JoséAntonioDíazNavas indeed it is. And perhaps even if the two series are divergent, maybe their ratio is finite? $\endgroup$ – LLlAMnYP Nov 6 '17 at 11:11
  • $\begingroup$ @JoséAntonioDíazNavas Thanks you for identifying my error, which I have corrected. $\endgroup$ – bbgodfrey Nov 6 '17 at 23:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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