-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
42 changed files
with
395 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
clear all | ||
clc | ||
close all | ||
%Ingreso de parametros para la simulacion: | ||
Eb=10; %Energia de bit | ||
Rb=100; %Tasa de bit | ||
|
||
Es=3*Eb; %Energia de simbolo -> 8-DPSK | ||
Rs=Rb/3; %Tasa de simbolo | ||
CantSimb=1002; %Cantidad de simbolos influye brutalmente para obtener las curvas. | ||
CantBit=CantSimb*3; %Cantidad de bits necesarios de simular para la cantidad de simbolos | ||
|
||
Fp=10*Rb; %Frecuencia de la portadora | ||
|
||
Pot=Es*Rs; %Potencia de cada uno de los simbolos | ||
|
||
Fs=500000; %Frecuencia de muestreo para observar señales en el canal de comunicaciones (Salida Modulador) | ||
|
||
%----------------------- | ||
EsNoTest=[1:16]; %Valores de Es/No para el bloque AWGN | ||
EsNo=[]; | ||
ErrorFinalSimb=[]; | ||
ErrorFinalBit=[]; | ||
EbNo=[]; | ||
%----------------------- | ||
for j=1:length(EsNoTest) | ||
EsNo=EsNoTest(j); | ||
EbNo(j)=EsNo - 10*log10(3); | ||
sim('MDPSK') | ||
CantErrS=0; | ||
ErrorT=Err'; | ||
for i=3:length(ErrorT) | ||
if(ErrorT(i) ~= 0) | ||
CantErrS=CantErrS+1; | ||
end | ||
end | ||
|
||
ErrorFinalSimb(j)=CantErrS/(CantSimb-2) %Cantidad de simbolos errados respecto a los totales PE | ||
ErrorFinalBit(j)=ErrorFinalSimb(j)/3 %Cantidad de bit erroneos respecto a los bit de informacion PB | ||
%Se usa codificacion de Gray | ||
|
||
end | ||
|
||
ber = berawgn(EbNo,'dpsk',8); | ||
semilogy(EbNo,ber) | ||
hold on | ||
semilogy(EbNo,ErrorFinalBit) | ||
xlabel('Eb/No (dB)') | ||
ylabel('BER') |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+392 Bytes
Proyecto/Archivos 8DPSK/slprj/sim/varcache/MDPSK/checksumOfCache.mat
Binary file not shown.
6 changes: 6 additions & 0 deletions
6
Proyecto/Archivos 8DPSK/slprj/sim/varcache/MDPSK/tmwinternal/simulink_cache.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<MF0 version="1.1" packageUris="http://schema.mathworks.com/mf0/SlCache/19700101"> | ||
<slcache.FileAttributes type="slcache.FileAttributes" uuid="5b24b59a-873d-457c-8bf6-1450c9bd4cd1"> | ||
<checksum>mIK/0TRlXX1gm9ybQouM+g==</checksum> | ||
</slcache.FileAttributes> | ||
</MF0> |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
clear all | ||
clc | ||
close all | ||
%Ingreso de parametros para la simulacion: | ||
Eb=10; %Energia de bit | ||
Rb=100; %Tasa de bit | ||
|
||
Es=1*Eb; %Energia de simbolo -> 8-DPSK | ||
Rs=Rb/1; %Tasa de simbolo | ||
CantSimb=12; %Cantidad de simbolos influye brutalmente para obtener las curvas. | ||
CantBit=CantSimb*1; %Cantidad de bits necesarios de simular para la cantidad de simbolos | ||
|
||
Fp=10*Rb; %Frecuencia de la portadora | ||
|
||
Pot=Es*Rs; %Potencia de cada uno de los simbolos | ||
|
||
%----------------------- | ||
EsNoTest=[1:25]; %Valores de Es/No para el bloque AWGN | ||
EsNo=[]; | ||
ErrorFinalSimbNOpt=[]; | ||
ErrorFinalBitNOpt=[]; | ||
ErrorFinalSimbOpt=[]; | ||
ErrorFinalBitOpt=[]; | ||
EbNo=[]; | ||
%----------------------- | ||
for j=1:length(EsNoTest) | ||
EsNo=EsNoTest(j); | ||
EbNo(j)=EsNo - 10*log10(1); | ||
sim('DBPSK_FormaEficiente') | ||
CantErrSOpt=0; | ||
CantErrSNOpt=0; | ||
ErrorTOpt=ErrOpt(1000/2:1000:length(ErrOpt)-(1000/2))'; %Producto de la integracion/retencion y reset me quedan picos que me confunden en las decisiones, diezmo la señal | ||
ErrorTNOpt=ErrNOpt(1000/2:1000:length(ErrOpt)-(1000/2))'; | ||
|
||
for i=3:length(ErrorTOpt) | ||
if(ErrorTOpt(i) ~= 0) | ||
CantErrSOpt=CantErrSOpt+1; | ||
end | ||
end | ||
|
||
for i=3:length(ErrorTNOpt) | ||
if(ErrorTNOpt(i) ~= 0) | ||
CantErrSNOpt=CantErrSNOpt+1; | ||
end | ||
end | ||
|
||
ErrorFinalSimbOpt(j)=CantErrSOpt/(CantSimb-2) %Cantidad de simbolos errados respecto a los totales PE | ||
ErrorFinalBitOpt(j)=ErrorFinalSimbOpt(j)/1 %Cantidad de bit erroneos respecto a los bit de informacion PB | ||
%Se usa codificacion de Gray | ||
|
||
ErrorFinalSimbNOpt(j)=CantErrSNOpt/(CantSimb-2); | ||
ErrorFinalBitNOpt(j)=ErrorFinalSimbNOpt(j)/1; | ||
end | ||
|
||
ber = berawgn(EbNo,'dpsk',2); | ||
semilogy(EbNo,ber) | ||
hold on | ||
semilogy(EbNo,ErrorFinalBitOpt) | ||
xlabel('Eb/No (dB)') | ||
ylabel('BER') | ||
hold on | ||
semilogy(EbNo,ErrorFinalBitNOpt) |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+392 Bytes
.../Archivos DPSK coherentemente/slprj/sim/varcache/DBPSK_FormaEficiente/checksumOfCache.mat
Binary file not shown.
6 changes: 6 additions & 0 deletions
6
...PSK coherentemente/slprj/sim/varcache/DBPSK_FormaEficiente/tmwinternal/simulink_cache.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<MF0 version="1.1" packageUris="http://schema.mathworks.com/mf0/SlCache/19700101"> | ||
<slcache.FileAttributes type="slcache.FileAttributes" uuid="0531551f-6a66-43af-b207-5f14b9edade7"> | ||
<checksum>agSzt0sB45NJ+/e/efuxuw==</checksum> | ||
</slcache.FileAttributes> | ||
</MF0> |
Binary file added
BIN
+2 KB
Proyecto/Archivos DPSK coherentemente/slprj/sim/varcache/DBPSK_FormaEficiente/varInfo.mat
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
clear all | ||
clc | ||
close all | ||
%Ingreso de parametros para la simulacion: | ||
Eb=10; %Energia de bit | ||
Rb=100; %Tasa de bit | ||
|
||
Es=2*Eb; %Energia de simbolo -> 8-DPSK | ||
Rs=Rb/2; %Tasa de simbolo | ||
CantSimb=102; %Cantidad de simbolos influye brutalmente para obtener las curvas. | ||
CantBit=CantSimb*2; %Cantidad de bits necesarios de simular para la cantidad de simbolos | ||
|
||
Fp=10*Rb; %Frecuencia de la portadora | ||
|
||
Pot=Es*Rs; %Potencia de cada uno de los simbolos | ||
|
||
Fs=500000; %Frecuencia de muestreo para observar señales en el canal de comunicaciones (Salida Modulador) | ||
|
||
%----------------------- | ||
EsNoTest=[1:16]; %Valores de Es/No para el bloque AWGN | ||
EsNo=[]; | ||
ErrorFinalSimb=[]; | ||
ErrorFinalBit=[]; | ||
EbNo=[]; | ||
%----------------------- | ||
for j=1:length(EsNoTest) | ||
EsNo=EsNoTest(j); | ||
EbNo(j)=EsNo - 10*log10(2); | ||
sim('QDPSK') | ||
CantErrS=0; | ||
ErrorT=Err'; | ||
for i=3:length(ErrorT) | ||
if(ErrorT(i) ~= 0) | ||
CantErrS=CantErrS+1; | ||
end | ||
end | ||
|
||
ErrorFinalSimb(j)=CantErrS/(CantSimb-2) %Cantidad de simbolos errados respecto a los totales PE | ||
ErrorFinalBit(j)=ErrorFinalSimb(j)/2 %Cantidad de bit erroneos respecto a los bit de informacion PB | ||
%Se usa codificacion de Gray | ||
|
||
end | ||
|
||
ber = berawgn(EbNo,'dpsk',4); | ||
semilogy(EbNo,ber) | ||
hold on | ||
semilogy(EbNo,ErrorFinalBit) | ||
xlabel('Eb/No (dB)') | ||
ylabel('BER') |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+392 Bytes
Proyecto/Archivos QDPSK/slprj/sim/varcache/QDPSK/checksumOfCache.mat
Binary file not shown.
6 changes: 6 additions & 0 deletions
6
Proyecto/Archivos QDPSK/slprj/sim/varcache/QDPSK/tmwinternal/simulink_cache.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<MF0 version="1.1" packageUris="http://schema.mathworks.com/mf0/SlCache/19700101"> | ||
<slcache.FileAttributes type="slcache.FileAttributes" uuid="589a8392-2061-4e25-a80f-6fd2a412eb1e"> | ||
<checksum>6Ly/6QphRAel47hac1IYIQ==</checksum> | ||
</slcache.FileAttributes> | ||
</MF0> |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
%Ingreso de parametros para la simulacion: | ||
Eb=EbPerf; %Energia de bit | ||
Rb=RbPerf; %Tasa de bit | ||
|
||
Es=1*Eb; %Energia de simbolo -> 8-DPSK | ||
Rs=Rb/1; %Tasa de simbolo | ||
CantSimb=CantSimbPerf; %Cantidad de simbolos influye brutalmente para obtener las curvas. | ||
CantBit=CantSimb*1; %Cantidad de bits necesarios de simular para la cantidad de simbolos | ||
|
||
Fp=10*Rb; %Frecuencia de la portadora | ||
|
||
Pot=Es*Rs; %Potencia de cada uno de los simbolos | ||
|
||
%----------------------- | ||
EsNoTest=EsNoTestPerf; %Valores de Es/No para el bloque AWGN | ||
EsNo=[]; | ||
ErrorFinalSimbNOpt=[]; | ||
ErrorFinalBitNOpt=[]; | ||
ErrorFinalSimbOpt=[]; | ||
ErrorFinalBitOpt=[]; | ||
EbNo=[]; | ||
%----------------------- | ||
fprintf("---\t --- \t DBPSK \t --- \t --- \n") | ||
for j=1:length(EsNoTest) | ||
fprintf("Simulacion BDPSK N: %i / %i \n",j,length(EsNoTest)) | ||
EsNo=EsNoTest(j); | ||
EbNo(j)=EsNo - 10*log10(1); | ||
sim('DBPSK_FormaEficiente'); | ||
CantErrSOpt=0; | ||
CantErrSNOpt=0; | ||
ErrorTOpt=ErrOpt(1000/2:1000:length(ErrOpt)-(1000/2))'; %Producto de la integracion/retencion y reset me quedan picos que me confunden en las decisiones, diezmo la señal | ||
ErrorTNOpt=ErrNOpt(1000/2:1000:length(ErrOpt)-(1000/2))'; | ||
|
||
for i=3:length(ErrorTOpt) | ||
if(ErrorTOpt(i) ~= 0) | ||
CantErrSOpt=CantErrSOpt+1; | ||
end | ||
end | ||
|
||
for i=3:length(ErrorTNOpt) | ||
if(ErrorTNOpt(i) ~= 0) | ||
CantErrSNOpt=CantErrSNOpt+1; | ||
end | ||
end | ||
|
||
ErrorFinalSimbOpt(j)=CantErrSOpt/(CantSimb-2); %Cantidad de simbolos errados respecto a los totales PE | ||
ErrorFinalBitOpt(j)=ErrorFinalSimbOpt(j)/1; %Cantidad de bit erroneos respecto a los bit de informacion PB | ||
%Se usa codificacion de Gray | ||
|
||
ErrorFinalSimbNOpt(j)=CantErrSNOpt/(CantSimb-2); | ||
ErrorFinalBitNOpt(j)=ErrorFinalSimbNOpt(j)/1; | ||
end | ||
fprintf("---\t --- \t Termino DBPSK \t --- \t --- \n") | ||
%ber = berawgn(EbNo,'dpsk',2); | ||
%semilogy(EbNo,ber) | ||
%hold on | ||
%semilogy(EbNo,ErrorFinalBitOpt) | ||
%xlabel('Eb/No (dB)') | ||
%ylabel('BER') | ||
%hold on | ||
%semilogy(EbNo,ErrorFinalBitNOpt) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
%Ingreso de parametros para la simulacion: | ||
Eb=EbPerf; %Energia de bit | ||
Rb=RbPerf; %Tasa de bit | ||
|
||
Es=3*Eb; %Energia de simbolo -> 8-DPSK | ||
Rs=Rb/3; %Tasa de simbolo | ||
CantSimb=CantSimbPerf; %Cantidad de simbolos influye brutalmente para obtener las curvas. | ||
CantBit=CantSimb*3; %Cantidad de bits necesarios de simular para la cantidad de simbolos | ||
|
||
Fp=10*Rb; %Frecuencia de la portadora | ||
|
||
Pot=Es*Rs; %Potencia de cada uno de los simbolos | ||
|
||
Fs=FsPerf; %Frecuencia de muestreo para observar señales en el canal de comunicaciones (Salida Modulador) | ||
|
||
%----------------------- | ||
EsNoTest=EsNoTestPerf + 10*log10(3); %Valores de Es/No para el bloque AWGN | ||
EsNo=[]; | ||
ErrorFinalSimb=[]; | ||
ErrorFinalBit=[]; | ||
EbNo=[]; | ||
%----------------------- | ||
fprintf("---\t --- \t 8DPSK \t --- \t --- \n") | ||
for j=1:length(EsNoTest) | ||
fprintf("Simulacion 8DPSK N: %i / %i \n",j,length(EsNoTest)) | ||
EsNo=EsNoTest(j); | ||
EbNo(j)=EsNo - 10*log10(3); | ||
sim('MDPSK'); | ||
CantErrS=0; | ||
ErrorT=Err'; | ||
for i=3:length(ErrorT) | ||
if(ErrorT(i) ~= 0) | ||
CantErrS=CantErrS+1; | ||
end | ||
end | ||
|
||
ErrorFinalSimb(j)=CantErrS/(CantSimb-2); %Cantidad de simbolos errados respecto a los totales PE | ||
ErrorFinalBit(j)=ErrorFinalSimb(j)/3 ; %Cantidad de bit erroneos respecto a los bit de informacion PB | ||
%Se usa codificacion de Gray | ||
|
||
end | ||
fprintf("---\t --- \t Termino 8DPSK \t --- \t --- \n") | ||
%ber = berawgn(EbNo,'dpsk',8); | ||
%semilogy(EbNo,ber) | ||
%hold on | ||
%semilogy(EbNo,ErrorFinalBit) | ||
%xlabel('Eb/No (dB)') | ||
%ylabel('BER') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
%Ingreso de parametros para la simulacion: | ||
Eb=EbPerf; %Energia de bit | ||
Rb=RbPerf; %Tasa de bit | ||
|
||
Es=2*Eb; %Energia de simbolo -> 8-DPSK | ||
Rs=Rb/2; %Tasa de simbolo | ||
CantSimb=CantSimbPerf;%Cantidad de simbolos influye brutalmente para obtener las curvas. | ||
CantBit=CantSimb*2; %Cantidad de bits necesarios de simular para la cantidad de simbolos | ||
|
||
Fp=10*Rb; %Frecuencia de la portadora | ||
|
||
Pot=Es*Rs; %Potencia de cada uno de los simbolos | ||
|
||
Fs=FsPerf; %Frecuencia de muestreo para observar señales en el canal de comunicaciones (Salida Modulador) | ||
|
||
%----------------------- | ||
EsNoTest=EsNoTestPerf + 10*log10(2); %Valores de Es/No para el bloque AWGN | ||
EsNo=[]; | ||
ErrorFinalSimb=[]; | ||
ErrorFinalBit=[]; | ||
EbNo=[]; | ||
%----------------------- | ||
fprintf("---\t --- \t QDPSK \t --- \t --- \n") | ||
for j=1:length(EsNoTest) | ||
fprintf("Simulacion DQPSK N: %i / %i \n",j,length(EsNoTest)) | ||
EsNo=EsNoTest(j); | ||
EbNo(j)=EsNo - 10*log10(2); | ||
sim('QDPSK'); | ||
CantErrS=0; | ||
ErrorT=Err'; | ||
for i=3:length(ErrorT) | ||
if(ErrorT(i) ~= 0) | ||
CantErrS=CantErrS+1; | ||
end | ||
end | ||
|
||
ErrorFinalSimb(j)=CantErrS/(CantSimb-2); %Cantidad de simbolos errados respecto a los totales PE | ||
ErrorFinalBit(j)=ErrorFinalSimb(j)/2 ; %Cantidad de bit erroneos respecto a los bit de informacion PB | ||
%Se usa codificacion de Gray | ||
|
||
end | ||
fprintf("---\t --- \t Termino QDPSK \t --- \t --- \n") | ||
%ber = berawgn(EbNo,'dpsk',4); | ||
%semilogy(EbNo,ber) | ||
%hold on | ||
%semilogy(EbNo,ErrorFinalBit) | ||
%xlabel('Eb/No (dB)') | ||
%ylabel('BER') |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
warning('off','all') | ||
EbPerf=10; | ||
RbPerf=100; | ||
FsPerf=100000; | ||
CantSimbPerf=2002; | ||
EsNoTestPerf=[1:0.5:14]; | ||
%Ejecucion de simulink | ||
BDPSK | ||
%Variables BDPSK | ||
PerfDBPSKEbNo=EbNo; | ||
PerfDBPSKOpt=ErrorFinalBitOpt; | ||
PerfDBPSKNOpt=ErrorFinalBitNOpt; | ||
CodigoQDPSK | ||
%Variables QDPSK | ||
PerfQDPSKEbNo=EbNo; | ||
PerfQDPSK=ErrorFinalBit; | ||
%Variables 8DPSK | ||
Codigo8DPSK | ||
Perf8DPSKEbNo=EbNo; | ||
Perf8DPSK=ErrorFinalBit; | ||
figure() | ||
%Graficas teoricas | ||
berDBPSK = berawgn(PerfDBPSKEbNo,'dpsk',2); | ||
semilogy(PerfDBPSKEbNo,berDBPSK) | ||
hold on | ||
berDQPSK = berawgn(PerfQDPSKEbNo,'dpsk',4); | ||
semilogy(PerfQDPSKEbNo,berDQPSK) | ||
hold on | ||
ber8DPSK = berawgn(Perf8DPSKEbNo,'dpsk',8); | ||
semilogy(Perf8DPSKEbNo,ber8DPSK) | ||
legend('BDPSK','QDPSK','8DPSK') | ||
%Graficas obtenidas mediante simulacion | ||
figure() | ||
semilogy(PerfDBPSKEbNo,PerfDBPSKOpt) | ||
hold on | ||
semilogy(PerfDBPSKEbNo,PerfDBPSKNOpt) | ||
hold on | ||
semilogy(PerfQDPSKEbNo,PerfQDPSK) | ||
hold on | ||
semilogy(Perf8DPSKEbNo,Perf8DPSK) | ||
legend('BDPSKef','BDPSKnef','QDPSK','8DPSK') | ||
warning('on','all') |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+392 Bytes
Proyecto/Performance/slprj/sim/varcache/DBPSK_FormaEficiente/checksumOfCache.mat
Binary file not shown.
Oops, something went wrong.