GNU Radio C++ API Reference: cldpc Class Reference

| GNU Radio C++ API Reference 3.10.12.0 The Free & Open Software Radio Ecosystem |

Loading...
Searching...
No Matches
cldpc Class Reference

`#include <gnuradio/fec/cldpc.h>`

## Public Member Functions
| cldpc ()
| Default constructor.
| cldpc (const GF2Mat X)
| Constructs the LDPC class from given GF2mat X.
| cldpc (const alist _list)
| Constructs the class from the given alist _list.
void | print_permute ()
| Prints the variable permute.
std::vector< uint8_t > | encode (std::vector< uint8_t > dataword)
| Encode the given vector dataword.
int | dimension ()
| Returns the dimension of the code.
GF2Mat | get_H ()
| Returns the parity check matrix H.
GF2Mat | get_G ()
| Returns the matrix G used in encoding.
int | get_M ()
| Returns the variable M.
int | get_N ()
| Returns the variable N.
std::vector< uint8_t > | syndrome (const std::vector< uint8_t > in)
| Returns the syndrome for a given vector "in".
bool | is_codeword (const std::vector< uint8_t > in)
| Returns true if "in" is a codeword, else false.
void | set_alist (const alist _list)
| Set the variable _list.
std::vector< uint8_t > | get_systematic_bits (std::vector< uint8_t > in)
| Obtain systematic bits from "in".

## Constructor & Destructor Documentation

## ◆ cldpc() [1/3]

cldpc::cldpc | ( |  | ) |
| inline

Default constructor.

## ◆ cldpc() [2/3]

cldpc::cldpc | ( | const GF2Mat | X | ) |

Constructs the LDPC class from given GF2mat X.

## ◆ cldpc() [3/3]

cldpc::cldpc | ( | const alist | _list | ) |

Constructs the class from the given alist _list.

## Member Function Documentation

## ◆ dimension()

int cldpc::dimension | ( |  | ) |

Returns the dimension of the code.

## ◆ encode()

std::vector< uint8_t > cldpc::encode | ( | std::vector< uint8_t > | dataword | ) |

Encode the given vector dataword.

dataword is of length K where K is the dimension of the code. The function returns a vector of length N where N is the block-length of the code.

For encoding a G matrix in the form [I P] is obtained from the parity matrix H, by (a) Column permutations, (b) Row additions and (c) Row permutations. Details of encoding is given in section A.1 of the reference given below.

- "Modern Coding Theory", T Richardson and R Urbanke.

## ◆ get_G()

GF2Mat cldpc::get_G | ( |  | ) |

Returns the matrix G used in encoding.

## ◆ get_H()

GF2Mat cldpc::get_H | ( |  | ) |

Returns the parity check matrix H.

## ◆ get_M()

int cldpc::get_M | ( |  | ) |

Returns the variable M.

## ◆ get_N()

int cldpc::get_N | ( |  | ) |

Returns the variable N.

## ◆ get_systematic_bits()

std::vector< uint8_t > cldpc::get_systematic_bits | ( | std::vector< uint8_t > | in | ) |

Obtain systematic bits from "in".

## ◆ is_codeword()

bool cldpc::is_codeword | ( | const std::vector< uint8_t > | in | ) |

Returns true if "in" is a codeword, else false.

## ◆ print_permute()

void cldpc::print_permute | ( |  | ) |

Prints the variable permute.

## ◆ set_alist()

void cldpc::set_alist | ( | const alist | _list | ) |

Set the variable _list.

## ◆ syndrome()

std::vector< uint8_t > cldpc::syndrome | ( | const std::vector< uint8_t > | in | ) |

Returns the syndrome for a given vector "in".

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

- cldpc.h