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

Vorticity calculation

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 19, 2024, 06:52
Default Vorticity calculation
  #1
Member
 
Divyaprakash
Join Date: Jun 2014
Posts: 71
Rep Power: 12
Divyaprakash is on a distinguished road
I need to calculate vorticity at every time-step since I need to use it for some other calculations. I will be doing that using


Code:
W = fvc::curl(U)

My query is about the locations of the generated field, W. Is it stored at the cell centers or at the cell face centers?
Divyaprakash is offline   Reply With Quote

Old   March 19, 2024, 11:37
Default
  #2
Member
 
Shravan
Join Date: Mar 2017
Posts: 73
Rep Power: 9
Severus is on a distinguished road
Hello,
To answer it in short, cell centres.

Two ways to find out
Method 1
Take a look at the vorticity functionObject.
https://www.openfoam.com/documentati...8H_source.html
https://www.openfoam.com/documentati...8C_source.html

See line 54 in vorticity.C. It kind of does what you want to do. Basically the same operation.
Now let us look at vorticity.H, see lines 49 and 51. You see that input (which is a velocity) is of the type volVectorField and the output (which is vorticity) is also of the type volVectorField. The data of the type volVectorField is stored in cell centres.

Method 2
Just print out your vorticity.
Code:
w.write()
Now, open the file w and see the number of values in internalField. This should be the same as the number of cell centres.

Thanks
Severus is offline   Reply With Quote

Reply

Tags
fvc, location, vorticity


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
Transfer output data as input for second calculation mannobot Main CFD Forum 3 December 7, 2018 10:37
Incompressible Navier-Stokes in Stream Function - Vorticity Formulation Daco Main CFD Forum 3 May 29, 2016 02:28
Defining output as input for second calculation mannobot FLUENT 1 June 2, 2010 05:20
vorticity boundary condition bearcharge Main CFD Forum 0 May 14, 2010 12:32
Vorticity Iso-Surface John Main CFD Forum 0 April 5, 2009 00:10


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