C(++)ECCO
C++ Error Control COding: a header-only library for ECC simulations and experiments, modeling complete coding systems across arbitrary finite fields and complex inter-field relationships - Christian Senger <senger@inue.uni-stuttgart.de>
Loading...
Searching...
No Matches
CECCO::TannerGraph< T >::BP_Workspace Struct Reference

Workspace for sum-product (belief propagation) decoding. More...

#include <graphs.hpp>

Public Member Functions

 BP_Workspace (const TannerGraph &g)
 Allocate message and belief arrays for g.
void calculate_intrinsic (const TannerGraph &g, const Matrix< double > &llrs)
 Set intrinsic (channel) costs from symbol-level LLRs.

Public Attributes

std::vector< std::vector< std::array< double, q > > > m_vc
 Variable-to-check messages by check and incident edge.
std::vector< std::vector< std::array< double, q > > > m_cv
 Check-to-variable messages by check and incident edge.
std::vector< std::array< double, q > > intrinsic
 Intrinsic (channel) cost per variable node and symbol.
std::vector< std::array< double, q > > posterior
 Posterior belief per variable node and symbol.
std::vector< std::vector< std::pair< size_t, size_t > > > var_edges
 Incident (check, edge) pairs for each variable node.
std::optional< Matrix< double > > v
 Optional received LLR matrix shown in TikZ output.

Static Public Attributes

static constexpr size_t q = T::get_size()
 Number of field symbols (message and belief vector length).

Detailed Description

template<FieldType T>
struct CECCO::TannerGraph< T >::BP_Workspace

Workspace for sum-product (belief propagation) decoding.

Stores variable-to-check and check-to-variable messages, the intrinsic (channel) costs, and the running posterior beliefs, each a length-q array per node. It is used by LinearCode<T>::dec_BP.

Definition at line 964 of file graphs.hpp.

Constructor & Destructor Documentation

◆ BP_Workspace()

template<FieldType T>
CECCO::TannerGraph< T >::BP_Workspace::BP_Workspace ( const TannerGraph & g)
inlineexplicit

Allocate message and belief arrays for g.

Parameters
gTanner graph whose variable- and check-node degrees define the workspace

Definition at line 973 of file graphs.hpp.

Member Function Documentation

◆ calculate_intrinsic()

template<FieldType T>
void CECCO::TannerGraph< T >::BP_Workspace::calculate_intrinsic ( const TannerGraph & g,
const Matrix< double > & llrs )
inline

Set intrinsic (channel) costs from symbol-level LLRs.

Parameters
gTanner graph providing the variable-node count
llrsSymbol-level LLR matrix with q−1 rows and one column per variable node

Intrinsic costs are the negated symbol costs of CECCO::details::symbol_costs_from_llrs.

Definition at line 991 of file graphs.hpp.

Member Data Documentation

◆ intrinsic

template<FieldType T>
std::vector<std::array<double, q> > CECCO::TannerGraph< T >::BP_Workspace::intrinsic

Intrinsic (channel) cost per variable node and symbol.

Definition at line 1005 of file graphs.hpp.

◆ m_cv

template<FieldType T>
std::vector<std::vector<std::array<double, q> > > CECCO::TannerGraph< T >::BP_Workspace::m_cv

Check-to-variable messages by check and incident edge.

Definition at line 1003 of file graphs.hpp.

◆ m_vc

template<FieldType T>
std::vector<std::vector<std::array<double, q> > > CECCO::TannerGraph< T >::BP_Workspace::m_vc

Variable-to-check messages by check and incident edge.

Definition at line 1001 of file graphs.hpp.

◆ posterior

template<FieldType T>
std::vector<std::array<double, q> > CECCO::TannerGraph< T >::BP_Workspace::posterior

Posterior belief per variable node and symbol.

Definition at line 1007 of file graphs.hpp.

◆ q

template<FieldType T>
size_t CECCO::TannerGraph< T >::BP_Workspace::q = T::get_size()
staticconstexpr

Number of field symbols (message and belief vector length).

Definition at line 966 of file graphs.hpp.

◆ v

template<FieldType T>
std::optional<Matrix<double> > CECCO::TannerGraph< T >::BP_Workspace::v

Optional received LLR matrix shown in TikZ output.

Definition at line 1011 of file graphs.hpp.

◆ var_edges

template<FieldType T>
std::vector<std::vector<std::pair<size_t, size_t> > > CECCO::TannerGraph< T >::BP_Workspace::var_edges

Incident (check, edge) pairs for each variable node.

Definition at line 1009 of file graphs.hpp.


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