CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

Big Difference between fvm:: and fvc::?

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By simrego

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 7, 2020, 13:32
Unhappy Big Difference between fvm:: and fvc::?
  #1
tmy
Member
 
Mingyuan Tao
Join Date: Mar 2016
Posts: 31
Rep Power: 10
tmy is on a distinguished road
Hi all,

I was trying to output the time change rate of one species. As I searched online, there exists two methods, either by using fvm:: or fvc::. However, I found big differences between these two methods. Which one is correct? Or more accurate? Please find the codes below:

DDT_[i].field() = (fvm::ddt(rho, Y[i])()).source();
DDTfvc_[i].field() = fvc::ddt(rho, Y[i]);

I also attached the values of DDT and DDTfvc of C7H16 at t=1e-6s. As you can see they have the difference with order of 2.

DDT_C7H16.txt

DDTfvc_C7H16.txt
tmy is offline   Reply With Quote

Old   January 11, 2020, 10:15
Default
  #2
Senior Member
 
anonymous
Join Date: Jan 2016
Posts: 416
Rep Power: 14
simrego is on a distinguished road
Hi!


fvm refers to finiteVolumeMethod or Matrix? not sure which one. But it will return an equation system for you since it is an implicit operator.
fvm is finiteVolumeCalculus. This is an explcit operator, which will do what you want.
So fvm will give you A*b=c. Actually it will give you the A matrix, and the c source vector, since b is the unknown, this is what we are looking for. when you use fvm(...).source, it should return the c vector from the equation system.
While fvc is the explicit operator, it will return a vector with the quantity you are interested in.


So shortly:
fvm: implicit, it will return the discretised equation system.

fvc: explicit operator, it will return the quantity.
atulkjoy likes this.
simrego is offline   Reply With Quote

Reply


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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
DIffrerence between fvm and fvc upuli OpenFOAM Programming & Development 2 July 16, 2018 15:37
fvmDdt, fvcDdt, fvm and fvc - differences gaza OpenFOAM Programming & Development 2 March 30, 2015 16:52
what is fvm and fvc musahossein OpenFOAM 1 September 26, 2013 22:39
Usage of fvm and fvc dl6tud OpenFOAM Programming & Development 1 July 27, 2012 18:28
Questions about the fvc and fvm starboy1985 OpenFOAM Programming & Development 0 August 2, 2011 15:52


All times are GMT -4. The time now is 22:48.