Nidalsb |
September 19, 2019 09:29 |
Boundary conditions - Pressure input ONLY
Hi,
I am using an inlet and an outlet pressure to try and solve an incompressible flow problem. I do not have any velocity or flow rate data.
The issue I am facing is that my solver always fails due to a high courant number no matter what solver I use. I tried Simple, Pimple and Piso.
Please let me know if you can find a mistake in my code below or feel free to suggest anything that would help.
PS: You can think of my problem as a box with a few internal walls directing the flow. xmin is the pressure inlet, xmax is the pressure outlet. the walls on the sides of the box are zmin. zmax, ymin, ymax and finally the internalwall is walls directing the flow in the interior of the box.
My P:
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 2 -2 0 0 0 0];
internalField uniform 0;
boundaryField
{
xmin
{
type totalPressure;
p0 uniform 130000;
value $internalField;
}
xmax
{
type totalPressure;
p0 uniform 100000;
value $internalField;
}
ymin
{
type zeroGradient;
}
ymax
{
type zeroGradient;
}
zmin
{
type zeroGradient;
}
zmax
{
type zeroGradient;
}
internalWall
{
type zeroGradient;
}
}
// ************************************************************************* //
My U:
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
object U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 1 -1 0 0 0 0];
internalField uniform (0 0 0);
boundaryField
{
xmin
{
type pressureInletVelocity;
value $internalField;
}
xmax
{
type pressureInletOutletVelocity;
value uniform (0 0 0);
}
ymin
{
type noSlip;
}
ymax
{
type noSlip;
}
zmin
{
type noSlip;
}
zmax
{
type noSlip;
}
internalWall
{
type noSlip;
}
}
// ************************************************************************* //
|