TrioCFD 1.9.8
TrioCFD documentation
Loading...
Searching...
No Matches
Keywords derived from sch_cn_iteratif

sch_cn_iteratif

Inherits from: schema_temps_base

The Crank-Nicholson method of second order accuracy. A mid-point rule formulation is used (Euler-centered scheme). The basic scheme is: $$u(t+1) = u(t) + du/dt(t+1/2)*dt$$ The estimation of the time derivative du/dt at the level (t+1/2) is obtained either by iterative process. The time derivative du/dt at the level (t+1/2) is calculated iteratively with a simple under-relaxations method. Since the method is implicit, neither the cfl nor the fourier stability criteria must be respected. The time step is calculated in a way that the iterative procedure converges with the less iterations as possible.

Remark : for stationary or RANS calculations, no limitation can be given for time step through high value of facsec_max parameter (for instance : facsec_max 1000). In counterpart, for LES calculations, high values of facsec_max may engender numerical instabilities.

Parameters:

  • [seuil] (type: float) criteria for ending iterative process (Max( || u(p) - u(p-1)||/Max || u(p) ||) < seuil) (0.001 by default)
  • [niter_min] (type: int) minimal number of p-iterations to satisfy convergence criteria (2 by default)
  • [niter_max] (type: int) number of maximum p-iterations allowed to satisfy convergence criteria (6 by default)
  • [niter_avg] (type: int) threshold of p-iterations (3 by default). If the number of p-iterations is greater than niter_avg, facsec is reduced, if lesser than niter_avg, facsec is increased (but limited by the facsec_max value).
  • [facsec_max] (type: float) maximum ratio allowed between dynamical time step returned by iterative process and stability time returned by CFL condition (2 by default).
  • [tinit] (type: float) Value of initial calculation time (0 by default).
  • [tmax] (type: float) Time during which the calculation will be stopped (1e30s by default).
  • [tcpumax] (type: float) CPU time limit (must be specified in hours) for which the calculation is stopped (1e30s by default).
  • [dt_min] (type: float) Minimum calculation time step (1e-16s by default).
  • [dt_max] (type: string) Maximum calculation time step as function of time (1e30s by default).
  • [dt_sauv] (type: float) Save time step value (1e30s by default). Every dt_sauv, fields are saved in the .sauv file. The file contains all the information saved over time. If this instruction is not entered, results are saved only upon calculation completion. To disable the writing of the .sauv files, you must specify 0. Note that dt_sauv is in terms of physical time (not cpu time).
  • [nb_sauv_max] (type: int) Maximum number of timesteps that will be stored in backup file (10 by default). This value is only useful when doing a complete backup of the calculation with parallel PDI (as it needs to allocate the proper amount of dataspace in advance). If this number is reached (ie we already stored the data of nb_sauv_max timesteps in the file), the next checkpoints will overwrite the first ones
  • [dt_impr] (type: float) Scheme parameter printing time step in time (1e30s by default). The time steps and the flux balances are printed (incorporated onto every side of processed domains) into the .out file.
  • [facsec] (type: string) Value assigned to the safety factor for the time step (1. by default). It can also be a function of time. The time step calculated is multiplied by the safety factor. The first thing to try when a calculation does not converge with an explicit time scheme is to reduce the facsec to 0.5. Warning: Some schemes needs a facsec lower than 1 (0.5 is a good start), for example Schema_Adams_Bashforth_order_3.
  • [seuil_statio] (type: float) Value of the convergence threshold (1e-12 by default). Problems using this type of time scheme converge when the derivatives dGi/dt of all the unknown transported values Gi have a combined absolute value less than this value. This is the keyword used to set the permanent rating threshold.
  • [residuals] (type: residuals) To specify how the residuals will be computed (default max norm, possible to choose L2-norm instead).
  • [diffusion_implicite] (type: int) Keyword to make the diffusive term in the Navier-Stokes equations implicit (in this case, it should be set to 1). The stability time step is then only based on the convection time step (dt=facsec*dt_convection). Thus, in some circumstances, an important gain is achieved with respect to the time step (large diffusion with respect to convection on tightened meshes). Caution: It is however recommended that the user avoids exceeding the convection time step by selecting a too large facsec value. Start with a facsec value of 1 and then increase it gradually if you wish to accelerate calculation. In addition, for a natural convection calculation with a zero initial velocity, in the first time step, the convection time is infinite and therefore dt=facsec*dt_max.
  • [seuil_diffusion_implicite] (type: float) This keyword changes the default value (1e-6) of convergency criteria for the resolution by conjugate gradient used for implicit diffusion.
  • [impr_diffusion_implicite] (type: int) Unactivate (default) or not the printing of the convergence during the resolution of the conjugate gradient.
  • [impr_extremums] (type: int) Print unknowns extremas
  • [no_error_if_not_converged_diffusion_implicite] (type: int) not_set
  • [no_conv_subiteration_diffusion_implicite] (type: int) not_set
  • [dt_start] (type: dt_start) dt_start dt_min : the first iteration is based on dt_min. dt_start dt_calc : the time step at first iteration is calculated in agreement with CFL condition. dt_start dt_fixe value : the first time step is fixed by the user (recommended when resuming calculation with Crank Nicholson temporal scheme to ensure continuity). By default, the first iteration is based on dt_calc.
  • [nb_pas_dt_max] (type: int) Maximum number of calculation time steps (1e9 by default).
  • [niter_max_diffusion_implicite] (type: int) This keyword changes the default value (number of unknowns) of the maximal iterations number in the conjugate gradient method used for implicit diffusion.
  • [precision_impr] (type: int) Optional keyword to define the digit number for flux values printed into .out files (by default 3).
  • [periode_sauvegarde_securite_en_heures] (type: float) To change the default period (23 hours) between the save of the fields in .sauv file.
  • [no_check_disk_space] (type: flag) To disable the check of the available amount of disk space during the calculation.
  • [disable_progress] (type: flag) To disable the writing of the .progress file.
  • [disable_dt_ev] (type: flag) To disable the writing of the .dt_ev file.
  • [adapt_dt_tmax] (type: flag) Use to adapt final dt when approaching tmax.
  • [gnuplot_header] (type: int) Optional keyword to modify the header of the .out files. Allows to use the column title instead of columns number.

sch_cn_ex_iteratif

Inherits from: sch_cn_iteratif

This keyword also describes a Crank-Nicholson method of second order accuracy but here, for scalars, because of instablities encountered when dt>dt_CFL, the Crank Nicholson scheme is not applied to scalar quantities. Scalars are treated according to Euler- Explicite scheme at the end of the CN treatment for velocity flow fields (by doing p Euler explicite under-iterations at dt<=dt_CFL). Parameters are the sames (but default values may change) compare to the Sch_CN_iterative scheme plus a relaxation keyword: niter_min (2 by default), niter_max (6 by default), niter_avg (3 by default), facsec_max (20 by default), seuil (0.05 by default)

Parameters:

  • [omega] (type: float) relaxation factor (0.1 by default)
  • [seuil] (type: float) criteria for ending iterative process (Max( || u(p) - u(p-1)||/Max || u(p) ||) < seuil) (0.001 by default)
  • [niter_min] (type: int) minimal number of p-iterations to satisfy convergence criteria (2 by default)
  • [niter_max] (type: int) number of maximum p-iterations allowed to satisfy convergence criteria (6 by default)
  • [niter_avg] (type: int) threshold of p-iterations (3 by default). If the number of p-iterations is greater than niter_avg, facsec is reduced, if lesser than niter_avg, facsec is increased (but limited by the facsec_max value).
  • [facsec_max] (type: float) maximum ratio allowed between dynamical time step returned by iterative process and stability time returned by CFL condition (2 by default).
  • [tinit] (type: float) Value of initial calculation time (0 by default).
  • [tmax] (type: float) Time during which the calculation will be stopped (1e30s by default).
  • [tcpumax] (type: float) CPU time limit (must be specified in hours) for which the calculation is stopped (1e30s by default).
  • [dt_min] (type: float) Minimum calculation time step (1e-16s by default).
  • [dt_max] (type: string) Maximum calculation time step as function of time (1e30s by default).
  • [dt_sauv] (type: float) Save time step value (1e30s by default). Every dt_sauv, fields are saved in the .sauv file. The file contains all the information saved over time. If this instruction is not entered, results are saved only upon calculation completion. To disable the writing of the .sauv files, you must specify 0. Note that dt_sauv is in terms of physical time (not cpu time).
  • [nb_sauv_max] (type: int) Maximum number of timesteps that will be stored in backup file (10 by default). This value is only useful when doing a complete backup of the calculation with parallel PDI (as it needs to allocate the proper amount of dataspace in advance). If this number is reached (ie we already stored the data of nb_sauv_max timesteps in the file), the next checkpoints will overwrite the first ones
  • [dt_impr] (type: float) Scheme parameter printing time step in time (1e30s by default). The time steps and the flux balances are printed (incorporated onto every side of processed domains) into the .out file.
  • [facsec] (type: string) Value assigned to the safety factor for the time step (1. by default). It can also be a function of time. The time step calculated is multiplied by the safety factor. The first thing to try when a calculation does not converge with an explicit time scheme is to reduce the facsec to 0.5. Warning: Some schemes needs a facsec lower than 1 (0.5 is a good start), for example Schema_Adams_Bashforth_order_3.
  • [seuil_statio] (type: float) Value of the convergence threshold (1e-12 by default). Problems using this type of time scheme converge when the derivatives dGi/dt of all the unknown transported values Gi have a combined absolute value less than this value. This is the keyword used to set the permanent rating threshold.
  • [residuals] (type: residuals) To specify how the residuals will be computed (default max norm, possible to choose L2-norm instead).
  • [diffusion_implicite] (type: int) Keyword to make the diffusive term in the Navier-Stokes equations implicit (in this case, it should be set to 1). The stability time step is then only based on the convection time step (dt=facsec*dt_convection). Thus, in some circumstances, an important gain is achieved with respect to the time step (large diffusion with respect to convection on tightened meshes). Caution: It is however recommended that the user avoids exceeding the convection time step by selecting a too large facsec value. Start with a facsec value of 1 and then increase it gradually if you wish to accelerate calculation. In addition, for a natural convection calculation with a zero initial velocity, in the first time step, the convection time is infinite and therefore dt=facsec*dt_max.
  • [seuil_diffusion_implicite] (type: float) This keyword changes the default value (1e-6) of convergency criteria for the resolution by conjugate gradient used for implicit diffusion.
  • [impr_diffusion_implicite] (type: int) Unactivate (default) or not the printing of the convergence during the resolution of the conjugate gradient.
  • [impr_extremums] (type: int) Print unknowns extremas
  • [no_error_if_not_converged_diffusion_implicite] (type: int) not_set
  • [no_conv_subiteration_diffusion_implicite] (type: int) not_set
  • [dt_start] (type: dt_start) dt_start dt_min : the first iteration is based on dt_min. dt_start dt_calc : the time step at first iteration is calculated in agreement with CFL condition. dt_start dt_fixe value : the first time step is fixed by the user (recommended when resuming calculation with Crank Nicholson temporal scheme to ensure continuity). By default, the first iteration is based on dt_calc.
  • [nb_pas_dt_max] (type: int) Maximum number of calculation time steps (1e9 by default).
  • [niter_max_diffusion_implicite] (type: int) This keyword changes the default value (number of unknowns) of the maximal iterations number in the conjugate gradient method used for implicit diffusion.
  • [precision_impr] (type: int) Optional keyword to define the digit number for flux values printed into .out files (by default 3).
  • [periode_sauvegarde_securite_en_heures] (type: float) To change the default period (23 hours) between the save of the fields in .sauv file.
  • [no_check_disk_space] (type: flag) To disable the check of the available amount of disk space during the calculation.
  • [disable_progress] (type: flag) To disable the writing of the .progress file.
  • [disable_dt_ev] (type: flag) To disable the writing of the .dt_ev file.
  • [adapt_dt_tmax] (type: flag) Use to adapt final dt when approaching tmax.
  • [gnuplot_header] (type: int) Optional keyword to modify the header of the .out files. Allows to use the column title instead of columns number.