Use the Time-Dependent Solver (

) to find the solution to time-dependent problems (also called dynamic or unsteady problems) using the implicit time-stepping methods BDF or generalized-
α or an explicit method from a family of Runge-Kutta methods for solving ordinary differential equations. This solver is automatically used when a
Time Dependent study is added to the model.
Use the Defined by study step list to specify if the settings are synchronized with the corresponding study step (the default). If you select
User defined (to override the settings defined in the corresponding study node), you can specify the following settings:
•
|
Use the Time unit list to choose a time unit that is suitable for the time span of the simulation. The default time unit is inherited from the corresponding setting in the study step.
|
•
|
Use the Times field to enter a vector of times that define the time span for the simulation using the Range button (  ) if needed (default: range(0,0.1.1)).
|
•
|
Use the Relative tolerance field to enter a positive scalar number (default: 0.01). The solver uses this number to control the relative error in each time step.
|
Select a Global method to select how the specified absolute tolerance is to be interpreted for the variables that use the global method (by default, all variables use the global method). Select:
•
|
Scaled to let the absolute tolerance be applied to scaled variables.
|
•
|
Unscaled to let the absolute tolerance be applied to unscaled variables.
|
In the Tolerance field, enter a positive number that is applied to either scaled or unscaled variables.
To specify the absolute tolerance individually for a variable, select from the Variables list and modify the corresponding tolerance using the
Method list. Select:
•
|
Scaled to apply the specified tolerance to scaled variables.
|
•
|
Unscaled to apply the specified tolerance to unscaled variables.
|
•
|
Use global (the default) to apply the tolerance specified for the global tolerance.
|
If Scaled or
Unscaled is selected as the
Method:
•
|
Enter a Tolerance value to modify the absolute tolerance for the selected variable.
|
•
|
If a problem of wave-equation type is being solved, and if Method in the Time Stepping section is set to BDF, then by default, the solver chooses a tolerance for these components. To manually enter a tolerance for a time derivative when using a first-order time integration method like BDF, select the Tolerance, time derivative check box and enter a tolerance in the associated field. The generalized- α method does not use this tolerance setting.
|
|
The Method setting ( Scaled or Unscaled) that is selected for a variable applies also to its time derivative.
|
Select the Update scaled absolute tolerance check box as needed. See
Absolute Tolerance Settings for the Time-Dependent Solver for details.
•
|
BDF to use a backward differentiation formula.
|
•
|
Runge-Kutta to use an explicit method from the Runge-Kutta family of methods for ODEs. From the Runge-Kutta method choose one of the following time-stepping methods:
|
-
|
RK34 (the default) combines adaptivity with good stability properties along the imaginary axis. It is therefore suitable for oscillatory problems.
|
-
|
Cash-Karp 5 is similar to Dormand-Prince 5 but has an even larger stability region along the negative real axis. It is therefore more efficient for naturally damped problems.
|
-
|
Dormand-Prince 5 (DOPRI5) method (see Ref. 12) provides estimates of the accuracy and stability by combining the Runge-Kutta steps using different sets of coefficients to get different order of accuracies.
|
•
|
Initialization only to compute consistent initial values only and then stop. If this option is selected, no other settings are required.
|
The following settings are available when BDF or
Generalized alpha is selected above.
If a Fully Coupled or Segregated attribute node is attached to a Time node, the settings for the nonlinear systems solved by the time-stepping methods come from that node.
|
The time-stepping method Generalized alpha requires a Fully Coupled or Segregated attribute node.
The time-stepping method BDF can be used without a Fully Coupled or Segregated attribute node. In such a situation, the BDF method uses an internal automatic nonlinear solver.
|
•
|
Free to let the time-stepping method choose time steps freely. The times specified in the Times field in the General section are not considered when a time step is chosen.
|
•
|
Intermediate to force the time-stepping method to take at least one step in each subinterval of the times specified in the Times field in the General section.
|
•
|
Strict to force the time-stepping method to take steps that end at the times specified in the Times field in the General section. The solver takes additional steps in between these times if necessary.
|
•
|
Manual to override the automatic choice of time step with a manual choice.
|
|
Manual is only available for Generalized alpha and overrides the local error estimation made in each time step.
|
If Free,
Intermediate, or
Strict is selected for the
Steps taken by solver:
•
|
Initial step. By default the solver chooses an initial step automatically. Select the Initial step check box for manual specification of an initial step.
|
•
|
Maximum step. By default the solver chooses a maximum time step automatically. Select the Maximum step check box for manual specification of a maximum time step. The maximum time step is a positive scalar value, which can be an expression that evaluates to a numerical value. The expression can include global parameters.
|
If Manual is selected for the
Steps taken by solver:
•
|
Time step. Enter a manual time step specification as a scalar, a vector of times, or an expression containing global variables or parameters in the Time step field.
|
If BDF is selected as the time stepping
Method:
•
|
Maximum BDF order. This setting controls the maximum allowed degree of the interpolating polynomial of the BDF method.
|
•
|
Minimum BDF order. This setting can be used to prevent the solver from decreasing the order of the BDF method below 2.
|
•
|
Event tolerance. This setting can be used to set the event tolerance (default value: 0.01), which is used for root finding of event conditions when using implicit events; see Explicit Event.
|
•
|
Nonlinear controller. Select this check box to use a nonlinear controller for more efficient time-step control in the BDF method, especially for highly nonlinear problems such as multiphase flow and turbulence in fluid dynamics. When nonlinear failures occur, the nonlinear controller becomes active and uses a more careful time step regulation. The nonlinear controller acknowledges that the step size for Newton stability might be smaller than the step size for BDF accuracy.
|
If Generalized alpha is selected as the time stepping
Method:
•
|
Time step increase delay (available if Free, Intermediate, or Strict is selected for the Steps taken by solver). Select this check box and enter a positive integer in the field to make the solver more restrictive when increasing the time step. This integer is the number of time steps taken by the solver before the increase of the time step is actually performed, from the first step where the error estimator signals that the current step is too small. This setting is useful when there is a natural variation in the solution, like periodicity or quasi-periodicity, which make the time steps vary up and down in size. The generalized- α method does not work well when the time step changes often, so in those situations it is better to damp the changes by a more conservative strategy using this setting. Entering 0 results in the same behavior as clearing the check box.
|
•
|
Amplification for high frequency. Enter a number between 0 and 1 to control how much damping of high frequencies the solver provides. A value close to 0 results in efficient damping, while a number close to 1 results in little damping.
|
•
|
Predictor. Select Linear to use linear extrapolation of the present solution to construct the initial guess for the nonlinear system of equations to be solved at the next time step. Select Constant to use the current solution as initial guess.
|
Use the Singular mass matrix list to control whether the solver automatically determines if a system includes a differential-algebraic equation or not. Select:
•
|
Maybe to make the solver look for zero-filled rows or columns in the mass matrix as a means of detecting a differential-algebraic equation.
|
•
|
Yes if the model includes a differential-algebraic equation where the mass matrix has no zero-filled rows or columns.
|
Use the Consistent initialization list to control how the solver performs consistent initialization of differential-algebraic systems. Select:
•
|
Backward Euler to perform consistent initialization using a small artificial step with the backward Euler method. When this is selected, enter a value in the Fraction of initial step for Backward Euler field. This value is a dimensionless quantity that determines the size of the time step for the backward Euler method (in terms of the initial step). Adjusting this value can improve the accuracy of the initialization step but can also affect the start-up of some models. The default value is 0.001 (that is, the small backward Euler step size is 0.1% of the initial step size).
|
•
|
Off to indicate that the initial values already are consistent, which means that the solver does not modify them.
|
•
|
On to use a consistent initialization routine that is preferable to Backward Euler for index-1 differential-algebraic equations.
|
|
The On option is only available when Time method is set to BDF at the same time that the internal nonlinear solver of the BDF method is used.
|
Use the Error estimation list to control how to treat algebraic degrees of freedom of a differential-algebraic system when estimating the time discretization error. Select:
•
|
Include algebraic (the default) to include the algebraic degrees of freedom in the error norm.
|
The following settings are available when Runge-Kutta is selected as the time-stepping method:
•
|
Free to let the time-stepping method choose time steps freely. The times specified in the Times field in the General section are not considered when a time step is chosen.
|
•
|
Intermediate to force the time-stepping method to take at least one step in each subinterval of the times specified in the Times field in the General section.
|
•
|
Strict to force the time-stepping method to take steps that end at the times specified in the Times field in the General section. The solver takes additional steps in between these times if necessary.
|
•
|
Manual to override the automatic choice of time step with a manual choice.
|
If Free,
Intermediate, or
Strict is selected for the
Steps taken by solver:
•
|
Initial step. By default the solver chooses an initial step automatically. Select the Initial step check box for manual specification of an initial step.
|
The following settings for Free,
Intermediate, and
Strict are only available for the Dormand-Prince time-stepping method:
•
|
Maximum step. By default the solver chooses a maximum time step automatically. Select the Maximum step check box for manual specification of a maximum time step. The maximum time step is a positive scalar value, which can be an expression that evaluates to a numerical value. The expression can include global parameters.
|
•
|
Minimum step size growth ratio and Maximum step size growth ratio. These growth ratio limits restrict how fast the step size may change, enforcing that the values of the ratio hnew/ hold is within the minimum step size growth ratio (default: 0.2) and the maximum step size growth ratio (default: 10).
|
•
|
Step size safety factor. The solver multiplies this factor (default: 0.9) to the estimated largest allowed step size to avoid taking too large step sizes when the estimate overshoots.
|
•
|
PI step controller. This setting affects the behavior of the PI (proportional-integral) controller that adds damping on step size changes to avoid choosing too large steps, which would then be rejected. The default value is Quick, which corresponds to a PI controller that responds quickly to changes. The Smooth option sets the controller to react more slowly, giving smoother choices of time steps. You can also turn off the PI controller by selecting Disabled. This setting affects the parameters α and β in the relation  . Here S is the safety factor described above, and erri is the estimated error in step i.
|
If Manual is selected for the
Steps taken by solver:
•
|
Time step. Enter a manual time step specification as a scalar, a vector of times, or an expression containing global variables or parameters in the Time step field.
|
For all options in the Steps taken by solver list, you can also activate or turn off detection of numerical stiffness using the
Stiffness detection check box (selected by default). If active, the stiffness detection uses a mechanism to detect if the problem that you solve becomes numerically stiff (which means that an explicit time stepping is required to take very small time steps). If the problem is considered to be stiff, an error appears and the solver stops. You can then switch to another solver that is better suited for stiff problems, such as an implicit BDF method.
This section mirrors what is defined for the Time Dependent node’s
Results While Solving section. That is, changes made to the Time-Dependent node are reflected here.
Use the Times to store list to control at what times the solver stores a solution. Select:
•
|
Specified values to store solutions at the values entered in the Times field in the General section.
|
•
|
Select the Store reaction forces check box to compute and store reaction forces in the output. This option is not supported when using any of the Runge-Kutta time-stepping methods.
|
•
|
Select the Store time derivatives check box to store time derivatives of the variables solved for in the output. Storing the time derivatives gives more accurate results when evaluating quantities that involve these time derivatives.
|
•
|
Select the Store solution on disk check box to store the output solution on disk rather than in the computer’s internal memory.
|
•
|
Select the Store solution before and after events check box to store two additional solutions every time an implicit or explicit event is triggered. See The Events Interface. This stores the solutions before and after the reinitialization.
|
Select the Allow complex numbers check box to be able to solve problems that are not automatically determined to be complex valued in a correct way.
Least-squares times are read from files pointed out by the least-squares objective nodes in an Optimization interface. If there is a least-squares objective with a time column, the time values are displayed under Least-squares times from file. If
Use least-squares times from file is on (which is the default), the least-squares times are read and merged with the user-defined time list at runtime. The merged data governs the setup of the time-dependent solver.
General parameter values list here refers to the list of times in the
General section above. If
Exclude times outside General parameter value lists is on (which is the default), start and end simulation times that you have provided are respected when merging with time values from files. Time values from files outside the user-defined time range are ignored. Otherwise (that is,
Exclude times outside General parameter value lists is off), all time values from files are used and merged with the user-defined time list.
If Use least-squares times from file is off, no time values from files are used.
You can change the default values of Use least-squares times from file and
Exclude times outside General parameter value lists only if
Defined by study step is set to
User defined.
In this section you can define constants that can be used as temporary constants in the solver. You can use the constants in the model or to define values for internal solver parameters. Click the Add (

) button to add a constant and then define its name in the
Constant name column and its value (a numerical value or parameter expression) in the
Constant value column. By default, any defined parameters are first added as the constant names, but you can change the names to define other constants. Click
Delete (

) to remove the selected constant from the list.
This section, which is initially empty, contains a log from the time stepping. This log is stored in the MPH-file. Select the Keep warnings in stored log to keep warning messages in this log so that the information in those warnings is available also when reopening the model.