On Wed, Jan 25, 2012 at 8:10 AM, John Newman <[email protected]> wrote:
> Hello, > > for a PDE of this type du/dt + (A-B*x)*du/dx = 0 , where variable u(x) > describes > some probability distribution (i.e. must be > 0) what is the proper > numerical > scheme to integrate it? Don't know exactly. I would say that a basic upwind scheme with a second order limiter would be a good place to start. Try it with the VanLeerConvectionTerm < http://matforge.org/fipy/browser/trunk/fipy/terms/vanLeerConvectionTerm.py>. > When I set u to normal distribution and let the system > evolve, soon I get u(x) < 0 for some x. I need Lax-like method > (http://www.cmth.ph.ic.ac.uk/people/a.mackinnon/Lectures/cp3/node29.html). > Is > this available in FiPy? > It is second order accurate, but also dispersive. We don't have any Lax based methods in FiPy. You might be able to implement one by using a staggered grid system in 1D just to test it. Actually, for 1D explicit, it would be easy to do just with numpy alone. No need for FiPy. -- Daniel Wheeler
_______________________________________________ fipy mailing list [email protected] http://www.ctcms.nist.gov/fipy [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
