Hi all,

I am running the convection-box cookbook and I wish to have the run stop when it has reached steady state. I am actually interested in getting a reliable number of digits for the steady state vrms, heat flux, avrg T, etc … and since I wish to push it to Ra=1e6 and may be higher with higher and higher resolutions I do not want to set an arbitrary end time.

I am therefore trying to use the steady state Termination criterion as follows (which I copy-pasted and adapted from the box_steady_state_terminate.prm test):

subsection Termination criteria

set Termination criteria = steady state heat flux, steady state temperature, steady state velocity

subsection Steady state heat flux

set Maximum relative deviation = 1e-5

set Time in steady state = 0.1

set Boundary indicators = top,bottom

end

subsection Steady state temperature

set Maximum relative deviation = 1e-5

set Time in steady state = 0.1

end

subsection Steady state velocity

set Maximum relative deviation = 1e-5

set Time in steady state = 0.1

end

end

My problem is as follows: the run stops at time 0.1 no matter the relative deviation values that I input (1e-5 or 1e-11). By the way my end time is set at 0.5. This means that either I don’t understand what “Time in steady state” mean or there is a bug.

Looking at the manual, the definition for “Time in steady state” is “The minimum length of simulation time that the system should be in steady state before termination” which I interpret as the required time interval during which steady state has been reached according to the relative deviation. However, if my run stops at t=0.1, this would mean that it has been at steady state all along, which is nonsense.

Any idea/comment on what I am doing wrong?

Here is the entire prm file:

set Dimension = 2

set Use years in output instead of seconds = false

set End time = 0.5

set Output directory = output

set Pressure normalization = surface

set Surface pressure = 0

# Stop the model run when a steady state heat flux is reached.

# Some of the models do not reach steady state and will continue

# until the end time is reached.

subsection Termination criteria

set Termination criteria = steady state heat flux, steady state temperature, steady state velocity

subsection Steady state heat flux

set Maximum relative deviation = 1e-5

set Time in steady state = 0.1

set Boundary indicators = top,bottom

end

subsection Steady state temperature

set Maximum relative deviation = 1e-5

set Time in steady state = 0.1

end

subsection Steady state velocity

set Maximum relative deviation = 1e-5

set Time in steady state = 0.1

end

end

subsection Geometry model

set Model name = box

subsection Box

set X extent = 1

set Y extent = 1

end

end

subsection Initial temperature model

set Model name = function

subsection Function

set Variable names = x,z

set Function constants = p=0.01, L=1, pi=3.1415926536, k=1

set Function expression = (1.0-z) - p*cos(k*pi*x/L)*sin(pi*z)

end

end

subsection Boundary temperature model

set Fixed temperature boundary indicators = bottom, top

set List of model names = box

subsection Box

set Bottom temperature = 1

set Top temperature = 0

end

end

subsection Boundary velocity model

set Tangential velocity boundary indicators = left, right, bottom, top

end

subsection Gravity model

set Model name = vertical

subsection Vertical

set Magnitude = 1

end

end

subsection Material model

set Model name = simple

subsection Simple model

set Reference density = 20

set Reference specific heat = 0.01

set Reference temperature = 0

set Thermal conductivity = 1

set Thermal expansion coefficient = 2.5e-3

set Viscosity = 1e-7

end

end

subsection Formulation

set Formulation = custom

set Mass conservation = incompressible

set Temperature equation = reference density profile

end

subsection Heating model

set List of model names = shear heating, adiabatic heating

#subsection Adiabatic heating

# set Use simplified adiabatic heating = true

#end

end

subsection Mesh refinement

set Initial global refinement = 4

set Initial adaptive refinement = 0

set Time steps between mesh refinement = 0

end

subsection Postprocess

set List of postprocessors = velocity statistics, temperature statistics, heat flux statistics, visualization, depth average, viscous dissipation statistics, heating statistics

subsection Visualization

set List of output variables = density, viscosity, strain rate, heat flux map, artificial viscosity, strain rate tensor, vertical heat flux

set Time between graphical output = 0.05

subsection Heat flux map

set Output point wise heat flux = true

end

#set Interpolate output = true

end

subsection Depth average

set Number of zones = 127

set Time between graphical output = 0.05

set List of output variables = temperature, velocity magnitude, adiabatic density

end

end

subsection Solver parameters

set Temperature solver tolerance = 1e-10

end