LDPC-Config-MATLAB
Version 1.0 (8.53 KB) by
Zakir Hussain
Generates WLAN LDPC config variables in the format supported by ldpcEncode() and ldpcDecode() functions of MATLAB (supported from 2021b)
% This code package contains a helper function generateConfigLDPC() which generates LDPC config struct variables in % the format supported by ldpcEncode() and ldpcDecode() functions of % MATLAB (supported from 2021b) https://se.mathworks.com/matlabcentral/fileexchange/103360-matlab-ldpc-config % This function is intended for those who wants to use LDPC coding function without having to worry about % parity check matrices and details. Currently LDPC codes from WLAN standard are supported in this function. % Author: Zakir Hussain Shaik % Contact: zakir.b2a@gmail.com % This function is version 1.0 % License: This code is licensed under the GPLv2 license. % This function outputs two outputs % First output : cfgLDPCEnc % Second output: decodercfg % These variables can be directly used with MATLAB functions ldpcEncode() and ldpcDecode() as per their corresponding syntaxes % This function accepts minimum one and maximum four inputs where three inputs are % optional. % First input : rate -- code rate (Mandtory Input) % Second input : codeword length (If given must be second input) % Third input : 'standard'-- 'wlan' (this input is name-value type) % Fourth input : 'decoderAlgo' -- decoding algorithm (this input is name-value type) % Second, third and fourth inputs are optional. However, if codeword length % is provided as input it should be in the second argument only. % Third and fourth arguments are of name-value format and can be given in % any order % Default values: standard is 'wlan', code word length is 648, decoder algorithm is 'bp' % Supported standard: 'wlan' % Supported rates: 1/2, 2/3, 3/4, and 5/6 % Supported codeword lengths: 648, 1296, and 1944 % decoderAlgo takes four algorithms as stated in MATLAB site: {'bp','layered-bp','norm-min-sum','offset-min-sum'} % This file is accompanied with example scripts % Following syntaxes are supported: % Example 1: rate = 1/2; [cfgLDPCEnc,decodercfg] = generateConfigLDPC(rate,'decoderAlgo','bp'); % Example 2: rate = 1/2; n = 1944; [cfgLDPCEnc,decodercfg] = generateConfigLDPC(rate,n,'decoderAlgo','norm-min-sum'); % Example 3: rate = 1/2; n = 1944; [cfgLDPCEnc,decodercfg] = generateConfigLDPC(rate,n,'decoderAlgo','norm-min-sum','standard','wlan'); % Example 4 rate = 3/4; % code rate n = 1296; % Codeword length decodAlgo = 'offset-min-sum'; % LDPC decoding algorithm [cfgLDPCEnc,decodercfg] = generateConfigLDPC(rate,n,'decoderAlgo',decodAlgo,'standard','wlan');
Cite As
Z. H. Shaik. MATLAB-LDPC-Config (https://github.com/zakirhussainshaik/MATLAB-LDPC-Config/releases/tag/v1.0), GitHub. Retrieved December 10, 2021.
MATLAB Release Compatibility
Created with
R2021b
Compatible with R2021b and later releases
Platform Compatibility
Windows macOS LinuxTags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
Version | Published | Release Notes | |
---|---|---|---|
1.0 |
To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.