This program simulates Serially Concatenated Convolutional Codes (SCCCs) of coding rate 1/4 using a turbo decoder with a SISO NSC module and a SISO RSC module.
Reference: S. Benedetto, D. Divsalar, G. Motorsi and F. Pollara, "A Soft-Input Soft-Output Maximum A posteriori (MAP) Module to Decode Parallel and Serial Concatenated Codes", TDA Progress Report, nov. 1996
using std::cout;
using std::endl;
using std::string;
{
ivec gen = "07 05";
double R = 1.0 / 4.0;
double Ec = 1.0;
vec sigma2 = (0.5 * Ec / R) * pow(inv_dB(
EbN0_dB), -1.0);
double Lc;
RNG_randomize();
{
{
}
{
}
}
}
return 0;
}
Ordinary AWGN Channel for cvec or vec inputs and outputs.
Array< T > left(int n) const
Get n left elements of the array.
int length() const
Returns the number of data elements in the array object.
Bit Error Rate Counter (BERC) Class.
BPSK modulator with real symbols.
void modulate_bits(const bvec &bits, vec &output) const
Modulate bits into BPSK symbols in complex domain.
void demodulate_bits(const vec &signal, bvec &output) const
Demodulate noisy BPSK symbols in complex domain into bits.
Binary Convolutional rate 1/n class.
void encode_tail(const bvec &input, bvec &output)
Encoding that starts and ends in the zero state.
void set_generator_polynomials(const ivec &gen, int constraint_length)
Set generator polynomials. Given in Proakis integer form.
Automatic naming when saving.
A Recursive Systematic Convolutional Encoder/Decoder class.
void set_generator_polynomials(const ivec &gen, int constraint_length)
Set generator polynomials.
void encode(const bvec &input, bmat &parity_bits)
Encode a binary vector of inputs starting from zero state without adding of a tail.
Soft Input Soft Output (SISO) modules.
The IT++ file format reading and writing class.
Include file for the IT++ communications module.
Mat< bin > bmat
bin matrix
When you run this program, the results (BER and EbN0_dB) are saved into sccc_bersim_awgn.it file. Using the following MATLAB script
clear all
itload('sccc_bersim_awgn.it');
figure
semilogy(EbN0_dB, BER, 'o-')
grid on
xlabel('E_b/N_0 [dB]')
ylabel('BER')
the results can be displayed.