Message Boards Message Boards

Solving differential equation depending on radial and time parameter

Posted 14 days ago

Hi, I hope you are all doing well so I am trying to solve this differential equations which depends on radial and a time parameter to find the velocity, as an initial condition i took the value of the stationary condition which I solved separately. So when i tried to solve the final equations i got these errors which I don't know what causes it, is it the initial conditions or the method in which i want to solve it. So if any one of you have an idea it would help me a lot Thank you all in advance

POSTED BY: Leo Murphy
5 Replies

I don't understand what you are trying to do, but this gives a result:

rho = 1000;
\[CapitalDelta]P = 0.008;
L = 2;
R = 0.15;
n = 0.748;
\[Lambda] = 0.47;
\[Mu]0 = 20.05 10^-3;
Subscript[\[Mu], \[Infinity]] = 0;
\[Omega] = 0.1;
system[r_] := {D[
     r (\[Mu]0 (1 + (\[Lambda] D[v[r], {r, 1}])^2)^((n - 1)/2) D[
         v[r], {r, 1}]), {r, 1}] == -\[CapitalDelta]P/L r, v[R] == 0, 
   v'[10^-7] == 0};
rs = NDSolveValue[system[r], v, {r, 10^-7, R}, MaxSteps -> 10000];
valR = Range[10^-7, R, 3.061222449*10^-3];
valV = Map[rs, valR];
eqdiff[val_] := {r*(rho*
        D[u[r, t], {t, 1}] + ((-\[CapitalDelta]P/L*
          Cos[\[Omega]*t]))) == 
    D[r (\[Mu]0 (1 + (\[Lambda] D[u[r, t], {r, 1}])^2)^((n - 1)/2) D[
         u[r, t], {r, 1}]), {r, 1}], u[r, 0] == val, 
   u[R, t] == 0, (D[u[r, t], r] == 0) /. r -> 10^-7};
sol[val_] := NDSolveValue[eqdiff[val], u, {r, 10^-7, R}, {t, 0, 30}];
sol[valV[[1]]]
sol[valV[[2]]]
POSTED BY: Gianluca Gorni

You need one u solution for every value inside valV? You can make a Table where each entry has the NDSolve with u[r, 0] == valV[[n,1]].

POSTED BY: Gianluca Gorni
Posted 12 days ago

I tried doing a FIT with FindFit but I get the same error I dont know how I shoud extract the results of this first DE

POSTED BY: Updating Name

Your initial condition u[r, 0] == valV is a problem, because valV is a matrix.

POSTED BY: Gianluca Gorni
Posted 13 days ago

Yes that's what I thought, Do you have an ideaof how I can use it as normal data like a FIT for example

POSTED BY: Leo Murphy
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract