alpaqa dll
Nonconvex constrained optimization
Loading...
Searching...
No Matches
L1Norm< Conf, Weight > Struct Template Reference

#include <alpaqa/functions/l1-norm.hpp>

Detailed Description

template<Config Conf, class Weight = typename Conf::real_t>
requires (std::is_same_v<Weight, typename Conf::real_t> || std::is_same_v<Weight, typename Conf::vec> || std::is_same_v<Weight, typename Conf::rvec> || std::is_same_v<Weight, typename Conf::crvec> || std::is_same_v<Weight, typename Conf::mat> || std::is_same_v<Weight, typename Conf::rmat> || std::is_same_v<Weight, typename Conf::crmat>)
struct alpaqa::functions::L1Norm< Conf, Weight >

ℓ₁-norm.

Template Parameters
WeightType of weighting factors. Either scalar or vector.
Examples
C++/Advanced/lasso-fbs.cpp.

Definition at line 24 of file l1-norm.hpp.

Collaboration diagram for L1Norm< Conf, Weight >:

Public Types

using weight_t = Weight

Public Member Functions

 L1Norm (weight_t λ)
 L1Norm ()
 L1Norm ()=default
real_t prox (crmat in, rmat out, real_t γ=1)

Public Attributes

weight_t λ

Static Public Attributes

static constexpr bool scalar_weight = std::is_same_v<weight_t, real_t>

Member Typedef Documentation

◆ weight_t

template<Config Conf, class Weight = typename Conf::real_t>
using weight_t = Weight

Definition at line 26 of file l1-norm.hpp.

Constructor & Destructor Documentation

◆ L1Norm() [1/3]

template<Config Conf, class Weight = typename Conf::real_t>
L1Norm ( weight_t λ)
inline

Definition at line 29 of file l1-norm.hpp.

Here is the caller graph for this function:

◆ L1Norm() [2/3]

template<Config Conf, class Weight = typename Conf::real_t>
L1Norm ( )
inline

Definition at line 40 of file l1-norm.hpp.

◆ L1Norm() [3/3]

template<Config Conf, class Weight = typename Conf::real_t>
L1Norm ( )
default

Member Function Documentation

◆ prox()

template<Config Conf, class Weight = typename Conf::real_t>
real_t prox ( crmat in,
rmat out,
real_t γ = 1 )
inline

Definition at line 49 of file l1-norm.hpp.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ scalar_weight

template<Config Conf, class Weight = typename Conf::real_t>
bool scalar_weight = std::is_same_v<weight_t, real_t>
staticconstexpr

Definition at line 27 of file l1-norm.hpp.

◆ λ

template<Config Conf, class Weight = typename Conf::real_t>
weight_t λ

Definition at line 47 of file l1-norm.hpp.


The documentation for this struct was generated from the following file: