numerical-collection-cpp 0.10.0
A collection of algorithms in numerical analysis implemented in C++
|
Class of quadratic functions with random coefficients and optimal variables. More...
#include <num_prob_collect/opt/random_quadratic_function.h>
Public Types | |
using | value_type = double |
Type of function values. | |
using | variable_type = double |
Type of variables. | |
Public Member Functions | |
random_quadratic_function (double coeff, double optimal_variable) noexcept | |
Constructor. | |
auto | coeff () const noexcept -> double |
Get the coefficient. | |
void | evaluate_on (double variable) noexcept |
Evaluate function value on variable. | |
auto | optimal_variable () const noexcept -> double |
Get the optimal variable. | |
auto | value () const noexcept -> const double & |
Get function value. | |
Private Attributes | |
double | coeff_ |
Coefficient. | |
double | optimal_variable_ |
Optimal variable. | |
double | value_ {0.0} |
Function value. | |
Class of quadratic functions with random coefficients and optimal variables.
Definition at line 30 of file random_quadratic_function.h.
using num_prob_collect::opt::random_quadratic_function::value_type = double |
Type of function values.
Definition at line 35 of file random_quadratic_function.h.
Type of variables.
Definition at line 33 of file random_quadratic_function.h.
|
inlinenoexcept |
Constructor.
[in] | coeff | Coefficient. |
[in] | optimal_variable | Optimal variable. |
Definition at line 43 of file random_quadratic_function.h.
|
inlinenodiscardnoexcept |
|
inlinenoexcept |
Evaluate function value on variable.
[in] | variable | Variable. |
Definition at line 51 of file random_quadratic_function.h.
|
inlinenodiscardnoexcept |
Get the optimal variable.
Definition at line 77 of file random_quadratic_function.h.
|
inlinenodiscardnoexcept |
Get function value.
Definition at line 61 of file random_quadratic_function.h.
|
private |
Coefficient.
Definition at line 83 of file random_quadratic_function.h.
|
private |
Optimal variable.
Definition at line 86 of file random_quadratic_function.h.
|
private |
Function value.
Definition at line 89 of file random_quadratic_function.h.