Utils.hpp
48 auto fractionToTheBoundary(VectorConstRef p, VectorConstRef dp, double tau, Index& ilimiting) -> double;
57 auto fractionToTheBoundary(VectorConstRef p, VectorConstRef dp, MatrixConstRef C, VectorConstRef r, double tau) -> double;
65 auto fractionToTheLowerBoundary(VectorConstRef p, VectorConstRef dp, VectorConstRef lower, double tau) -> double;
96 auto minimizeGoldenSectionSearch(const std::function<double(double)>& f, double a, double b, double tol = 1e-5) -> double;
99 auto minimizeBrent(const std::function<double(double)>& f, double min, double max, double tolerance = 1e-5, unsigned maxiters = 100) -> double;
auto infinity() -> double
Return the floating-point representation of positive infinity.
Definition: Utils.cpp:105
auto minimizeBrent(const std::function< double(double)> &f, double min, double max, double tolerance, unsigned maxiters) -> double
Calculate the minimum of a single variable function using the Brent algorithm.
Definition: Utils.cpp:201
The namespace containing all components of the Reaktoro library.
Definition: ChemicalScalar.hpp:24
auto lessThan(double lhs, double rhs, double baseval) -> bool
Compute the fraction-to-the-boundary step length given by:
Definition: Utils.cpp:93
auto greaterThan(double lhs, double rhs, double baseval) -> bool
Check if a float number is greater than another by a base value.
Definition: Utils.cpp:99
auto largestStep(VectorConstRef p, VectorConstRef dp) -> double
Compute the largest step length such that is on the lower bound .
Definition: Utils.cpp:25
auto bfgs() -> std::function< Matrix(VectorConstRef, VectorConstRef)>
Return an inverse Hessian function based on the BFGS Hessian approximation.
Definition: Utils.cpp:110
Eigen::Ref< const Eigen::MatrixXd > MatrixConstRef
Alias to Eigen type Ref<const MatrixXd>.
Definition: Matrix.hpp:44
Eigen::Ref< const Eigen::VectorXd > VectorConstRef
< Alias to Eigen type Ref<VectorXd>.
Definition: Matrix.hpp:31