2 Usage
(require reed-solomon) | package: reed-solomon |
procedure
(rs-encode data_list parity_length [ #:bit_width bit_width #:primitive_poly_value primitive_poly_value #:express? express? #:express_path express_path]) → (listof exact-integer?) data_list : (listof exact-integer?) parity_length : natural? bit_width : natural? = 8 primitive_poly_value : natural? = 285 express? : boolean? = #f express_path : path-string? = ".encode.express"
parity_length is user defined, (floor (/ parity_length 2)) is recovery capacity.
ie: parity_length is 4, it can recover 2 symbols at most.
bit_width: from 2 - 32
primitive_poly_value: each bit width has multiple available primitive values.
encode and decode should use the same primitive poly value.
2-32 bits available primitive value table
set #:express? to true will generate a detail report in express_path.
scribble --htmls report.scrbl |
Warning: express will generate a set of scribble files, it’s very slow, debug usage only.
procedure
(rs-decode data_list parity_length [ #:bit_width bit_width #:primitive_poly_value primitive_poly_value #:express? express? #:express_path express_path]) → (listof exact-integer?) data_list : (listof exact-integer?) parity_length : natural? bit_width : natural? = 8 primitive_poly_value : natural? = 285 express? : boolean? = #f express_path : path-string? = ".encode.express"
parity_length, bit_width, primitive_poly_value should be consistent as encode.
set #:express? to true will generate a detail report in express_path.
scribble --htmls report.scrbl |
Warning: express will generate a set of scribble files, it’s very slow, debug usage only.