shark::Dirichlet_distribution< RealType > Class Template Reference

Dirichlet distribution. More...

#include <shark/Rng/Dirichlet.h>

Public Member Functions

 Dirichlet_distribution (size_t n=3, RealType alpha=1)
 
 Dirichlet_distribution (const std::vector< RealType > &alphas)
 
const std::vector< RealType > & alphas () const
 
void reset ()
 
template<class Engine >
result_type operator() (Engine &eng) const
 

Friends

template<class CharT , class Traits >
std::basic_ostream< CharT, Traits > & operator<< (std::basic_ostream< CharT, Traits > &os, const Dirichlet_distribution &d)
 
template<class CharT , class Traits >
std::basic_istream< CharT, Traits > & operator>> (std::basic_istream< CharT, Traits > &is, Dirichlet_distribution &d)
 

Detailed Description

template<class RealType = double>
class shark::Dirichlet_distribution< RealType >

Dirichlet distribution.

Definition at line 53 of file Dirichlet.h.

Constructor & Destructor Documentation

◆ Dirichlet_distribution() [1/2]

template<class RealType = double>
shark::Dirichlet_distribution< RealType >::Dirichlet_distribution ( size_t  n = 3,
RealType  alpha = 1 
)
inlineexplicit

Definition at line 59 of file Dirichlet.h.

◆ Dirichlet_distribution() [2/2]

template<class RealType = double>
shark::Dirichlet_distribution< RealType >::Dirichlet_distribution ( const std::vector< RealType > &  alphas)
inlineexplicit

Definition at line 62 of file Dirichlet.h.

Member Function Documentation

◆ alphas()

template<class RealType = double>
const std::vector<RealType>& shark::Dirichlet_distribution< RealType >::alphas ( ) const
inline

◆ operator()()

template<class RealType = double>
template<class Engine >
result_type shark::Dirichlet_distribution< RealType >::operator() ( Engine &  eng) const
inline

Definition at line 74 of file Dirichlet.h.

References remora::sum().

◆ reset()

template<class RealType = double>
void shark::Dirichlet_distribution< RealType >::reset ( )
inline

Definition at line 71 of file Dirichlet.h.

Friends And Related Function Documentation

◆ operator<<

template<class RealType = double>
template<class CharT , class Traits >
std::basic_ostream<CharT,Traits>& operator<< ( std::basic_ostream< CharT, Traits > &  os,
const Dirichlet_distribution< RealType > &  d 
)
friend

Definition at line 94 of file Dirichlet.h.

◆ operator>>

template<class RealType = double>
template<class CharT , class Traits >
std::basic_istream<CharT,Traits>& operator>> ( std::basic_istream< CharT, Traits > &  is,
Dirichlet_distribution< RealType > &  d 
)
friend

Definition at line 104 of file Dirichlet.h.


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