Convect error: Fatal error in Convect (R2) operator: loop => velocity too high ? or NaN

Hi there;
I am trying to solve a 2D advection problem, where the “p1dc” velocity fields (u, v) are computed from an algorithm and then I apply:

MaxU=max(abs(u[ ].max),abs(v[ ].max));
timeStep=CourantNo*(Th.hmin)/(MaxU+0.001);
concstarNew=convect([u,v, -timeStep, concstar);

Yet I get the error after \textbf{some} time steps.

I am wondering what are the reasons? and how can I choose a time step that works?

Best
M

Generaly, due the discontinuity some characteristics can be lock between 2 element,

1 Like