renamed PolarCodeConst0 to BhattacharyyaFreezer

This commit is contained in:
Ahmet Inan 2026-02-13 12:47:55 +01:00
commit 72e5b2240a
3 changed files with 4 additions and 4 deletions

View file

@ -89,7 +89,7 @@ Encoder for [augmented Hadamard codes](https://en.wikipedia.org/wiki/Hadamard_co
Bit freezers for the construction of [polar codes](https://en.wikipedia.org/wiki/Polar_code_(coding_theory)). Bit freezers for the construction of [polar codes](https://en.wikipedia.org/wiki/Polar_code_(coding_theory)).
* PolarFreezer: Constructs code for a given erasure probability without the need for storing nor sorting of erasure probabilities for the virtual channels. * PolarFreezer: Constructs code for a given erasure probability without the need for storing nor sorting of erasure probabilities for the virtual channels.
* PolarCodeConst0: Constructs code by choosing the K best virtual channels computed from a given erasure probability. * BhattacharyyaFreezer: Constructs code by choosing the K best virtual channels computed from a given erasure probability.
### [polar_sequence.hh](polar_sequence.hh) ### [polar_sequence.hh](polar_sequence.hh)

View file

@ -43,7 +43,7 @@ public:
}; };
template <int MAX_M> template <int MAX_M>
class PolarCodeConst0 class BhattacharyyaFreezer
{ {
static void inform_bit(uint32_t *bits, int idx) static void inform_bit(uint32_t *bits, int idx)
{ {

View file

@ -50,8 +50,8 @@ int main()
std::cerr << "better SNR: " << better_SNR << std::endl; std::cerr << "better SNR: " << better_SNR << std::endl;
double probability = std::exp(-pow(10.0, better_SNR / 10)); double probability = std::exp(-pow(10.0, better_SNR / 10));
if (1) { if (1) {
auto freeze = new CODE::PolarCodeConst0<M>; auto freeze = new CODE::BhattacharyyaFreezer<M>;
std::cerr << "sizeof(PolarCodeConst0<M>) = " << sizeof(CODE::PolarCodeConst0<M>) << std::endl; std::cerr << "sizeof(BhattacharyyaFreezer<M>) = " << sizeof(CODE::BhattacharyyaFreezer<M>) << std::endl;
(*freeze)(frozen, M, K, probability); (*freeze)(frozen, M, K, probability);
delete freeze; delete freeze;
} else { } else {