#include "parameter.hpp"
#include "variable.hpp"
#include <Eigen/Sparse>
Go to the source code of this file.
|
using | cvx::MatrixX = Eigen::Matrix< cvx::Scalar, Eigen::Dynamic, Eigen::Dynamic > |
|
using | cvx::VectorX = Eigen::Matrix< cvx::Scalar, Eigen::Dynamic, 1 > |
|
|
Scalar | cvx::par (double p) |
| Creates a constant parameter. More...
|
|
Scalar | cvx::dynpar (double &p) |
| Creates a dynamic parameter. More...
|
|
template<typename Derived > |
auto | cvx::par (const Eigen::MatrixBase< Derived > &m) |
| Creates a constant parameter from a dense Eigen type. More...
|
|
template<typename Derived > |
auto | cvx::par (const Eigen::SparseMatrixBase< Derived > &m) |
| Creates a constant parameter from a sparse Eigen type. More...
|
|
template<typename Derived > |
auto | cvx::dynpar (Eigen::MatrixBase< Derived > &m) |
| Creates a dynamic parameter from a dense Eigen type. More...
|
|
template<typename T > |
auto | cvx::dynpar (Eigen::SparseMatrix< T > &m) |
| Creates a dynamic parameter from a sparse Eigen type. More...
|
|
double | cvx::eval (const Scalar &s) |
| Evaluates the scalar. More...
|
|
template<typename Derived > |
auto | cvx::eval (const Eigen::MatrixBase< Derived > &m) |
| Evaluates a dense Eigen type. More...
|
|
template<typename Derived > |
auto | cvx::eval (const Eigen::SparseMatrixBase< Derived > &m) |
| Evaluates a sparse Eigen type. More...
|
|
const Scalar & | cvx::conj (const Scalar &x) |
|
const Scalar & | cvx::real (const Scalar &x) |
|
Scalar | cvx::imag (const Scalar &) |
|
Scalar | cvx::square (const Scalar &x) |
|
Scalar | cvx::abs2 (const Scalar &x) |
|
◆ dynpar() [1/3]
Scalar cvx::dynpar |
( |
double & |
p | ) |
|
Creates a dynamic parameter.
Internally stores pointers to the original values.
- Warning
- Do not delete the source before the parameter is no longer required.
- Parameters
-
p | The value of the parameter |
- Returns
- Scalar The constant parameter
◆ dynpar() [2/3]
template<typename Derived >
auto cvx::dynpar |
( |
Eigen::MatrixBase< Derived > & |
m | ) |
|
Creates a dynamic parameter from a dense Eigen type.
Internally stores pointers to the original values.
- Warning
- Do not delete the source before the parameter is no longer required.
- Template Parameters
-
- Parameters
-
m | A dense Eigen type containing problem parameters |
- Returns
- auto A dense Eigen type with cvx::Scalar as scalar type
◆ dynpar() [3/3]
template<typename T >
auto cvx::dynpar |
( |
Eigen::SparseMatrix< T > & |
m | ) |
|
Creates a dynamic parameter from a sparse Eigen type.
Internally stores pointers to the original values.
- Warning
- Do not delete the source before the parameter is no longer required.
- Template Parameters
-
- Parameters
-
m | A sparse Eigen type containing problem parameters |
- Returns
- auto A sparse Eigen type with cvx::Scalar as scalar type
◆ eval() [1/3]
template<typename Derived >
auto cvx::eval |
( |
const Eigen::MatrixBase< Derived > & |
m | ) |
|
|
inline |
Evaluates a dense Eigen type.
- Template Parameters
-
- Parameters
-
m | A dense Eigen type to be evaluated |
- Returns
- auto The evaluated dense Eigen type
◆ eval() [2/3]
template<typename Derived >
auto cvx::eval |
( |
const Eigen::SparseMatrixBase< Derived > & |
m | ) |
|
|
inline |
Evaluates a sparse Eigen type.
- Template Parameters
-
- Parameters
-
m | A sparse Eigen type to be evaluated |
- Returns
- auto The evaluated sparse Eigen type
◆ eval() [3/3]
double cvx::eval |
( |
const Scalar & |
s | ) |
|
Evaluates the scalar.
- Parameters
-
s | The scalar to be evaluated |
- Returns
- double The value of the scalar
◆ par() [1/3]
template<typename Derived >
auto cvx::par |
( |
const Eigen::MatrixBase< Derived > & |
m | ) |
|
|
inline |
Creates a constant parameter from a dense Eigen type.
- Template Parameters
-
- Parameters
-
m | A dense Eigen type containing problem parameters |
- Returns
- auto A dense Eigen type with cvx::Scalar as scalar type
◆ par() [2/3]
template<typename Derived >
auto cvx::par |
( |
const Eigen::SparseMatrixBase< Derived > & |
m | ) |
|
|
inline |
Creates a constant parameter from a sparse Eigen type.
- Template Parameters
-
- Parameters
-
m | A sparse Eigen type containing problem parameters |
- Returns
- auto A sparse Eigen type with cvx::Scalar as scalar type
◆ par() [3/3]
Scalar cvx::par |
( |
double |
p | ) |
|
Creates a constant parameter.
- Parameters
-
p | The value of the parameter |
- Returns
- Scalar The constant parameter