-
Notifications
You must be signed in to change notification settings - Fork 0
/
SER.m
22 lines (21 loc) · 683 Bytes
/
SER.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
% ///////////////////Probabilidad de error de símbolo\\\\\\\\\\\\\\\\\\\\\\
% Entradas:
% X -> señal a la entrada del emisor
% Y -> salida del receptor
% N -> número de portadoras
% samples -> muestras totales que se transmiten
% Salidas:
% ser -> probabilidad de error de símbolo
% /////////////////////////////////////////////////////////////////////////
function ser = SER(X,Y,N,samples)
ser = 0;
for i = 1:samples
for n = 1:N
if (real(X(n,i))*real(Y(n,i)) <= 0) || ...
(imag(X(n,i))*imag(Y(n,i)) <= 0)
ser = ser + 1;
end
end
end
ser = (ser/(samples*N))*100;
end