A C-language implementation for simulating the encoding and decoding of zipper codes, a family of spatially-coupled product-like codes with algebraic decoding. For more information about zipper codes, you can read our paper here or the author's Master's thesis here.
The program will work correctly under the assumption that:
Here. Since this package uses a PCG Random Number Generator, you will also need to download the C Implementation (not the minimal C Implementation) of the PCG family of pseudorandom number generators, available here.
After unzipping, simply follow the instructions in the file README
.
Download the code and build it by following the following commands:
tar -xzf ZipperSim.tar.gz
cd ZipperSim
make
Then you can run the simulator by using command
./main config_filename chunk_size crossover_probability
The user needs to provide a configuration file containing the code parameters and interleaver map for config_file
. Samples of configuration files are available in the directory config_files
. For example:
./main config_files/GF128/delayed_diag_62.txt 62 3.3e-2
./main config_files/GF256/staircase_125.txt 125 1.7e-2
In order to use different error-locator field and generator polynomial for the simulation, comment and uncomment the lines indicated in bch.c
and recompile.
The program will run until MAX_ERROR
errors are collected. To specify the MAX_ERROR
parameter, edit the line containing #define MAX_ERROR
in main.c
.
The file will have the following format:
period nu
n n[0] n[1] ... n[nu-1]
k k[0] k[1] ... k[nu-1]
m m[0] m[1] ... m[nu-1]
buffer_len buflen
interleaver map
(0-phi_1(0,0)) phi_2(0,0) (0-phi_1(0,1)) phi_2(0,1) ... (0-phi_1(0,m[0]-1)) phi_2(0,m[0]-1)
(1-phi_1(1,0)) phi_2(1,0) (1-phi_1(1,1)) phi_2(1.1) ... (1-phi_1(1,m[1]-1)) phi_2(1,m[1]-1)
...
((nu-1)-phi_1(nu-1,0)) phi_2(nu-1,0) ((nu-1)-phi_1(nu-1,1)) phi_2(nu-1,1) ... ((nu-1)-phi_1(nu-1,m[nu-1]-1)) phi_2(nu-1,m[nu-1]-1)
Here, phi
denotes the interleaver map, while phi_1
and phi_2
respectively denote the first and second coordinates of the output of the interleaver map.
For example, if phi(1,2)=(3,4)
, then phi_1(1,2)=3
while phi_2(1,2)=4
.
n
, k
, and m
is space-separated. The first row of the interleaver map is in a new line after interleaver_map
and each entry is also space-separated.