% plot_LinearModSinc - test linear modulation with rectangular pulse

%% Parameters:
fsT      = 20;
L        = 10;
Alphabet = [1,-1];
Priors   = 0.5*[1 1];
Ns       = 10;               % number of symbols
Pulse    = Sinc( L, fsT);    % sinc pulse

%% symbols and Signal using our functions
Symbols = RandomSymbols(Ns, Alphabet, Priors);
Signal  = LinearModulation(Symbols,Pulse,fsT);
%% plot
tt = (0 : length(Signal)-1 )/fsT;
plot(tt, Signal,(L/2:L/2+Ns-1), Symbols,'ro')
grid
xlabel('Time/T')
ylabel('Amplitude')

%% Store name of script for automated figure generation
ScriptName = mfilename;