CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Post-Processing

div function in the postProcess utility gives error

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 5, 2020, 03:13
Default div function in the postProcess utility gives error
  #1
Senior Member
 
Mojtaba.a's Avatar
 
Mojtaba Amiraslanpour
Join Date: Jun 2011
Location: Tampa, US
Posts: 308
Rep Power: 15
Mojtaba.a is on a distinguished road
Send a message via Skype™ to Mojtaba.a
Hello guys,

I was taking a look at the postProcess functionality and trying out the new div function to compute the divergence field of the velocity.

I did that quite well by adding the linear scheme to my fvSchemes file:

Code:
div(U)      Gauss linear;
However, when I try to use the upwind scheme:

Code:
div(U)      Gauss upwind;
I get the following error:

Code:
No finite volume options present
--> FOAM Warning :
--> FOAM FATAL IO ERROR:
wrong token type - expected word, found on line 39: label 1
Why is it unable to compute the divergence of U with this scheme (More broadly it cannot be computed by any other schemes except the linear ones)

Best.
__________________
Learn OpenFOAM in Persian
SFO (StarCCM+ FLUENT OpenFOAM) Project Team Member
Complex Heat & Flow Simulation Research Group
If you can't explain it simply, you don't understand it well enough. "Richard Feynman"
Mojtaba.a is offline   Reply With Quote

Old   April 5, 2020, 16:24
Default
  #2
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 932
Rep Power: 12
HPE is on a distinguished road
Could you please post a MWE, so that we can reproduce the error?
HPE is offline   Reply With Quote

Old   April 6, 2020, 16:26
Default
  #3
Senior Member
 
Mojtaba.a's Avatar
 
Mojtaba Amiraslanpour
Join Date: Jun 2011
Location: Tampa, US
Posts: 308
Rep Power: 15
Mojtaba.a is on a distinguished road
Send a message via Skype™ to Mojtaba.a
Quote:
Originally Posted by HPE View Post
Could you please post a MWE, so that we can reproduce the error?
Sure. You can download the attached case.

Reproduce the issue by running the following commands in OF 6:

Code:
pisoFoam
postProcess -func "div(U)"
It works fine. Now go to the fvSchemes file and change the div(U) scheme into

Code:
div(U)       Gauss upwind;
Also, you may notice a warning when running the div function where it says it can't find the surfaceScalarField of U. Again, I have no idea why it searches for the surfaceScalarField.
Attached Files
File Type: zip cavity.zip (25.4 KB, 2 views)
__________________
Learn OpenFOAM in Persian
SFO (StarCCM+ FLUENT OpenFOAM) Project Team Member
Complex Heat & Flow Simulation Research Group
If you can't explain it simply, you don't understand it well enough. "Richard Feynman"
Mojtaba.a is offline   Reply With Quote

Old   April 9, 2020, 12:48
Default
  #4
Senior Member
 
Mojtaba.a's Avatar
 
Mojtaba Amiraslanpour
Join Date: Jun 2011
Location: Tampa, US
Posts: 308
Rep Power: 15
Mojtaba.a is on a distinguished road
Send a message via Skype™ to Mojtaba.a
Any thoughts on this?
__________________
Learn OpenFOAM in Persian
SFO (StarCCM+ FLUENT OpenFOAM) Project Team Member
Complex Heat & Flow Simulation Research Group
If you can't explain it simply, you don't understand it well enough. "Richard Feynman"
Mojtaba.a is offline   Reply With Quote

Old   April 12, 2020, 06:53
Default
  #5
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 932
Rep Power: 12
HPE is on a distinguished road
after Easter
HPE 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
Building OpenFOAM1.7.0 from source ata OpenFOAM Installation 46 March 6, 2022 13:21
[swak4Foam] swak4foam openfoam 7 installation problem Andrea23 OpenFOAM Community Contributions 1 February 17, 2020 18:11
Mesquite - Adaptive mesh refinement / coarsening? philippose OpenFOAM Running, Solving & CFD 94 January 27, 2016 09:40
[OpenFOAM.org] Compile OF 2.3 on Mac OS X .... the patch gschaider OpenFOAM Installation 225 August 25, 2015 19:43
[swak4Foam] GroovyBC the dynamic cousin of funkySetFields that lives on the suburb of the mesh gschaider OpenFOAM Community Contributions 300 October 29, 2014 18:00


All times are GMT -4. The time now is 05:33.