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

boudary conditions do not work

Register Blogs Community New Posts Updated Threads Search

Like Tree5Likes
  • 3 Post By RobertHB
  • 1 Post By SRKR
  • 1 Post By RobertHB

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 7, 2018, 14:28
Default boudary conditions do not work
  #1
New Member
 
Join Date: Aug 2018
Posts: 12
Rep Power: 7
salomama is on a distinguished road
Hello everyone;
i am trying to run for days this problem of an open test section of a wind tunnel and it is never working, i created my grids in pointwise and when it comes to setting my boudary conditions in openFoam i always get this continuity error

#Create mesh for time = 0


PISO: Operating solver in PISO mode

Reading transportProperties

Reading field p

Reading field U

Reading/calculating face flux field phi


Starting time loop

Time = 0.005

Courant Number mean: 0.0123967 max: 2.45
smoothSolver: Solving for Ux, Initial residual = 1, Final residual = 0.00116461, No Iterations 1000
smoothSolver: Solving for Uy, Initial residual = 0, Final residual = 0, No Iterations 0
DICPCG: Solving for p, Initial residual = 1, Final residual = 0.0405119, No Iterations 14
time step continuity errors : sum local = 0.00391647, global = -0.000631697, cumulative = -0.000631697
DICPCG: Solving for p, Initial residual = 0.00450157, Final residual = 8.79408e-07, No Iterations 30
time step continuity errors : sum local = 7.64836e-07, global = -4.35029e-08, cumulative = -0.000631741
ExecutionTime = 0.15 s ClockTime = 0 s

Time = 0.01

Courant Number mean: 0.382124 max: 25.3777
#0 Foam::error:rintStack(Foam::Ostream&) at ??:?
#1 Foam::sigFpe::sigHandler(int) at ??:?
#2 ? in "/lib64/libc.so.6"
#3 Foam::symGaussSeidelSmoother::smooth(Foam::word const&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::Field<double> const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, unsigned char, int) at ??:?
#4 Foam::symGaussSeidelSmoother::smooth(Foam::Field<d ouble>&, Foam::Field<double> const&, unsigned char, int) const at ??:?
#5 Foam::smoothSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:?
#6 ? at ??:?
#7 ? at ??:?
#8 ? at ??:?
#9 ? at ??:?
#10 __libc_start_main in "/lib64/libc.so.6"
#11 ? at ??:?
Floating point exception



this is my U file
#internalField uniform (0 0 0);

boundaryField
{
bd1
{
type symmetryPlane;
}
bd2
{
type symmetryPlane;
}
bottomendoftestsection
{
type fixedValue;
value uniform (0 0 0);
}
endofshearlayer
{
type fixedValue;
value uniform (0 0 0);
}
inlet
{
type fixedValue;
value uniform (30 0 0);
}
outlet
{
type inletOutlet;
value $internalField;
inletValue uniform (0 0 0);
}
outlet1
{
type fixedValue;
value uniform (0 0 0);
}
outsidebottom1
{
type fixedValue;
value uniform (0 0 0);
}
outsidebottom2
{
type fixedValue;
value uniform (0 0 0);
}
outsidebottom3
{
type fixedValue;
value uniform (0 0 0);
}
outsideleft
{
type fixedValue;
value uniform (0 0 0);
}
outsideright
{
type fixedValue;
value uniform (0 0 0);
}
outside1
{
type fixedValue;
value uniform (0 0 0);
}
outside2
{
type fixedValue;
value uniform (0 0 0);
}
shearlayer
{
type fixedValue;
value uniform (0 0 0);
}
walls
{
type noSlip;
}
BaseAndTop
{
type empty;
}
}

and P file
#dimensions [0 2 -2 0 0 0 0];

internalField uniform 0;

boundaryField
{
bd1
{
type symmetryPlane;
}
bd2
{
type symmetryPlane;
}
bottomendoftestsection
{
type totalPressure;
rho rho;
psi none;
gamma 1;
p0 uniform 0;
value uniform 0;
}
endofshearlayer
{
type totalPressure;
rho rho;
psi none;
gamma 1;
p0 uniform 0;
value uniform 0;
}
inlet
{
type fixedFluxPressure;
value uniform 0;
gradient uniform 0;
}
outlet
{
type totalPressure;
rho rho;
psi none;
gamma 1;
p0 uniform 0;
value uniform 0;
}
outlet1
{
type zeroGradient;
}
outsidebottom1
{
type zeroGradient;;
}
outsidebottom2
{
type zeroGradient;
}
outsidebottom3
{
type zeroGradient;
}
outsideleft
{
type zeroGradient;
}
outsideright
{
type zeroGradient;
}
outside1
{
type zeroGradient;
}
outside2
{
type zeroGradient;
}
shearlayer
{
type totalPressure;
rho rho;
psi none;
gamma 1;
p0 uniform 0;
value uniform 0;
}
walls
{
type zeroGradient;
}
BaseAndTop
{
type empty;
}
}

i have so many boudary conditions because i am trying to analyze the the flow of air that is going out from the open test section and see how far the shear layer goes. i put only half of the test section assuming that is symmetric seen from the top.
i can attach a picture of what i am working on.
salomama is offline   Reply With Quote

Old   August 8, 2018, 03:02
Default
  #2
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 11
RobertHB is on a distinguished road
Quote:
Originally Posted by salomama View Post
Starting time loop

Time = 0.005

Courant Number mean: 0.0123967 max: 2.45
[...]

Time = 0.01

Courant Number mean: 0.382124 max: 25.3777
#0 Foam::error:rintStack(Foam::Ostream&) at ??:?
#1 Foam::sigFpe::sigHandler(int) at ??:?
#2 ? in "/lib64/libc.so.6"
There's your problem, your Courant number is blowing up. Remember, to ensure numberical stability the Courant number should be below 1.0. If you think about how it is calculated
Co = \frac{u \cdot \Delta t}{\Delta x}
you can see that either your time step is too large OR your velocity to high OR your mesh size doesn't fit. Or a combination of those.
libi.macek, Jeneas and salomama like this.
__________________
If you liked my answer to your question, please consider leaving a "Like" in return
RobertHB is offline   Reply With Quote

Old   August 16, 2018, 12:53
Default not able to run icofoam because of to the time in controldict
  #3
New Member
 
Join Date: Aug 2018
Posts: 12
Rep Power: 7
salomama is on a distinguished road
Thank you RobertHB for your help.
i changed from working now from poitwise to openFoam completely starting with a simple design to get familiarized with OpenFoam, so this is my new Block Mesh;


vertices
(
(0 0 0)
(1.5 0 0)
(0 0.3 0)
(1.5 0.3 0)//3
(0 0.6 0) //4
(1.5 0.6 0)
(0 0 0.1) //6
(1.5 0 0.1)
(0 0.3 0.1) //8
(1.5 0.3 0.1) //9
(0 0.6 0.1)
(1.5 0.6 0.1) //11
);

blocks
(
hex (0 1 3 2 6 7 9 8) (20 20 1) simpleGrading (1 1 1)
hex (2 3 5 4 8 9 11 10) (20 20 1) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
farfield
{
type patch;
faces
(
(4 10 11 5)
);
}
inlet
{
type patch;
faces
(
(2 8 10 4)
);
}
outlet
{
type patch;
faces
(
(3 5 11 9)
);
}
symmetry
{
type symmetryPlane;
faces
(
(0 1 7 6)
);
}
rightside
{
type patch;
faces
(
(0 6 8 2)
);
}
leftside
{
type patch;
faces
(
(1 3 9 7)
);
}
frontAndBack
{
type empty;
faces
(
(2 4 5 3)
(0 2 3 1)
(6 7 9 8)
(8 9 11 10)
);
}
);

mergePatchPairs
(
);






my problem now is that when i run icoFoam with this ControlDict it start calculating time but it stops at at certain time, i tried to calculate the courant number before but im still confused how to choose the right delta time and interval if i want the end time to be enough to see the end of what happens in the animation using paraFoam. is there another formula that gives the time steps that show up in paraFoam? or a formula between the interval and delta T? besides the courant number because i tried different times and icoFoam stops.



application icoFoam;

startFrom startTime;

startTime 0;

stopAt endTime;

endTime 0.05;

deltaT 0.000005;

writeControl timeStep;

writeInterval 10;

purgeWrite 0;

writeFormat ascii;

writePrecision 6;

writeCompression off;

timeFormat general;

timePrecision 6;

runTimeModifiable true;







Time = 0.00961

Courant Number mean: 0.128956 max: 1.45861
smoothSolver: Solving for Ux, Initial residual = 0.0223022, Final residual = 9.80215e-06, No Iterations 27
smoothSolver: Solving for Uy, Initial residual = 0.0227496, Final residual = 9.78112e-06, No Iterations 37
DICPCG: Solving for p, Initial residual = 0.0611888, Final residual = 0.00213952, No Iterations 4
time step continuity errors : sum local = 4.34267e-05, global = -1.04824e-05, cumulative = -0.000153279
DICPCG: Solving for p, Initial residual = 0.0140375, Final residual = 9.42045e-07, No Iterations 33
time step continuity errors : sum local = 1.98796e-08, global = -6.87078e-10, cumulative = -0.00015328
ExecutionTime = 4.63 s ClockTime = 7 s

Time = 0.009615

Courant Number mean: 0.136936 max: 1.51927
smoothSolver: Solving for Ux, Initial residual = 0.0243793, Final residual = 3.00823e+06, No Iterations 1000
smoothSolver: Solving for Uy, Initial residual = 0.0260771, Final residual = 2.41502e+07, No Iterations 1000
DICPCG: Solving for p, Initial residual = 1, Final residual = 0.0472285, No Iterations 23
time step continuity errors : sum local = 56726.1, global = 800.186, cumulative = 800.186
DICPCG: Solving for p, Initial residual = 0.222503, Final residual = 4.24965e-07, No Iterations 38
time step continuity errors : sum local = 4.94998, global = -0.0741813, cumulative = 800.112
ExecutionTime = 4.7 s ClockTime = 7 s

Time = 0.00962

Courant Number mean: 1.35673e+07 max: 6.22719e+08
#0 Foam::error:rintStack(Foam::Ostream&) at ??:?
#1 Foam::sigFpe::sigHandler(int) at ??:?
#2 ? in "/lib/x86_64-linux-gnu/libc.so.6"
#3 Foam::symGaussSeidelSmoother::smooth(Foam::word const&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::Field<double> const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, unsigned char, int) at ??:?
#4 Foam::symGaussSeidelSmoother::smooth(Foam::Field<d ouble>&, Foam::Field<double> const&, unsigned char, int) const at ??:?
#5 Foam::smoothSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:?
#6 ? at ??:?
#7 ? at ??:?
#8 ? at ??:?
#9 ? at ??:?
#10 __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#11 ? at ??:?
Floating point exception (core dumped)


thank you for your help.
salomama is offline   Reply With Quote

Old   August 16, 2018, 14:12
Default
  #4
New Member
 
Join Date: Aug 2018
Posts: 12
Rep Power: 7
salomama is on a distinguished road
Also does the time setting in controldict depends on my entries in 0 file, pressure and velocity? because sometimes it runs and i don t get my results so i change the inputs of my outlets and it gives me an error of divergence even though usng the same time steps of last run... i am so confused! i will appreciate your help.
salomama is offline   Reply With Quote

Old   August 17, 2018, 02:16
Default
  #5
New Member
 
Srikar Reddy Palla
Join Date: May 2018
Posts: 19
Rep Power: 7
SRKR is on a distinguished road
Try to decrease the 'deltaT', with info you gave... that should clear your problem.
salomama likes this.
SRKR is offline   Reply With Quote

Old   August 17, 2018, 04:30
Default
  #6
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 11
RobertHB is on a distinguished road
Usually your velocity and mesh size are they way you need them, so to combat the Co number, you can only change the time step.
Your simulation runs from startTime to endTime and your variables are calculated every deltaT, the timestep.
How often your simulation writes data to a folder is deterimed by writeControl and writeInterval. At the moment every 10th timestep = every 5e-5 sec.
You could change this to writeControl runTime; writeInterval xxx; to get data every xxx seconds.
Since your simulation blows up so suddenly, i'd guess its more a problem of your mesh than of your timestep. Eventhough thats still to large (Co_max > 1).
salomama likes this.
__________________
If you liked my answer to your question, please consider leaving a "Like" in return
RobertHB is offline   Reply With Quote

Reply

Tags
#boudary #conditions


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
nonreflective boudary conditions mfinke CFX 8 December 20, 2013 17:19
Water subcooled boiling Attesz CFX 7 January 5, 2013 03:32
HELP,how to define the periodic boudary conditions using the icem mesh? dada1204 FLUENT 2 May 1, 2012 17:06
boudary conditions for flow past a sphere srijit goswami Main CFD Forum 3 January 27, 2001 07:28
A problem about setting boundary conditions lyang Main CFD Forum 0 September 19, 1999 18:29


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