9.0
general documentation
Loading...
Searching...
No Matches
cs_time_step.cpp File Reference
#include "base/cs_defs.h"
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "bft/bft_mem.h"
#include "bft/bft_error.h"
#include "bft/bft_printf.h"
#include "base/cs_base.h"
#include "base/cs_log.h"
#include "base/cs_map.h"
#include "base/cs_parall.h"
#include "base/cs_time_step.h"
Include dependency graph for cs_time_step.cpp:

Functions

cs_time_step_tcs_get_glob_time_step (void)
 Provide read/write access to cs_glob_time_step.
cs_time_step_options_tcs_get_glob_time_step_options (void)
 Provide read/write access to cs_glob_time_step_options.
void cs_time_step_define_variable (int is_variable)
 Define whether time step is variable or not.
void cs_time_step_define_local (int is_local)
 Define whether time step is local in space or not.
void cs_time_step_define_nt_max (int nt_max)
 Define maximum time step number.
void cs_time_step_define_t_max (double t_max)
 Define maximum time value.
void cs_time_step_define_prev (int nt_prev, double t_prev)
 Set time values from previous (usually restarted) calculations.
void cs_time_step_increment (double dt)
 Increment the global time step.
void cs_time_step_update_dt (double dt)
 Update global time step value for a time step in progress.
void cs_time_step_redefine_cur (int nt_cur, double t_cur)
 Redefine the current time values.
void cs_time_step_log_setup (void)
 Print the time stepping options to setup.log.

Detailed Description

base time step data.

Function Documentation

◆ cs_get_glob_time_step()

cs_time_step_t * cs_get_glob_time_step ( void )

Provide read/write access to cs_glob_time_step.

Returns
pointer to global time step structure

◆ cs_get_glob_time_step_options()

cs_time_step_options_t * cs_get_glob_time_step_options ( void )

Provide read/write access to cs_glob_time_step_options.

Returns
pointer to global time step options structure

◆ cs_time_step_define_local()

void cs_time_step_define_local ( int is_local)

Define whether time step is local in space or not.

Parameters
[in]is_local0 if time step is uniform in space, 1 if it is local

◆ cs_time_step_define_nt_max()

void cs_time_step_define_nt_max ( int nt_max)

Define maximum time step number.

Parameters
[in]nt_maxmaximum time step number (unlimited if negative)

◆ cs_time_step_define_prev()

void cs_time_step_define_prev ( int nt_prev,
double t_prev )

Set time values from previous (usually restarted) calculations.

Parameters
[in]nt_prevprevious time step number
[in]t_prevprevious physical time

◆ cs_time_step_define_t_max()

void cs_time_step_define_t_max ( double t_max)

Define maximum time value.

Parameters
[in]t_maxmaximum time value (unlimited if negative)

◆ cs_time_step_define_variable()

void cs_time_step_define_variable ( int is_variable)

Define whether time step is variable or not.

Parameters
[in]is_variable0 if time step is variable in time, 1 if it is fixed

◆ cs_time_step_increment()

void cs_time_step_increment ( double dt)

Increment the global time step.

Parameters
[in]dttime step value to increment

◆ cs_time_step_log_setup()

void cs_time_step_log_setup ( void )

Print the time stepping options to setup.log.

◆ cs_time_step_redefine_cur()

void cs_time_step_redefine_cur ( int nt_cur,
double t_cur )

Redefine the current time values.

Remarks
Using cs_time_step_increment is preferred, but this function may be required for reverting to a previous time step.
Parameters
[in]nt_curcurrent time step number
[in]t_curcurrent physical time

◆ cs_time_step_update_dt()

void cs_time_step_update_dt ( double dt)

Update global time step value for a time step in progress.

This is useful when using an adaptive time step, which is incremented earlier based on an estimated time step but needs to be updated.

Parameters
[in]dttime step value to update