alpaqa develop
Nonconvex constrained optimization
Loading...
Searching...
No Matches
Classes | Namespaces | Concepts | Macros | Typedefs | Functions | Variables
config.hpp File Reference
#include <alpaqa/util/quadmath/quadmath-print.hpp>
#include <alpaqa/util/quadmath/quadmath.hpp>
#include <complex>
#include <limits>
#include <type_traits>
#include <Eigen/Core>
+ Include dependency graph for config.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  is_config< T >
 
struct  is_eigen_config< T >
 
struct  is_config< EigenConfigf >
 
struct  is_config< EigenConfigd >
 
struct  is_config< EigenConfigl >
 
struct  is_config< EigenConfigq >
 
struct  is_eigen_config< EigenConfigf >
 
struct  is_eigen_config< EigenConfigd >
 
struct  is_eigen_config< EigenConfigl >
 
struct  is_eigen_config< EigenConfigq >
 
struct  EigenConfig< RealT >
 
struct  EigenConfigf
 Single-precision float configuration. More...
 
struct  EigenConfigd
 Double-precision double configuration. More...
 
struct  EigenConfigl
 long double configuration. More...
 

Namespaces

namespace  alpaqa
 
namespace  alpaqa::vec_util
 

Concepts

concept  alpaqa::Config
 

Macros

#define USING_ALPAQA_CONFIG_NO_TYPENAME(Conf)
 
#define USING_ALPAQA_CONFIG(Conf)
 
#define USING_ALPAQA_CONFIG_TEMPLATE(Conf)
 
#define ALPAQA_IF_QUADF(...)
 
#define ALPAQA_IF_FLOAT(...)
 
#define ALPAQA_IF_LONGD(...)
 

Typedefs

using DefaultConfig = EigenConfigd
 
template<Config Conf = DefaultConfig>
using real_t = typename Conf::real_t
 
template<Config Conf = DefaultConfig>
using cplx_t = typename Conf::cplx_t
 
template<Config Conf = DefaultConfig>
using vec = typename Conf::vec
 
template<Config Conf = DefaultConfig>
using mvec = typename Conf::mvec
 
template<Config Conf = DefaultConfig>
using cmvec = typename Conf::cmvec
 
template<Config Conf = DefaultConfig>
using rvec = typename Conf::rvec
 
template<Config Conf = DefaultConfig>
using crvec = typename Conf::crvec
 
template<Config Conf = DefaultConfig>
using mat = typename Conf::mat
 
template<Config Conf = DefaultConfig>
using mmat = typename Conf::mmat
 
template<Config Conf = DefaultConfig>
using cmmat = typename Conf::cmmat
 
template<Config Conf = DefaultConfig>
using rmat = typename Conf::rmat
 
template<Config Conf = DefaultConfig>
using crmat = typename Conf::crmat
 
template<Config Conf = DefaultConfig>
using cmat = typename Conf::cmat
 
template<Config Conf = DefaultConfig>
using mcmat = typename Conf::mcmat
 
template<Config Conf = DefaultConfig>
using cmcmat = typename Conf::cmcmat
 
template<Config Conf = DefaultConfig>
using rcmat = typename Conf::rcmat
 
template<Config Conf = DefaultConfig>
using crcmat = typename Conf::crcmat
 
template<Config Conf = DefaultConfig>
using length_t = typename Conf::length_t
 
template<Config Conf = DefaultConfig>
using index_t = typename Conf::index_t
 
template<Config Conf = DefaultConfig>
using indexvec = typename Conf::indexvec
 
template<Config Conf = DefaultConfig>
using rindexvec = typename Conf::rindexvec
 
template<Config Conf = DefaultConfig>
using crindexvec = typename Conf::crindexvec
 
template<Config Conf = DefaultConfig>
using mindexvec = typename Conf::mindexvec
 
template<Config Conf = DefaultConfig>
using cmindexvec = typename Conf::cmindexvec
 

Functions

template<class Derived >
requires (Derived::ColsAtCompileTime == 1)
auto norm_inf (const Eigen::MatrixBase< Derived > &v)
 Get the maximum or infinity-norm of the given vector.
 
template<class Derived >
requires (Derived::ColsAtCompileTime == 1)
auto norm_1 (const Eigen::MatrixBase< Derived > &v)
 Get the 1-norm of the given vector.
 

Variables

template<class T >
constexpr bool is_config_v = is_config<T>::value
 
template<class T >
constexpr bool is_eigen_config_v = is_eigen_config<T>::value
 
template<Config Conf>
constexpr const auto inf = std::numeric_limits<real_t<Conf>>::infinity()
 
template<Config Conf>
constexpr const auto NaN = std::numeric_limits<real_t<Conf>>::quiet_NaN()
 
template<Config Conf>
const rvec< Confnull_vec = mvec<Conf>{nullptr, 0}
 Global empty vector for convenience.
 
template<Config Conf>
const rindexvec< Confnull_indexvec = mindexvec<Conf>{nullptr, 0}
 Global empty index vector for convenience.
 

Macro Definition Documentation

◆ USING_ALPAQA_CONFIG_NO_TYPENAME

#define USING_ALPAQA_CONFIG_NO_TYPENAME (   Conf)
Value:
using real_t [[maybe_unused]] = Conf::real_t; \
using cplx_t [[maybe_unused]] = Conf::cplx_t; \
using vec [[maybe_unused]] = Conf::vec; \
using mvec [[maybe_unused]] = Conf::mvec; \
using cmvec [[maybe_unused]] = Conf::cmvec; \
using rvec [[maybe_unused]] = Conf::rvec; \
using crvec [[maybe_unused]] = Conf::crvec; \
using mat [[maybe_unused]] = Conf::mat; \
using mmat [[maybe_unused]] = Conf::mmat; \
using cmmat [[maybe_unused]] = Conf::cmmat; \
using rmat [[maybe_unused]] = Conf::rmat; \
using crmat [[maybe_unused]] = Conf::crmat; \
using cmat [[maybe_unused]] = Conf::cmat; \
using mcmat [[maybe_unused]] = Conf::mcmat; \
using cmcmat [[maybe_unused]] = Conf::cmcmat; \
using rcmat [[maybe_unused]] = Conf::rcmat; \
using crcmat [[maybe_unused]] = Conf::crcmat; \
using length_t [[maybe_unused]] = Conf::length_t; \
using index_t [[maybe_unused]] = Conf::index_t; \
using indexvec [[maybe_unused]] = Conf::indexvec; \
using rindexvec [[maybe_unused]] = Conf::rindexvec; \
using crindexvec [[maybe_unused]] = Conf::crindexvec; \
using mindexvec [[maybe_unused]] = Conf::mindexvec; \
using cmindexvec [[maybe_unused]] = Conf::cmindexvec

Definition at line 51 of file config.hpp.

◆ USING_ALPAQA_CONFIG

#define USING_ALPAQA_CONFIG (   Conf)
Value:
/** @cond CONFIG_TYPES */ \
using config_t [[maybe_unused]] = Conf; \
USING_ALPAQA_CONFIG_NO_TYPENAME(typename Conf) /** @endcond */
Examples
C++/Advanced/lasso-fbs.cpp, C++/CasADi/Rosenbrock/main.cpp, C++/CustomControlCppProblem/main.cpp, C++/CustomCppProblem/main.cpp, C++/DLProblem/main.cpp, C++/FortranProblem/main.cpp, C++/SimpleUnconstrProblem/main.cpp, and problems/sparse-logistic-regression.cpp.

Definition at line 77 of file config.hpp.

◆ USING_ALPAQA_CONFIG_TEMPLATE

#define USING_ALPAQA_CONFIG_TEMPLATE (   Conf)
Value:
/** @cond CONFIG_TYPES */ \
using config_t [[maybe_unused]] = typename Conf; \
USING_ALPAQA_CONFIG_NO_TYPENAME(typename Conf) /** @endcond */

Definition at line 81 of file config.hpp.

◆ ALPAQA_IF_QUADF

#define ALPAQA_IF_QUADF (   ...)

Definition at line 223 of file config.hpp.

◆ ALPAQA_IF_FLOAT

#define ALPAQA_IF_FLOAT (   ...)

Definition at line 229 of file config.hpp.

◆ ALPAQA_IF_LONGD

#define ALPAQA_IF_LONGD (   ...)

Definition at line 235 of file config.hpp.