Class SteadyStateProblem
Defined in File forwardproblem.h
Class Documentation
-
class SteadyStateProblem
The SteadyStateProblem class solves a steady-state problem using Newton’s method and falls back to integration on failure.
Public Functions
-
explicit SteadyStateProblem(FwdSimWorkspace *ws, Solver const &solver, Model &model, bool is_preeq)
Constructor.
-
void run(Solver &solver, int it, realtype t0)
Compute the steady state in the forward case.
Tries to determine the steady state of the ODE system and computes steady state sensitivities if requested. Expects that solver, model, and ws_ are already initialized.
- Parameters:
solver – The solver instance
it – Index of the current output time point.
t0 – Initial time for the steady state simulation.
-
inline SimulationState const &get_final_simulation_state() const
Return the stored SimulationState.
- Returns:
stored SimulationState
-
inline AmiVectorArray const &get_state_sensitivity() const
Return state sensitivity at steady state.
- Returns:
sx
-
inline double get_cpu_time() const
Get the CPU time taken to solve the forward problem.
- Returns:
The CPU time in milliseconds.
-
inline std::vector<SteadyStateStatus> const &get_steady_state_status() const
Get the steady state computation status.
- Returns:
Execution status of the different approaches [newton, simulation, newton].
-
inline realtype get_steady_state_time() const
Get model time at which steady state was found through simulation.
- Returns:
Time at which steady state was found (model time units).
-
inline realtype get_residual_norm() const
Get the weighted root mean square of the residuals.
- Returns:
The weighted root-mean-square of the residuals.
-
inline std::vector<int> const &get_num_steps() const
Get the number of steps taken to find the steady state.
- Returns:
Number of steps taken to find the steady state as [newton, simulation, newton].
-
bool check_steady_state_success() const
Check, whether any approach to find the steady state was successful.
- Returns:
Whether any approach to find the steady state was successful.
-
inline Solver const *get_solver() const
Get the pre-equilibration solver.
- Returns:
The preequilibration solver.
-
inline PeriodResult const &get_result() const
Get the preequilibration result.
- Returns:
-
explicit SteadyStateProblem(FwdSimWorkspace *ws, Solver const &solver, Model &model, bool is_preeq)