Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #16154 > unrolled thread

Solve PDE system with 3 variables

Started byZharenkovDA@yandex.ru
First post2013-11-02 06:16 +0000
Last post2013-11-02 06:16 +0000
Articles 1 — 1 participant

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Solve PDE system with 3 variables ZharenkovDA@yandex.ru - 2013-11-02 06:16 +0000

#16154 — Solve PDE system with 3 variables

FromZharenkovDA@yandex.ru
Date2013-11-02 06:16 +0000
SubjectSolve PDE system with 3 variables
Message-ID<l525bb$9f5$1@smc.vnet.net>
Hello, I'm trying to solve the system of PDE's with piecewise IC functions. Each function depends of 3 variables.
With this code Mathematica throws 2 errors like this:

NDSolve::mxsst: Using maximum number of grid points 100 allowed by the MaxPoints or MinStepSize options for independent variable r.
 
In documentation I found that this error appears when there is a sharp feature in initial conditions. But I'm sure that there is no such features in them.


b = 1; 
 a = 1.01;
 mu = 1;
 r0 = 0.1;
 r01 = 0.3;
 r02 = 0.7;
 r1 = 1;
 foo1[r_?NumericQ] := 
  Piecewise[{{0, r < r0}, {(r - r0)/(r01 - r0), r0 <= r <= r01}, {1, 
    r01 < r < r02}, {(r - r1)/(r02 - r1), r02 <= r <= r1}, {0, 
    r > r1}}]


foo2[r_?NumericQ] := 
 Piecewise[{{1, r < r0}, {(r - r01)/(r0 - r01), r0 <= r <= r01}, {0, 
    r01 < r}}]


ftu = Table[{r, foo1[r]}, {r, 0, 1, 0.0025}];
ftv = ft = Table[{r, foo2[r]}, {r, 0, 1, 0.0025}];


initU = Interpolation[ftu];
initV = Interpolation[ftv];


w = NDSolve[{D[u[r, thet, t], t] == 
     D[u[r, thet, t], {r, 2}] + (1/r) D[u[r, thet, t], r] + (1/r^2) D[
        u[r, thet, t], {thet, 2}] + 
      u[r, thet, t] (1 - u[r, thet, t] - c*v[r, thet, t]),
    D[v[r, thet, t], t] == 
     mu*(D[v[r, thet, t], {r, 2}] + (1/r) D[v[r, thet, t], 
           r] + (1/r^2) D[v[r, thet, t], {thet, 2}]) + 
      a*v[r, thet, t] (1 - c*u[r, thet, t] - b*v[r, thet, t]),
    Derivative[1, 0, 0][u][1, thet, t] == 0, 
    Derivative[1, 0, 0][v][1, thet, t] == 0, 
    Derivative[1, 0, 0][u][0.01, thet, t] == 0, 
    Derivative[1, 0, 0][v][0.01, thet, t] == 0,
    (*D[u[r,thet,t],r]\[Equal]D[initU[r],r]/.{r\[Rule]1},
    D[v[r,thet,t],r]\[Equal]D[initV[r],r]/.{r\[Rule]1},
    D[u[r,thet,t],r]\[Equal]D[initU[r],r]/.{r\[Rule]0.01} ,
    D[v[r,thet,t],r]\[Equal]D[initV[r],r]/.{r\[Rule]0.01},*)
    
    u[r, 0, t] == u[r, 2 Pi, t],
    v[r, 0, t] == v[r, 2 Pi, t],
    u[r, thet, 0] == initU[r],
    v[r, thet, 0] == initV[r]},
   {u, v}, {t, 0, 1}, {thet, 0, 2 Pi}, {r, 0.01, 1}];

[toc] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web