Re: Avoiding imaginary numbers in DSolve
- To: mathgroup at smc.vnet.net
- Subject: [mg38003] Re: [mg37977] Avoiding imaginary numbers in DSolve
- From: "Y.A.Tesiram" <yas at pcomm.hfi.unimelb.edu.au>
- Date: Mon, 25 Nov 2002 01:56:57 -0500 (EST)
- Sender: owner-wri-mathgroup at wolfram.com
Hi,
In[13]:= ?Re
Re[z] gives the real part of the complex number z.
So
In[12]:= Re[(FullSimplify[#1, M > 0 && r > 0] &
)[DSolve[(-Derivative[2][t][r])*r^2 +M*Derivative[1][t][r]^3 == 0, t[r],
r]]]
Yas
On Sat, 23 Nov 2002, Dave Snead wrote:
> I'm using DSolve to solve a differential equation, the result of which
> should be real but instead I get combinations
>
> of quantities involving the imaginary I (which I assume reduces to a real
> quantity). How do I get results that look
>
> real and avoid I? Thanks in advance.
>
>
>
> (FullSimplify[#1, M > 0 && r > 0] & )[
>
> DSolve[(-Derivative[2][t][r])*r^2 +
>
> M*Derivative[1][t][r]^3 == 0, t[r], r]]
>
>
>
> {{t[r] -> Sqrt[r*(M - r*C[1])]/(Sqrt[2]*C[1]) + C[2] -
>
> (I*M*Log[2*((-I)*Sqrt[2]*Sqrt[r*C[1]] +
>
> Sqrt[2*M - 2*r*C[1]])])/(Sqrt[2]*C[1]^(3/2))},
>
> {t[r] -> -(Sqrt[r*(M - r*C[1])]/(Sqrt[2]*C[1])) + C[2] +
>
> (I*M*Log[2*((-I)*Sqrt[2]*Sqrt[r*C[1]] +
>
> Sqrt[2*M - 2*r*C[1]])])/(Sqrt[2]*C[1]^(3/2))}}
>
>
>
>
>
>