%% Generate LDPC Codeword
% Create input data for encoding consisting of two code block segments of length 2560 and 36 filler bits at the end.

C = 2;          
K = 2560;       
F = 36;         
cbs = ones(K-F,C);
fillers = -1*ones(F,C);
cbs = [cbs;fillers];   

% Generate LDPC codeword for the two code block segments. Use base graph number two.

bgn = 2;        
codedcbs = nrLDPCEncode(cbs,bgn);
size(codedcbs)

% Copyright 2018 The MathWorks, Inc.