On Mon, Sep 23, 2013 at 7:12 PM, Richard Edward Gillilan <[email protected]> wrote: > I want to solve the time-dependent convection-diffusion equation and am > testing my code on a simple 1D case. > > The flow field is a simple constant velocity. I've set D = 0, so no diffusion > should happen at all. > This system represents a little plug of high-concentration solute in a > solvent that should flow down the tube > without spreading. Problem is that I get lots of spreading even when I set > cell size and time-step very small. > > Can anyone see what I'm doing wrong?
Hi Richard, Sorry for taking so long to reply to this. It's a difficult problem but there is masses of literature on this problem. No scheme perfectly preserves the initial shape. The term you are using "PowerLawConvectionTerm" is only first order. A second order scheme will do better. Try the VanLeerConvectionTerm for a second order accurate scheme http://matforge.org/fipy/browser/fipy/fipy/terms/vanLeerConvectionTerm.py#L47 A lot of work uses even higher order schemes. Those aren't in FiPy. CLAWPACK may have some of those if you want to compare. Cheers -- Daniel Wheeler _______________________________________________ fipy mailing list [email protected] http://www.ctcms.nist.gov/fipy [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
