38#include <itpp/itexports.h>
135 LLR_calc_unit(
short int Dint1,
short int Dint2,
short int Dint3);
166 short int Dint3 = 7);
220 ivec construct_logexp_table();
226 short int Dint1, Dint2, Dint3;
242 return static_cast<double>(l) / (1 << Dint1);
249 if (l > QLLR_MAX_double) {
253 if (l < -QLLR_MAX_double) {
257 return static_cast<QLLR>(std::floor(0.5 + (1 << Dint1) * l));
264 int ind = x >> Dint3;
269 it_assert_debug(ind < Dint2,
"LLR_calc_unit::logexp(): internal error");
276 return logexp_table(ind);
296 return (maxab +
logexp(x));
Log-likelihood algebra calculation unit.
QLLR jaclog(QLLR a, QLLR b) const
Jacobian logarithm.
QLLR Boxplus(QLLR a, QLLR b) const
Hagenauer's "Boxplus" operator.
void init_llr_tables(short int Dint1=12, short int Dint2=300, short int Dint3=7)
Set the quantization and table parameters.
ivec get_Dint()
Retrieve the table resolution values.
QLLR to_qllr(double l) const
Convert a "real" LLR value to an LLR type.
friend ITPP_EXPORT std::ostream & operator<<(std::ostream &os, const LLR_calc_unit &l)
Print some properties of the LLR calculation unit in plain text.
QLLR logexp(QLLR x) const
Logexp operator.
double to_double(QLLR l) const
Convert an LLR type to a "real" LLR.
LLR_calc_unit()
Constructor, using the default table resolution.
#define it_info_debug(s)
Print information message if NDEBUG is not defined.
#define it_assert_debug(t, s)
Abort if t is not true and NDEBUG is not defined.
Matrix Class Definitions.
Various functions on vectors and matrices - header file.
std::ostream & operator<<(std::ostream &output, const bin &inbin)
Output stream of bin.
Definitions of special vectors and matrices.
Templated Vector Class Definitions.