Message Boards Message Boards


Question about grid refinement

Posted 2 months ago
2 Replies
0 Total Likes

Hi there! I'm new, so apologies if this is the wrong place to post this. I can't seem to improve the grid refinement when solving the following equation.

A = 8;
rmax = 20;
ti = 0;
tf = 80;
\[Omega] = 1/2;
\[Theta]fn = 
  NDSolveValue[{Derivative[0, 2][\[Theta]][r, t] - 
      Derivative[2, 0][\[Theta]][r, t] + \[Theta][r, t] + 
      NeumannValue[Derivative[0, 1][\[Theta]][r, t], r == rmax] == 
     0, \[Theta][0, t] == 0, \[Theta][r, ti] == 0, 
    Derivative[0, 1][\[Theta]][r, ti] == 
     r  A  Sech[r \[Omega]]}, \[Theta], {r, 0, rmax}, {t, ti, tf}];
 Plot[\[Theta]fn[r, t]/r, {r, 0, 20}, PlotRange -> {-1, 1}], {t, 0, 

Even if I use the option "MaxStepSize->0.001", the result is not improved. I suspect I'm missing something obvious, but any help is greatly appreciated!

2 Replies
Posted 2 months ago

Hi David,

Can you explain what you mean by "grid refinement"?

Dear Rohit,

Could you please have a look at your email.

Thank you very much.

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
or Discard

Group Abstract Group Abstract