This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <itpp/itcomm.h> | |
#include <itpp/itmex.h> | |
using namespace itpp; | |
void mexFunction(int n_output, mxArray *output[], int n_input, const mxArray *input[]) { | |
// Check the number of inputs and output arguments | |
if(n_output!=1) mexErrMsgTxt("Wrong number of output variables!"); | |
if(n_input!=1) mexErrMsgTxt("Wrong number of input variables!"); | |
// Convert input variables to IT++ format | |
bvec input_bits = mxArray2bvec(input[0]); | |
// - - - - - - - - - Start of routine - - - - - - - - - - - - - - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from pyitpp import itload | |
from matplotlib.pyplot import * | |
out = itload('pccc_bersim_awgn.it') | |
semilogy(out['EbN0_dB'], out['BER'].T, 'o-') | |
grid() | |
xlabel('$E_b/N_0 [dB]$') |