Giter Site home page Giter Site logo

rs_matlab's Introduction

All this MATLAB 2011 code is my attempt to make simple Reed-Solomon coder/decoder over GF(2^m)
This implementation isn't designed to be FAST. My main consideration was:
			"readability >> optimization"

Therefore, it is really slow compared to RS decoders used in production :)

Brief description follows
GF related:
-gf_calculate_mt - compute multiplication table for finite field extension GF(2^m)
-gf_calculate_pt - compute powers and logarithms table for specified element from GF(2^m)

All following functions use powers table obtained from gf_calculate_pt()
gf_div, gf_mul - fast division and multiplication in GF(2^m)
gf_el_order - compute order of finite field element

Polynomials (all polymials are defined over GF(2^m), where m can be 1):
poly_div - division with remainder
poly_mul - multiplication
poly_sum - sum of polynomials
poly_eval - evaluate polynomial inf GF(2^m) at point X, X belongs to GF(2^m)
poly_nonzero - test polynomial for non-zeroness (similar to nnz())
poly_trim - trim highest powers with zero coefficients
poly_xn - construct polynomial p(x) = x^n
poly_diff - compute formal derivative p'(x) over GF(2^m)
poly_gcd - find greatest common divisor of polynomials using Euclid's algorithm

LFSR (LFSR stands for Linear Feedback Shift Register):
berlekamp - compute minimal LFSR that generates specified sequence using Berlekamp-Massey algorithm.
	Throws "division by 0" if first sequence element is zero!
lfsr_test - compute first N elements of sequence generated by supplied LFSR

Reed-Solomon:
rs_generator - compute RS over GF(2^m) generator polynomial which provides specified Dmin
rs_encode - systematically encode some data block (symbols are elements of GF(2^m)) in RS code
rs_decode - try to decode received RS code word and correct errors. Uses Berlekamp-Massey algorithm
	to compute locator polynomial L(x), Chien search to find its roots, and Forney algorithm
	to find exact error values.
rs_test - demonstrative test:
	random data -> encode -> +random errors -> decode -> test for data correctness

To see something that all this stuff can do, just run rs_test()

(C) Roman Dobrodiy

rs_matlab's People

Contributors

romavis avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.