Re: integration
- To: mathgroup at smc.vnet.net
- Subject: [mg92848] Re: integration
- From: Gobithaasan <gobithaasan at gmail.com>
- Date: Wed, 15 Oct 2008 05:36:36 -0400 (EDT)
- References: <gcchbh$s2c$1@smc.vnet.net> <48EA5916.2050008@gmail.com> <48EA758D.7000502@gmail.com>
Greetings... Thanks Jean-Marc Gulliet, I think Mathematica 6 would be able to give a simplified answer, which is more understandable without the appearance of imaginary numbers in the answer. The assumption of the integral should be: [1]{k1,k2,r,s,S} are real numbers [2] r > -1 [3] S > 0 [4] 0<= s<= S I tried doing with these assumption, but the imaginary part still exists.. Is there anyway to ask Mathematica 6 to give the right assumption for imaginary-free answer? Thank you very much Jean... Gobithaasan Jean-Marc Gulliet wrote: > Jean-Marc Gulliet wrote: > >> RG wrote: >> >>> I have been trying to simplify(integrate) the following function, but >>> M6 seems to give a complex answer which i cann't understand.. please >>> help. >>> >>> x[s_]=\!\( >>> \*SubsuperscriptBox[\(\[Integral]\), \(0\), \(s\)]\(Cos[ >>> \*FractionBox[\(r\ t\ \((\(-\[Kappa]0\) + \[Kappa]1 + r\ \[Kappa]1)\) >>> + \((1 + r)\)\ S\ \((\[Kappa]0 - \[Kappa]1)\)\ \((\(-Log[S]\) + Log[S >>> + r\ t])\)\), >>> SuperscriptBox[\(r\), \(2\)]]] \[DifferentialD]t\)\) >> >> First, notice that if we use the *InputForm* of the above expression, >> we can easily add assumptions on the parameters of the integral (or >> we could use *Assuming*), for instance that S, r, and s are real and >> r != 0 or s > 0. >> >> However, it seems that the above integral has no solution if the >> parameter S is positive. On the other hand, ff we allow S to be >> negative (or complex) then the integral has a symbolic complex solution. >> >> In[49]:= Integrate[ >> Cos[(r*t*(-\[Kappa]0 + \[Kappa]1 + r*\[Kappa]1) + (1 + r)* >> S*(\[Kappa]0 - \[Kappa]1)* >> (-Log[S] + Log[S + r*t]))/r^2], {t, 0, s}, >> Assumptions -> S > 0] >> >> Out[49]= Integrate[ >> Cos[(r t (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1) + (1 + >> r) S (\[Kappa]0 - \[Kappa]1) (-Log[S] + Log[S + r t]))/r^2], {t, >> 0, s}, Assumptions -> S > 0] >> >> In[46]:= Integrate[ >> Cos[(r*t*(-\[Kappa]0 + \[Kappa]1 + r*\[Kappa]1) + (1 + r)* >> S*(\[Kappa]0 - \[Kappa]1)* >> (-Log[S] + Log[S + r*t]))/r^2], {t, 0, s}, >> Assumptions -> {Element[{S, r, s}, Reals], r != 0, s > 0}] >> >> Out[46]= If[r S > 0 || s + S/r <= 0, (1/( >> 2 (\[Kappa]0 - \[Kappa]1 - r \[Kappa]1))) >> r S^(-((I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2)) (r s + S)^(-(( >> >> [... output partially deleted ...] >> >> r^2)] Sin[(S \[Kappa]0)/r^2 - (S \[Kappa]1)/r^2 - ( >> S \[Kappa]1)/r]), >> Integrate[ >> Cos[(r t (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1) + (1 + >> r) S (\[Kappa]0 - \[Kappa]1) (-Log[S] + Log[S + r t]))/ >> r^2], {t, 0, s}, >> Assumptions -> >> r != 0 && s > 0 && r S <= 0 && r (r s + S) > 0 && >> S \[Element] Reals]] >> >> >> You can manipulate further the integral thanks to *FullSimplify* and >> some assumptions on the parameters. >> >> Assuming[r S > 0 || s + S/r <= 0, >> FullSimplify[ >> 1/(2 (\[Kappa]0 - \[Kappa]1 - r \[Kappa]1)) >> r S^(-((I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2)) (r s + S)^(-(( >> >> [... input partially deleted ...] >> >> S \[Kappa]1)/r])]] > > It took a long time, but the last expression returned the following > result (which is valid only for r S > 0 || s + S/r <= 0): > > (1/(2 r))E^(-((I S (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1))/ > r^2)) (S ExpIntegralE[-((I (1 + r) S (\[Kappa]0 - \[Kappa]1))/ > r^2), -((I S (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1))/r^2)] - > S^(-((I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2)) (r s + S)^( > 1 + (I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2) > ExpIntegralE[-((I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2), -(( > I (r s + S) (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1))/r^2)] + > E^((2 I S (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1))/ > r^2) (S ExpIntegralE[(I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2, ( > I S (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1))/r^2] - (S^3)^(( > I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2) (r s + S)^( > 1 - (I (1 + r) S (\[Kappa]0 - \[Kappa]1))/ > r^2) ((\[Kappa]0 - (1 + r) \[Kappa]1)^2)^(( > I (1 + r) S (\[Kappa]0 - \[Kappa]1))/ > r^2) (S^2 (r s + S)^2 (\[Kappa]0 - (1 + r) \[Kappa]1)^2)^(-(( > I (1 + r) S (\[Kappa]0 - \[Kappa]1))/ > r^2)) ((r s + S) (S + r Conjugate[s]))^(( > I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2) > ExpIntegralE[(I (1 + r) S (\[Kappa]0 - \[Kappa]1))/r^2, ( > I (r s + S) (-\[Kappa]0 + \[Kappa]1 + r \[Kappa]1))/r^2])) > > Regards, > -- Jean-Marc >