How do I get the following into Mathematica, solving for $a$:
$$ 0.7 = 1 - \frac{2}{a} \times \left[ \frac{1}{a} \int_0^a \frac{x}{\exp(x)-1}\mathrm dx + \frac{a}{6} - 1\right] $$
Answer
In my experience FindRoot works best for such problems:
In[1]:= fun[a_?NumericQ] := NIntegrate[(x/(Exp[x] - 1)), {x, 0, a}]
In[2]:= FindRoot[1 - (2/a)*((1/a)*fun[a] + (a/6) - 1) == 0.7, {a, 0.1}]
Out[2]= {a -> 58.3073}
Comments
Post a Comment