|
[Sponsors] |
October 1, 2015, 17:38 |
Creating solver without pressure corrections
|
#1 |
Member
Lisandro Maders
Join Date: Feb 2013
Posts: 98
Rep Power: 13 |
Hi,
I am trying to create a solver that solves only the following equations: 1) Continuity 2) Momentum 3) Generic transport equation of variable Z The fact is that my pressure field is constant, it almost does not vary. And also I take the density from a table based on Z values. So I do not need to make that pressure corrections that SIMPLE algorithm and others do. So how to proper write the .C solver file? Or if you can suggest me to take a look in some specific code that has this simplification it would be good as well. Regards, Lisandro |
|
October 1, 2015, 21:15 |
What I have done so far..
|
#2 |
Member
Lisandro Maders
Join Date: Feb 2013
Posts: 98
Rep Power: 13 |
Here is what I have done so far, but it is dividing by zero (at least I interpreted the error like this) somewhere in rhoEqn..
Code:
int main(int argc, char *argv[]) { #include "setRootCase.H" #include "createTime.H" #include "createMesh.H" #include "initFGM.H" #include "createFields.H" simpleControl simple(mesh); // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // #include "CourantNo.H" // #include "compressibleCourantNo.H" while (simple.loop()) { Info<< "Time = " << runTime.timeName() << nl << endl; while (simple.correctNonOrthogonal()) { Info << " Antes de rhoEqn.H " << endl; Info << " Escrevendo rho " << rho << endl; Info << " Escrevendo phi " << phi << endl; #include "rhoEqn.H" #include "UEqn.H" #include "pvEqn.H" #include "ztEqn.H" } if (runTime.write()) { #include "writeFGMfields.H" #include "writeThermoPropertyFields.H" } Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s" << " ClockTime = " << runTime.elapsedClockTime() << " s" << nl << endl; } Info<< "End\n" << endl; return 0; } |
|
October 7, 2015, 10:31 |
Still weird
|
#3 |
Member
Lisandro Maders
Join Date: Feb 2013
Posts: 98
Rep Power: 13 |
Jamamoto,
I interpreted your "like" as: that looks right! However, the results I am getting for velocity field are very weird, which tells me I missed something in this simplification. Could you or someone else give me some help on this? Is there any solver in OpenFOAM that does not make use of such simplification (no pressure/momentum corrections).. Thanks! |
|
Tags |
correction, momentum, pressure, simple, simplification |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Pressure equation for compressible solver | Akshay | OpenFOAM Programming & Development | 8 | October 3, 2015 10:22 |
Help! Divergence detected in AMG solver: pressure correction | user0314 | FLUENT | 3 | September 2, 2011 17:12 |
Using pressure based solver for compressible flows | aamer | Main CFD Forum | 2 | June 15, 2011 13:45 |
Creating New Solver: For particle-laden compressible jets | sankarv | OpenFOAM | 0 | April 4, 2010 19:06 |
Hydrostatic pressure in 2-phase flow modeling (long) | DS & HB | Main CFD Forum | 0 | January 8, 2000 16:00 |