Re: diff equation
- To: mathgroup at smc.vnet.net
- Subject: [mg88333] Re: diff equation
- From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
- Date: Fri, 2 May 2008 03:42:12 -0400 (EDT)
- Organization: The Open University, Milton Keynes, UK
- References: <BLU129-DS335A7C6B4ED0F214741F6A8D90@phx.gbl> <4818FDAB.60005@gmail.com> <fvc5v1$9ks$1@smc.vnet.net>
Ali YILDIRIM wrote: > [resent a more readable form - moderator] > > Dear Math group.. > > I have an differential equation. I can not solve in mathematica. > Would you help me, please? > > dM/d t =D[d^2 M//dr^2 +(2/r) (dM/dr)]-kM -----------!!!----!!!! Not sure for what this D stands here. I discarded it in the example below. Also you have a spurious backslash. So you could write your equation as D[M[r, t], t] == D[M[r, t], r, r] + 2/r D[M[r, t], r] - k M[r, t] > Boundary conditions are: > > 1-) at t=0, M= Mo M[r, 0] == M0 > 2-) r = 0, dM/dr=0 D[M[0, t], t] == 0 > 3-) at r = R, M = Ms M[R, t] == Ms Then you can use DSolve or NDSolve as in DSolve[{D[M[r, t], t] == D[M[r, t], r, r] + 2/r D[M[r, t], r] - k M[r, t], M[r, 0] == M0, D[M[0, t], t] == 0, M[R, t] == Ms}, M, {r, t}] Regards, -- Jean-Marc