CFD Online Discussion Forums

CFD Online Discussion Forums (
-   Main CFD Forum (
-   -   separating physics and numerics? (

Maxim Umansky February 17, 2004 14:54

separating physics and numerics?

I am thinking whether one can come up with a general CFD code that would use a variety of options for discretization for a variety of options for the physics equations. Something like a parser that would automatically interpret the physics equations according to the chosen discretization scheme, rather than using a hard-wired discretization scheme. Anyone heard of somebody trying anything like that? Thanks for any info or thoughts.


Hrvoje Jasak February 17, 2004 17:49

Re: separating physics and numerics?
Well, have a look at the FOAM web site ( the code is written (in C++) as a library of operators talking the language of partial differential equations. Each operator creates a matrix and the matrices are then summed up to create the final linear system on which a solver is called. There are examples on the web site and all top-level codes are shipped in full source. Typically, they will be a couple of hundred lines long, so there's no need to be scared :)

This approach allows you to pick-and-mix your physics any way you like. The discretisation is then controlled "per-operator" and "per-equation"; with some work you can even go from FVM (that's the work-horse) to the FEM (used for automatic mesh motion and such like).

If you need to know more, there are a couple of papers you can read:

Weller, H.G.; Tabor G.; Jasak, H. and Fureby, C.: A Tensorial Approach to CFD using Object Orientated Techniques, Computers in Physics, 1998 v 12 n 6, pp 620 - 631

Jasak, H.; Weller, H.G and Nordin, N.: In-Cylinder CFD Simulation Using a C++ Object-Oriented Toolkit, SAE World Congress, Detroit, 2004. The paper describes some parts of the FOAM design and includes example internal combustion engine simulations using FOAM.



Jim Park February 17, 2004 20:01

Re: separating physics and numerics?

Professor Jerry Baker at the University of Tennessee.

alex February 18, 2004 09:53

Re: separating physics and numerics?
or just check out their website at

All times are GMT -4. The time now is 17:24.