CFD Online Logo CFD Online URL
Home > Forums > OpenFOAM Programming & Development

fvc::div() instead of fvc::flux()?

Register Blogs Members List Search Today's Posts Mark Forums Read

LinkBack Thread Tools Display Modes
Old   October 14, 2014, 07:55
Default fvc::div() instead of fvc::flux()?
New Member
Join Date: Sep 2014
Posts: 15
Rep Power: 5
Franko is on a distinguished road
Could anybody tell me, is there any difference between using these two solver's codes? Can I use the first code instead of the second code and vice versa? (Personally I think they have the same result):

So, the first code:
    surfaceScalarField phi ("phi", A);

    surfaceScalarField phiflux = fvc::flux(phi, B, "div(phi,B)");

     fvScalarMatrix sEqn
              fvm::ddt(s) + fvc::div(phiflux)
and the second code:

     surfaceScalarField phi ("phi", A);

     fvScalarMatrix sEqn
        fvm::ddt(s) + fvc::div(phi, B, "div(phi,B)")
Franko is offline   Reply With Quote

Old   December 23, 2014, 12:11
Senior Member
Dongyue Li
Join Date: Jun 2012
Location: Torino, Italy
Posts: 754
Rep Power: 10
sharonyue is on a distinguished road
The reason to use fvc::flux() MIGHT be to use flux limiter scheme. such as vanleer~
sharonyue is offline   Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
fvc::div for surfaceVectorField ARTem OpenFOAM Programming & Development 2 January 14, 2017 17:47
rho in fvc::flux santiagomarquezd OpenFOAM Running, Solving & CFD 0 February 29, 2012 14:31
flux limiter involving tensor : How to use fvc::flux() with volTensorField ? Cyp OpenFOAM Programming & Development 2 January 21, 2011 05:36
fvc::div() strange behaviour ivan_cozza OpenFOAM Running, Solving & CFD 2 February 6, 2010 07:09
What type return fvcdiv su_junwei OpenFOAM Running, Solving & CFD 6 October 13, 2008 07:09

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