NavierStokesSolver#
- class NavierStokesSolver[source]#
Bases:
GenericSolverSettingsNavierStokesSolverclass for setting up the compressible Navier-Stokes solver. For more information on setting up the numerical parameters for the Navier-Stokes solver, refer to Navier-Stokes solver knowledge base.Example
>>> fl.NavierStokesSolver( ... absolute_tolerance=1e-10, ... numerical_dissipation_factor=0.01, ... linear_solver=LinearSolver(max_iterations=50), ... low_mach_preconditioner=True, ... )
Attributes
- absolute_tolerance: float#
Tolerance for the NS residual, below which the solver goes to the next physical step.
- Default:
1e-10
- relative_tolerance: float#
Tolerance to the relative residual, below which the solver goes to the next physical step. Relative residual is defined as the ratio of the current pseudoStep’s residual to the maximum residual present in the first 10 pseudoSteps within the current physicalStep. NOTE: relativeTolerance is ignored in steady simulations and only absoluteTolerance is used as the convergence criterion.
- Default:
0
- linear_solver: LinearSolver#
- Default:
LinearSolver()
- CFL_multiplier: float#
Factor to the CFL definitions defined in the Time Stepping section.
- Default:
1.0
- kappa_MUSCL: float#
Kappa for the MUSCL scheme, range from [-1, 1], with 1 being unstable. The default value of -1 leads to a 2nd order upwind scheme and is the most stable. A value of 0.33 leads to a blended upwind/central scheme and is recommended for low subsonic flows leading to reduced dissipation.
- Default:
-1
- numerical_dissipation_factor: float#
A factor in the range [0.01, 1.0] which exponentially reduces the dissipation of the numerical flux. The recommended starting value for most low-dissipation runs is 0.2.
- Default:
1
- low_mach_preconditioner: bool#
Use preconditioning for accelerating low Mach number flows.
- Default:
False
- low_mach_preconditioner_threshold: float, optional#
For flow regions with Mach numbers smaller than threshold, the input Mach number to the preconditioner is assumed to be the threshold value if it is smaller than the threshold. The default value for the threshold is the freestream Mach number.
- Default:
None
- max_force_jac_update_physical_steps: int#
When physical step is less than this value, the jacobian matrix is updated every pseudo step.
- Default:
0
Additional Constructors
- classmethod from_file(filename)#
Loads a
Flow360BaseModelfrom .json, or .yaml file.- Parameters:
filename (str) – Full path to the .yaml or .json file to load the
Flow360BaseModelfrom.- Returns:
An instance of the component class calling load.
- Return type:
Flow360BaseModel
Example
>>> params = Flow360BaseModel.from_file(filename='folder/sim.json')
Methods
- help(methods=False)#
Prints message describing the fields and methods of a
Flow360BaseModel.- Parameters:
methods (bool = False) – Whether to also print out information about object’s methods.
- Return type:
None
Example
>>> params.help(methods=True)