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

Using PengRobinson eq with sonicFoam

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 24, 2017, 17:28
Default Using PengRobinsonGas equation with sonicFoam
  #1
Zon
New Member
 
Wellorzzon
Join Date: Mar 2017
Posts: 1
Rep Power: 0
Zon is on a distinguished road
Hello,

I am a Master's Degree student and I am working on a project that uses sonicFoam as a solver.

The cases I am simulating are basically a fluid in supersonic flow within an ejector. I used the type of cell "wedge" to simulate just one cell (1 of the total cylinder from the original ejector design) in the radial direction and refined the mesh in the longitudinal direction (x and y planes).
However, the cases are diverging, i.e., the Mass Flux Error between Inlet and Outlet is high, mainly when I increase the mesh refinement just in the longitudinal direction . I tried to use the PengRobinson equation but the solver restricted me to use just sensibleInternalEnergy as option to energy in the thermophysicalProperties, so I coudn't use polynomial and hPolynomial as option to transport and thermo, respectively.
Thinking on it, I recompiled the solver (based on rhoPimpleFoam) using the sensibleEnthalpy instead of sensibleInternalEnergy and used the PengRobinson equation, which gave me very good results. But I wanted to know:

Which aspects of the calculation those changes affects the simulated physics of the sonicFoam?



Notes: Changes in the sonicFoam are described below.

----------------------------------------------------------------------------------------
1. createFieldRefs.H
Commented the term "volScalarField& e = thermo.he();";

2. createFields.H
In the line "thermo.validate(args.executable(), "e");", the term "h" was added next to "e", resulting in "thermo.validate(args.executable(), "h", "e");";

3. EEqn.H
The terms "e" were replaced for "he";
Added a line after the "{" with the information "volScalarField& he = thermo.he();".
----------------------------------------------------------------------------------------

Thanks for helping me.

Last edited by Zon; July 31, 2017 at 16:51.
Zon is offline   Reply With Quote

Reply

Tags
pengrobinson, pengrobinsongas, rhopimplefoam, sensibleenthalpy, sonicfoam

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
energy in sonicFoam joern OpenFOAM Running, Solving & CFD 1 September 24, 2019 01:15
wallHeatFlux utility with sonicFoam hiuluom OpenFOAM Post-Processing 3 September 18, 2015 08:39
sonicFoam terminal error after mapping from consistent mesh Spaceprofessor OpenFOAM Running, Solving & CFD 0 May 14, 2013 05:54
Error trying to run steady-state sonicFoam dancfd OpenFOAM Running, Solving & CFD 2 February 12, 2013 04:15
Crash when using sonicFoam Horus OpenFOAM 1 June 16, 2010 13:57


All times are GMT -4. The time now is 06:57.