CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   Discretization (http://www.cfd-online.com/Forums/openfoam/92225-discretization.html)

mahdiiowa September 6, 2011 19:29

Discretization
 
Hi Guys

As you all may know, the form of the discretized momentum equation that have been used in OpenFOAM's icoFoam solver is based on the general Scalar Transport equation which has term "del.(U Phi)" and has been discretized in the following way

"fvm :: div(phi, U)"

My question is that how can I discretize it based on familar N.S. equation form which includes U.del(Phi).

I tried "U & (fvc::grad(phi))" but it produced the follwoing error

"no match for ‘operator&’ in ‘Foam::operator+(const Foam::tmp<Foam::fvMatrix<Type> >&, const Foam::DimensionedField<Type, Foam::volMesh>&)"

I would appriciate your commments.

chegdan September 7, 2011 17:30

Quote:

Originally Posted by mahdiiowa (Post 323204)
Hi Guys

As you all may know, the form of the discretized momentum equation that have been used in OpenFOAM's icoFoam solver is based on the general Scalar Transport equation which has term "del.(U Phi)" and has been discretized in the following way

"fvm :: div(phi, U)"

My question is that how can I discretize it based on familar N.S. equation form which includes U.del(Phi).

I tried "U & (fvc::grad(phi))" but it produced the follwoing error

"no match for ‘operator&’ in ‘Foam::operator+(const Foam::tmp<Foam::fvMatrix<Type> >&, const Foam::DimensionedField<Type, Foam::volMesh>&)"

I would appriciate your commments.

div(phi,U) is actually your div(UU) term in the NS equation. As you probably know already:

div(UU) = U & grad(U) + U*div(U)

for incompressible flow at a low residual...div(U) goes to zero and

div(UU) = U & grad(U)

so...div(UU) is considered the conservative form of the equation. hope this helps.

Dan

mahdiiowa September 7, 2011 17:56

Daniel
Thank you for your help.


All times are GMT -4. The time now is 00:19.