Category: News
Simulink build TI CCS Project error.
Post Content Post Content ccs ti MATLAB Answers — New Questions
Equivalence of MSK and Offset QPSK
Hi everyone,
i’m currently trying to create a offset QPSK modulation using an MSK with a half-sine matched filter. This is based on the IEEE paper https://ieeexplore.ieee.org/document/4102435. I generated an OQPSK and MSK signal with MATLAB and plotted the angle of the signal. Both can be seen below. There is no frequency error or noise. They spectrum for both is the same and the amplitude of the symbol stays constant, so this is indeed a OQPSK signal. Just the resulting bits are different.
I can demodulated the OQPSK using the OQPSK demodulation function from the Communications Toolbox as well as the with the symbol order based on the phase seen in the picture. So the OQPSK is correct. I can also demodulate the MSK with a normal FSK demodulater and the ouput is the same as with the OQPSK. But when applying any kinf of OQPSK demodulation to the MSK signal the resulting sequence is different as well as the phase (picture).
So is a MSK with Half-Sine Filter really equivalent to an OQPSK and both can be received with the same receiver?
This is the phase of the MSK signal
And this is the phase of the OQPSK signal
Best Regards,
AxelHi everyone,
i’m currently trying to create a offset QPSK modulation using an MSK with a half-sine matched filter. This is based on the IEEE paper https://ieeexplore.ieee.org/document/4102435. I generated an OQPSK and MSK signal with MATLAB and plotted the angle of the signal. Both can be seen below. There is no frequency error or noise. They spectrum for both is the same and the amplitude of the symbol stays constant, so this is indeed a OQPSK signal. Just the resulting bits are different.
I can demodulated the OQPSK using the OQPSK demodulation function from the Communications Toolbox as well as the with the symbol order based on the phase seen in the picture. So the OQPSK is correct. I can also demodulate the MSK with a normal FSK demodulater and the ouput is the same as with the OQPSK. But when applying any kinf of OQPSK demodulation to the MSK signal the resulting sequence is different as well as the phase (picture).
So is a MSK with Half-Sine Filter really equivalent to an OQPSK and both can be received with the same receiver?
This is the phase of the MSK signal
And this is the phase of the OQPSK signal
Best Regards,
Axel Hi everyone,
i’m currently trying to create a offset QPSK modulation using an MSK with a half-sine matched filter. This is based on the IEEE paper https://ieeexplore.ieee.org/document/4102435. I generated an OQPSK and MSK signal with MATLAB and plotted the angle of the signal. Both can be seen below. There is no frequency error or noise. They spectrum for both is the same and the amplitude of the symbol stays constant, so this is indeed a OQPSK signal. Just the resulting bits are different.
I can demodulated the OQPSK using the OQPSK demodulation function from the Communications Toolbox as well as the with the symbol order based on the phase seen in the picture. So the OQPSK is correct. I can also demodulate the MSK with a normal FSK demodulater and the ouput is the same as with the OQPSK. But when applying any kinf of OQPSK demodulation to the MSK signal the resulting sequence is different as well as the phase (picture).
So is a MSK with Half-Sine Filter really equivalent to an OQPSK and both can be received with the same receiver?
This is the phase of the MSK signal
And this is the phase of the OQPSK signal
Best Regards,
Axel msk, oqpsk MATLAB Answers — New Questions
Project for the web – holiday calendar
Hi!
On project for the web i’ve created a calendar template from a “calendar resource” and assigned them a 08:00 AM – 17:00 PM GMT+1 working hour
Holiday are “non working day” in this calendar (summer and winter holiday)
Is there a way to let the plan’s PM to manage his collaborator holiday without admin access to project admin dashboard?
Otherways every time that a users go on holiday i should go on his resourse and modify his working day
Thanks!
Hi! On project for the web i’ve created a calendar template from a “calendar resource” and assigned them a 08:00 AM – 17:00 PM GMT+1 working hourHoliday are “non working day” in this calendar (summer and winter holiday) Is there a way to let the plan’s PM to manage his collaborator holiday without admin access to project admin dashboard?Otherways every time that a users go on holiday i should go on his resourse and modify his working day Thanks! Read More
Automatically Adjusting Rows in a Range
I run a daily golf league where the number of players is not consistent. The data is removed after every use. I use multiple tables that randomly creates teams using RAND function. It also sorts and rank player performance and sum winnings from 3 tables (team performance, individual performance and skins). Every time I use the workbook, I need to manually adjust the table sizes in multiple pages since any #N/A or #VALUE! in a table will interfere with sum, match, vlookup, sorting and rank functions. Is there a way to automatically adjust the number of rows in all of the tables based on the the number of players (PLAYER COUNT)?
I run a daily golf league where the number of players is not consistent. The data is removed after every use. I use multiple tables that randomly creates teams using RAND function. It also sorts and rank player performance and sum winnings from 3 tables (team performance, individual performance and skins). Every time I use the workbook, I need to manually adjust the table sizes in multiple pages since any #N/A or #VALUE! in a table will interfere with sum, match, vlookup, sorting and rank functions. Is there a way to automatically adjust the number of rows in all of the tables based on the the number of players (PLAYER COUNT)? Read More
Workbook flash prevent
Help with the best strategy to prevent workbook flash before Login form displays
Help with the best strategy to prevent workbook flash before Login form displays Read More
Calendar reminders disappear after about 7 days in “new outlook”
If I go back to “old outlook” the reminders works correctly? I can’t find in new outlook any settings that indicate number of days to keep calendar reminders before they are auto-deleted. It appears to be an on/off feature.
If I go back to “old outlook” the reminders works correctly? I can’t find in new outlook any settings that indicate number of days to keep calendar reminders before they are auto-deleted. It appears to be an on/off feature. Read More
You have to transmit Data Sequence 11100010 with transmission bit rate 1000000 through QPSK. Write a Matlab code and a) Generate data sequence and all the above mentioned wave
clear all
close all
Data_Seq=[1,1,1,0,0,0,1,0]
stem(Data_Seq)
bitrate= 1000000;
SR=1/bitrate;
ylim([-1 1])
t=0:0.01:length(Data_Seq)
Data_Seq2=[1,1,1,-1,-1,-1,1,-1]
stem(Data_Seq2)
A = Data_Seq2(1:2:end,:) %
B = Data_Seq2(2:2:end,:)
stem(A)
even = Data_Seq(2:2:end);
odd = Data_Seq(1:2:end);
stem(even)
// i Want to seperate even and odd signal but not undrstanding how to plotclear all
close all
Data_Seq=[1,1,1,0,0,0,1,0]
stem(Data_Seq)
bitrate= 1000000;
SR=1/bitrate;
ylim([-1 1])
t=0:0.01:length(Data_Seq)
Data_Seq2=[1,1,1,-1,-1,-1,1,-1]
stem(Data_Seq2)
A = Data_Seq2(1:2:end,:) %
B = Data_Seq2(2:2:end,:)
stem(A)
even = Data_Seq(2:2:end);
odd = Data_Seq(1:2:end);
stem(even)
// i Want to seperate even and odd signal but not undrstanding how to plot clear all
close all
Data_Seq=[1,1,1,0,0,0,1,0]
stem(Data_Seq)
bitrate= 1000000;
SR=1/bitrate;
ylim([-1 1])
t=0:0.01:length(Data_Seq)
Data_Seq2=[1,1,1,-1,-1,-1,1,-1]
stem(Data_Seq2)
A = Data_Seq2(1:2:end,:) %
B = Data_Seq2(2:2:end,:)
stem(A)
even = Data_Seq(2:2:end);
odd = Data_Seq(1:2:end);
stem(even)
// i Want to seperate even and odd signal but not undrstanding how to plot qpsk modulation MATLAB Answers — New Questions
Recreating embedded antenna pattern from isolated element and S-parameter matrix
My objective is to calculate the active element pattern of the central element in a rectangular array. According to Eq. (17) in David M. Pozar’s paper, "A Relation Between the Active Input Impedance and the Active Element Pattern of a Phased Array," this equation provides the embedded pattern of the mth antenna. While I believe I have correctly implemented this function, the results are not as expected. If anyone has experience with similar calculations, I would appreciate any insights or feedback on why there is a discrepancy between complexEmbPattern and complexEmbPattern_.
The conversion from phi/ theta to elevation/azimuth has been done according to Matlab’s: Antenna Toolbox Coordinate System – MATLAB & Simulink (mathworks.com)
Thank you in advance for your assistance!
Physical Constants:
freq = 30e9;
c = physconst(‘lightspeed’);
lambda = c/freq;
wn = 2*pi/lambda;
azimuth = -180:5:180;
elevation = -90:5:90;
Isolated Element:
element = dipole;
element.Length = 0.47*lambda;
element.Width = cylinder2strip(0.191e-3);
figure;
show(element);
isoEfieldPattern = pattern(element, freq, azimuth, elevation, …
‘Type’, ‘efield’);
isoPhasePattern = pattern(element, freq, azimuth, elevation, …
‘Type’, ‘phase’, …
‘Polarization’, ‘V’);
complexIsoPattern = isoEfieldPattern.*exp(1j*deg2rad(isoPhasePattern));
Embedded Element Pattern:
N = 3;
M = 3;
K = M*N;
a = 0.5*lambda;
b = 0.5*lambda;
array = rectangularArray;
array.Element = element;
array.Element.Tilt = 90;
array.Element.TiltAxis = ‘Y’;
array.Size = [N M];
array.ColumnSpacing = a;
array.RowSpacing = b;
array.Tilt = 90;
array.TiltAxis = ‘Y’;
figure;
show(array);
ElemIndex = (prod(array.Size) – 1)/2 + 1;
Zinf = 76 + 1i*31;
embEfieldPattern = pattern(array, freq, azimuth, elevation, …
‘ElementNumber’, ElemIndex, …
‘Termination’, real(Zinf), …
‘Type’, ‘efield’);
embPhasePattern = pattern(array, freq, azimuth, elevation, …
‘ElementNumber’, ElemIndex, …
‘Termination’, real(Zinf), …
‘Type’, ‘phase’, …
‘Polarization’, ‘V’);
complexEmbPattern = embEfieldPattern.*exp(1j*deg2rad(embPhasePattern));
Sparam = sparameters(array, freq, real(Zinf)).Parameters;
complexEmbPattern_ = ones(size(elevation,2),size(azimuth,2));
m = ElemIndex;
for az = 1:length(azimuth)
for el = 1:length(elevation)
u = wn*a*cosd(elevation(el))*sind(azimuth(az));
v = wn*b*sind(elevation(el));
i_m = mod(m – 1, M) + 1;
j_m = floor((m – 1)/M) + 1;
sum = 0;
for n = 1:K
i_n = mod(n – 1, M) + 1;
j_n = floor((n – 1)/M) + 1;
sum = sum + Sparam(n, m)*exp(1i*((i_n – 1)*u + (j_n – 1)*v));
end
complexEmbPattern_(el, az) = complexIsoPattern(el, az)*(exp(1i*((i_m – 1)*u + (j_m – 1)*v)) + sum);
end
endMy objective is to calculate the active element pattern of the central element in a rectangular array. According to Eq. (17) in David M. Pozar’s paper, "A Relation Between the Active Input Impedance and the Active Element Pattern of a Phased Array," this equation provides the embedded pattern of the mth antenna. While I believe I have correctly implemented this function, the results are not as expected. If anyone has experience with similar calculations, I would appreciate any insights or feedback on why there is a discrepancy between complexEmbPattern and complexEmbPattern_.
The conversion from phi/ theta to elevation/azimuth has been done according to Matlab’s: Antenna Toolbox Coordinate System – MATLAB & Simulink (mathworks.com)
Thank you in advance for your assistance!
Physical Constants:
freq = 30e9;
c = physconst(‘lightspeed’);
lambda = c/freq;
wn = 2*pi/lambda;
azimuth = -180:5:180;
elevation = -90:5:90;
Isolated Element:
element = dipole;
element.Length = 0.47*lambda;
element.Width = cylinder2strip(0.191e-3);
figure;
show(element);
isoEfieldPattern = pattern(element, freq, azimuth, elevation, …
‘Type’, ‘efield’);
isoPhasePattern = pattern(element, freq, azimuth, elevation, …
‘Type’, ‘phase’, …
‘Polarization’, ‘V’);
complexIsoPattern = isoEfieldPattern.*exp(1j*deg2rad(isoPhasePattern));
Embedded Element Pattern:
N = 3;
M = 3;
K = M*N;
a = 0.5*lambda;
b = 0.5*lambda;
array = rectangularArray;
array.Element = element;
array.Element.Tilt = 90;
array.Element.TiltAxis = ‘Y’;
array.Size = [N M];
array.ColumnSpacing = a;
array.RowSpacing = b;
array.Tilt = 90;
array.TiltAxis = ‘Y’;
figure;
show(array);
ElemIndex = (prod(array.Size) – 1)/2 + 1;
Zinf = 76 + 1i*31;
embEfieldPattern = pattern(array, freq, azimuth, elevation, …
‘ElementNumber’, ElemIndex, …
‘Termination’, real(Zinf), …
‘Type’, ‘efield’);
embPhasePattern = pattern(array, freq, azimuth, elevation, …
‘ElementNumber’, ElemIndex, …
‘Termination’, real(Zinf), …
‘Type’, ‘phase’, …
‘Polarization’, ‘V’);
complexEmbPattern = embEfieldPattern.*exp(1j*deg2rad(embPhasePattern));
Sparam = sparameters(array, freq, real(Zinf)).Parameters;
complexEmbPattern_ = ones(size(elevation,2),size(azimuth,2));
m = ElemIndex;
for az = 1:length(azimuth)
for el = 1:length(elevation)
u = wn*a*cosd(elevation(el))*sind(azimuth(az));
v = wn*b*sind(elevation(el));
i_m = mod(m – 1, M) + 1;
j_m = floor((m – 1)/M) + 1;
sum = 0;
for n = 1:K
i_n = mod(n – 1, M) + 1;
j_n = floor((n – 1)/M) + 1;
sum = sum + Sparam(n, m)*exp(1i*((i_n – 1)*u + (j_n – 1)*v));
end
complexEmbPattern_(el, az) = complexIsoPattern(el, az)*(exp(1i*((i_m – 1)*u + (j_m – 1)*v)) + sum);
end
end My objective is to calculate the active element pattern of the central element in a rectangular array. According to Eq. (17) in David M. Pozar’s paper, "A Relation Between the Active Input Impedance and the Active Element Pattern of a Phased Array," this equation provides the embedded pattern of the mth antenna. While I believe I have correctly implemented this function, the results are not as expected. If anyone has experience with similar calculations, I would appreciate any insights or feedback on why there is a discrepancy between complexEmbPattern and complexEmbPattern_.
The conversion from phi/ theta to elevation/azimuth has been done according to Matlab’s: Antenna Toolbox Coordinate System – MATLAB & Simulink (mathworks.com)
Thank you in advance for your assistance!
Physical Constants:
freq = 30e9;
c = physconst(‘lightspeed’);
lambda = c/freq;
wn = 2*pi/lambda;
azimuth = -180:5:180;
elevation = -90:5:90;
Isolated Element:
element = dipole;
element.Length = 0.47*lambda;
element.Width = cylinder2strip(0.191e-3);
figure;
show(element);
isoEfieldPattern = pattern(element, freq, azimuth, elevation, …
‘Type’, ‘efield’);
isoPhasePattern = pattern(element, freq, azimuth, elevation, …
‘Type’, ‘phase’, …
‘Polarization’, ‘V’);
complexIsoPattern = isoEfieldPattern.*exp(1j*deg2rad(isoPhasePattern));
Embedded Element Pattern:
N = 3;
M = 3;
K = M*N;
a = 0.5*lambda;
b = 0.5*lambda;
array = rectangularArray;
array.Element = element;
array.Element.Tilt = 90;
array.Element.TiltAxis = ‘Y’;
array.Size = [N M];
array.ColumnSpacing = a;
array.RowSpacing = b;
array.Tilt = 90;
array.TiltAxis = ‘Y’;
figure;
show(array);
ElemIndex = (prod(array.Size) – 1)/2 + 1;
Zinf = 76 + 1i*31;
embEfieldPattern = pattern(array, freq, azimuth, elevation, …
‘ElementNumber’, ElemIndex, …
‘Termination’, real(Zinf), …
‘Type’, ‘efield’);
embPhasePattern = pattern(array, freq, azimuth, elevation, …
‘ElementNumber’, ElemIndex, …
‘Termination’, real(Zinf), …
‘Type’, ‘phase’, …
‘Polarization’, ‘V’);
complexEmbPattern = embEfieldPattern.*exp(1j*deg2rad(embPhasePattern));
Sparam = sparameters(array, freq, real(Zinf)).Parameters;
complexEmbPattern_ = ones(size(elevation,2),size(azimuth,2));
m = ElemIndex;
for az = 1:length(azimuth)
for el = 1:length(elevation)
u = wn*a*cosd(elevation(el))*sind(azimuth(az));
v = wn*b*sind(elevation(el));
i_m = mod(m – 1, M) + 1;
j_m = floor((m – 1)/M) + 1;
sum = 0;
for n = 1:K
i_n = mod(n – 1, M) + 1;
j_n = floor((n – 1)/M) + 1;
sum = sum + Sparam(n, m)*exp(1i*((i_n – 1)*u + (j_n – 1)*v));
end
complexEmbPattern_(el, az) = complexIsoPattern(el, az)*(exp(1i*((i_m – 1)*u + (j_m – 1)*v)) + sum);
end
end s-parameters, embedded element pattern, active element pattern, matlab MATLAB Answers — New Questions
Match analytical and simulation values of SER vs SNR curve.
% Parameters
M = 4; % MQAM order (e.g., 16-QAM)
N = 1e5; % Number of transmit symbols
% Define SNR range
SNR_dB_range = 0:10;
num_SNR_points = length(SNR_dB_range);
% Initialize SER array
SER_values = zeros(num_SNR_points, 1);
% Create MQAM constellation
constellation = createMQAM(M);
% Loop over each SNR value
for idx = 1:num_SNR_points
SNR_dB = SNR_dB_range(idx);
% Generate transmit symbols
transmitSymbols = generateSymbols(constellation, N);
% Transmit through AWGN channel
receivedSymbols = transmitSymbolsThroughAWGN(transmitSymbols, SNR_dB);
% Demodulate symbols
decodedSymbols = demodulateSymbols(receivedSymbols, constellation);
% Compute Symbol Error Rate
SER = computeSER(transmitSymbols, decodedSymbols);
% Store SER value
SER_values(idx) = SER;
% Compute Theoretical SER
SER_theoretical = computeTheoreticalSER(M, SNR_dB_range);
SER_theoretical_values = SER_theoretical;
end
% Plot SER vs SNR
figure;
semilogy(SNR_dB_range, SER_values, ‘o-‘, ‘DisplayName’, ‘Simulated SER’);
hold on;
semilogy(SNR_dB_range, SER_theoretical_values, ‘r–‘, ‘DisplayName’, ‘Theoretical SER’);
xlabel(‘SNR (dB)’);
ylabel(‘Symbol Error Rate (SER)’);
title(‘SER vs. SNR for MQAM’);
legend;
grid on;
function constellation = createMQAM(M)
% Create an MQAM constellation manually
% M: Number of symbols (e.g., 16, 64, etc.)
% Check that M is a perfect square
k = sqrt(M);
if mod(k,1) ~= 0
error(‘M must be a perfect square’);
end
% Generate constellation points
k = round(k); % Number of points per side
[X, Y] = meshgrid(linspace(-k+1, k-1, k), linspace(-k+1, k-1, k));
constellation = X(:) + 1i*Y(:);
end
function symbols = generateSymbols(constellation, N)
% Generate N random transmit symbols
% constellation: The MQAM constellation points
% N: Number of symbols to generate
numPoints = length(constellation);
indices = randi([1 numPoints], [N, 1]); % Randomly choose indices
symbols = constellation(indices); % Select symbols from the constellation
end
function received = transmitSymbolsThroughAWGN(symbols, SNR_dB)
% Transmit symbols through a SISO AWGN channel
% symbols: Transmit symbols
% SNR_dB: Signal-to-noise ratio in dB
% Convert SNR from dB to linear scale
SNR_linear = 10^(SNR_dB / 10);
% Calculate noise variance
noise_variance = 1 / SNR_linear;
% Generate noise
noise = sqrt(noise_variance / 2) * (randn(size(symbols)) + 1i*randn(size(symbols)));
% Received symbols
received = symbols + noise;
end
function decodedSymbols = demodulateSymbols(received, constellation)
% Demodulate symbols using minimum distance decoding
% received: Received symbols
% constellation: MQAM constellation points
numSymbols = length(received);
numPoints = length(constellation);
% Initialize decoded symbols
decodedSymbols = zeros(size(received));
for i = 1:numSymbols
% Compute distances to all constellation points
distances = abs(received(i) – constellation).^2;
% Find the closest constellation point
[~, idx] = min(distances);
decodedSymbols(i) = constellation(idx);
end
end
function SER = computeSER(originalSymbols, decodedSymbols)
% Compute symbol error rate
% originalSymbols: Transmit symbols
% decodedSymbols: Received and decoded symbols
numErrors = sum(originalSymbols ~= decodedSymbols);
totalSymbols = length(originalSymbols);
SER = numErrors / totalSymbols;
end
function SER_theoretical = computeTheoreticalSER(M, SNR_dB)
% Compute the theoretical SER for MQAM in AWGN
% M: Number of symbols (e.g., 16, 64, etc.)
% SNR_dB: SNR in dB
% Convert SNR from dB to linear scale
SNR_linear = 10.^(SNR_dB / 10);
% Compute theoretical SER
k = sqrt(M); % Number of points per side
if mod(k,1) ~= 0
error(‘M must be a perfect square’);
end
% Calculate SER using the Q-function
SER_theoretical = 4*(1-1./sqrt(M))*qfunc(sqrt(3./(M-1)*SNR_linear));
end
In the above code when I plot the SER v/s SNR and compare the simulation and analytical values don’t match. Can someone tell me what is the error in my code and how can I match the curves ?% Parameters
M = 4; % MQAM order (e.g., 16-QAM)
N = 1e5; % Number of transmit symbols
% Define SNR range
SNR_dB_range = 0:10;
num_SNR_points = length(SNR_dB_range);
% Initialize SER array
SER_values = zeros(num_SNR_points, 1);
% Create MQAM constellation
constellation = createMQAM(M);
% Loop over each SNR value
for idx = 1:num_SNR_points
SNR_dB = SNR_dB_range(idx);
% Generate transmit symbols
transmitSymbols = generateSymbols(constellation, N);
% Transmit through AWGN channel
receivedSymbols = transmitSymbolsThroughAWGN(transmitSymbols, SNR_dB);
% Demodulate symbols
decodedSymbols = demodulateSymbols(receivedSymbols, constellation);
% Compute Symbol Error Rate
SER = computeSER(transmitSymbols, decodedSymbols);
% Store SER value
SER_values(idx) = SER;
% Compute Theoretical SER
SER_theoretical = computeTheoreticalSER(M, SNR_dB_range);
SER_theoretical_values = SER_theoretical;
end
% Plot SER vs SNR
figure;
semilogy(SNR_dB_range, SER_values, ‘o-‘, ‘DisplayName’, ‘Simulated SER’);
hold on;
semilogy(SNR_dB_range, SER_theoretical_values, ‘r–‘, ‘DisplayName’, ‘Theoretical SER’);
xlabel(‘SNR (dB)’);
ylabel(‘Symbol Error Rate (SER)’);
title(‘SER vs. SNR for MQAM’);
legend;
grid on;
function constellation = createMQAM(M)
% Create an MQAM constellation manually
% M: Number of symbols (e.g., 16, 64, etc.)
% Check that M is a perfect square
k = sqrt(M);
if mod(k,1) ~= 0
error(‘M must be a perfect square’);
end
% Generate constellation points
k = round(k); % Number of points per side
[X, Y] = meshgrid(linspace(-k+1, k-1, k), linspace(-k+1, k-1, k));
constellation = X(:) + 1i*Y(:);
end
function symbols = generateSymbols(constellation, N)
% Generate N random transmit symbols
% constellation: The MQAM constellation points
% N: Number of symbols to generate
numPoints = length(constellation);
indices = randi([1 numPoints], [N, 1]); % Randomly choose indices
symbols = constellation(indices); % Select symbols from the constellation
end
function received = transmitSymbolsThroughAWGN(symbols, SNR_dB)
% Transmit symbols through a SISO AWGN channel
% symbols: Transmit symbols
% SNR_dB: Signal-to-noise ratio in dB
% Convert SNR from dB to linear scale
SNR_linear = 10^(SNR_dB / 10);
% Calculate noise variance
noise_variance = 1 / SNR_linear;
% Generate noise
noise = sqrt(noise_variance / 2) * (randn(size(symbols)) + 1i*randn(size(symbols)));
% Received symbols
received = symbols + noise;
end
function decodedSymbols = demodulateSymbols(received, constellation)
% Demodulate symbols using minimum distance decoding
% received: Received symbols
% constellation: MQAM constellation points
numSymbols = length(received);
numPoints = length(constellation);
% Initialize decoded symbols
decodedSymbols = zeros(size(received));
for i = 1:numSymbols
% Compute distances to all constellation points
distances = abs(received(i) – constellation).^2;
% Find the closest constellation point
[~, idx] = min(distances);
decodedSymbols(i) = constellation(idx);
end
end
function SER = computeSER(originalSymbols, decodedSymbols)
% Compute symbol error rate
% originalSymbols: Transmit symbols
% decodedSymbols: Received and decoded symbols
numErrors = sum(originalSymbols ~= decodedSymbols);
totalSymbols = length(originalSymbols);
SER = numErrors / totalSymbols;
end
function SER_theoretical = computeTheoreticalSER(M, SNR_dB)
% Compute the theoretical SER for MQAM in AWGN
% M: Number of symbols (e.g., 16, 64, etc.)
% SNR_dB: SNR in dB
% Convert SNR from dB to linear scale
SNR_linear = 10.^(SNR_dB / 10);
% Compute theoretical SER
k = sqrt(M); % Number of points per side
if mod(k,1) ~= 0
error(‘M must be a perfect square’);
end
% Calculate SER using the Q-function
SER_theoretical = 4*(1-1./sqrt(M))*qfunc(sqrt(3./(M-1)*SNR_linear));
end
In the above code when I plot the SER v/s SNR and compare the simulation and analytical values don’t match. Can someone tell me what is the error in my code and how can I match the curves ? % Parameters
M = 4; % MQAM order (e.g., 16-QAM)
N = 1e5; % Number of transmit symbols
% Define SNR range
SNR_dB_range = 0:10;
num_SNR_points = length(SNR_dB_range);
% Initialize SER array
SER_values = zeros(num_SNR_points, 1);
% Create MQAM constellation
constellation = createMQAM(M);
% Loop over each SNR value
for idx = 1:num_SNR_points
SNR_dB = SNR_dB_range(idx);
% Generate transmit symbols
transmitSymbols = generateSymbols(constellation, N);
% Transmit through AWGN channel
receivedSymbols = transmitSymbolsThroughAWGN(transmitSymbols, SNR_dB);
% Demodulate symbols
decodedSymbols = demodulateSymbols(receivedSymbols, constellation);
% Compute Symbol Error Rate
SER = computeSER(transmitSymbols, decodedSymbols);
% Store SER value
SER_values(idx) = SER;
% Compute Theoretical SER
SER_theoretical = computeTheoreticalSER(M, SNR_dB_range);
SER_theoretical_values = SER_theoretical;
end
% Plot SER vs SNR
figure;
semilogy(SNR_dB_range, SER_values, ‘o-‘, ‘DisplayName’, ‘Simulated SER’);
hold on;
semilogy(SNR_dB_range, SER_theoretical_values, ‘r–‘, ‘DisplayName’, ‘Theoretical SER’);
xlabel(‘SNR (dB)’);
ylabel(‘Symbol Error Rate (SER)’);
title(‘SER vs. SNR for MQAM’);
legend;
grid on;
function constellation = createMQAM(M)
% Create an MQAM constellation manually
% M: Number of symbols (e.g., 16, 64, etc.)
% Check that M is a perfect square
k = sqrt(M);
if mod(k,1) ~= 0
error(‘M must be a perfect square’);
end
% Generate constellation points
k = round(k); % Number of points per side
[X, Y] = meshgrid(linspace(-k+1, k-1, k), linspace(-k+1, k-1, k));
constellation = X(:) + 1i*Y(:);
end
function symbols = generateSymbols(constellation, N)
% Generate N random transmit symbols
% constellation: The MQAM constellation points
% N: Number of symbols to generate
numPoints = length(constellation);
indices = randi([1 numPoints], [N, 1]); % Randomly choose indices
symbols = constellation(indices); % Select symbols from the constellation
end
function received = transmitSymbolsThroughAWGN(symbols, SNR_dB)
% Transmit symbols through a SISO AWGN channel
% symbols: Transmit symbols
% SNR_dB: Signal-to-noise ratio in dB
% Convert SNR from dB to linear scale
SNR_linear = 10^(SNR_dB / 10);
% Calculate noise variance
noise_variance = 1 / SNR_linear;
% Generate noise
noise = sqrt(noise_variance / 2) * (randn(size(symbols)) + 1i*randn(size(symbols)));
% Received symbols
received = symbols + noise;
end
function decodedSymbols = demodulateSymbols(received, constellation)
% Demodulate symbols using minimum distance decoding
% received: Received symbols
% constellation: MQAM constellation points
numSymbols = length(received);
numPoints = length(constellation);
% Initialize decoded symbols
decodedSymbols = zeros(size(received));
for i = 1:numSymbols
% Compute distances to all constellation points
distances = abs(received(i) – constellation).^2;
% Find the closest constellation point
[~, idx] = min(distances);
decodedSymbols(i) = constellation(idx);
end
end
function SER = computeSER(originalSymbols, decodedSymbols)
% Compute symbol error rate
% originalSymbols: Transmit symbols
% decodedSymbols: Received and decoded symbols
numErrors = sum(originalSymbols ~= decodedSymbols);
totalSymbols = length(originalSymbols);
SER = numErrors / totalSymbols;
end
function SER_theoretical = computeTheoreticalSER(M, SNR_dB)
% Compute the theoretical SER for MQAM in AWGN
% M: Number of symbols (e.g., 16, 64, etc.)
% SNR_dB: SNR in dB
% Convert SNR from dB to linear scale
SNR_linear = 10.^(SNR_dB / 10);
% Compute theoretical SER
k = sqrt(M); % Number of points per side
if mod(k,1) ~= 0
error(‘M must be a perfect square’);
end
% Calculate SER using the Q-function
SER_theoretical = 4*(1-1./sqrt(M))*qfunc(sqrt(3./(M-1)*SNR_linear));
end
In the above code when I plot the SER v/s SNR and compare the simulation and analytical values don’t match. Can someone tell me what is the error in my code and how can I match the curves ? communication, plot MATLAB Answers — New Questions
Create a 3D matrix from 2 2D matrix
Hi all,
I want to create a 3D matrix from three 2D matrix with different size.
The first matrix has the size of 360×560 which contain the information of grid for x.
The second matrix has the same size (360×560) and has the grid details of z.
The third matrix has the size of 100×560 and it contain the detail of grid for y.
To simply, the size of x, y and z are 560, 360 and 100.
I would like to create a 3D matrix with a size of 100x360x560 with grid information for the x, y and z direction.
May I know how to achieve that? I have attached a test.mat file that include x, y and z.
Thanks for your help!Hi all,
I want to create a 3D matrix from three 2D matrix with different size.
The first matrix has the size of 360×560 which contain the information of grid for x.
The second matrix has the same size (360×560) and has the grid details of z.
The third matrix has the size of 100×560 and it contain the detail of grid for y.
To simply, the size of x, y and z are 560, 360 and 100.
I would like to create a 3D matrix with a size of 100x360x560 with grid information for the x, y and z direction.
May I know how to achieve that? I have attached a test.mat file that include x, y and z.
Thanks for your help! Hi all,
I want to create a 3D matrix from three 2D matrix with different size.
The first matrix has the size of 360×560 which contain the information of grid for x.
The second matrix has the same size (360×560) and has the grid details of z.
The third matrix has the size of 100×560 and it contain the detail of grid for y.
To simply, the size of x, y and z are 560, 360 and 100.
I would like to create a 3D matrix with a size of 100x360x560 with grid information for the x, y and z direction.
May I know how to achieve that? I have attached a test.mat file that include x, y and z.
Thanks for your help! combine matrix MATLAB Answers — New Questions
Transmission-Reception using USRPs(B210s) with 5G NR Waveform Synchronization failing
Hi Everyone,
I am trying to create a 5G environment with USRPs, one as transmitter (PC1 with MATLAB) and other as receiver (PC2 with MATLAB) and they are connect with wired antennas.
I am generating the 5G NR waveform at transmitter side and sending it to receiver over connected antennas.
The waveform signal is sent for 10 seconds and receiver also receiving it for same duration with 1 second provided for transmission delay (through USRP’s USBs and wires). However, the synchronization is failing and the waveform I received are not the same which leads to inability to extract the sent waveform properties like PDCCH and PDSCH, data, etc. The datatypes of sent and received waveform are also different (Complex-double at transmitter, Complex-int16 at receiver).
I used the below link for designing the waveform for transmission.
https://in.mathworks.com/help/5g/ug/5g-nr-waveform-capture-and-analysis-using-software-defined-radio.html
Although there is no details about the receiver side in the above link.
If someone faced the similar issues, kindly suggest some help
If there exist any tutorial for this kind of work Please share?
ThanksHi Everyone,
I am trying to create a 5G environment with USRPs, one as transmitter (PC1 with MATLAB) and other as receiver (PC2 with MATLAB) and they are connect with wired antennas.
I am generating the 5G NR waveform at transmitter side and sending it to receiver over connected antennas.
The waveform signal is sent for 10 seconds and receiver also receiving it for same duration with 1 second provided for transmission delay (through USRP’s USBs and wires). However, the synchronization is failing and the waveform I received are not the same which leads to inability to extract the sent waveform properties like PDCCH and PDSCH, data, etc. The datatypes of sent and received waveform are also different (Complex-double at transmitter, Complex-int16 at receiver).
I used the below link for designing the waveform for transmission.
https://in.mathworks.com/help/5g/ug/5g-nr-waveform-capture-and-analysis-using-software-defined-radio.html
Although there is no details about the receiver side in the above link.
If someone faced the similar issues, kindly suggest some help
If there exist any tutorial for this kind of work Please share?
Thanks Hi Everyone,
I am trying to create a 5G environment with USRPs, one as transmitter (PC1 with MATLAB) and other as receiver (PC2 with MATLAB) and they are connect with wired antennas.
I am generating the 5G NR waveform at transmitter side and sending it to receiver over connected antennas.
The waveform signal is sent for 10 seconds and receiver also receiving it for same duration with 1 second provided for transmission delay (through USRP’s USBs and wires). However, the synchronization is failing and the waveform I received are not the same which leads to inability to extract the sent waveform properties like PDCCH and PDSCH, data, etc. The datatypes of sent and received waveform are also different (Complex-double at transmitter, Complex-int16 at receiver).
I used the below link for designing the waveform for transmission.
https://in.mathworks.com/help/5g/ug/5g-nr-waveform-capture-and-analysis-using-software-defined-radio.html
Although there is no details about the receiver side in the above link.
If someone faced the similar issues, kindly suggest some help
If there exist any tutorial for this kind of work Please share?
Thanks 5g nr waveform synchronization using usrps (b210s) MATLAB Answers — New Questions
Error en windows
Buenos diás,
Al inicia el ordenador y una vez iniciado cada media hora me sale este mensaje de error:
“Esta version de windows expirara el dia 15/09/2024. Debe mover a una nueva compilacion tan pronto como sea posible, Conectarse interner para obtener mas información.”
Agradeceria me indicasen como puedo eliminar dicho mensaje sin necesidad de reinstalar windows ya que tengo programas e información que no me gustaría perder. Mi versiónb de windows es original y dispondo del correspondiente codigo de activación. Aunque escriba dicho codigo de nuevo, me sigue dando el mismo error.
Gracias de antemano. Un cordial saludo
Buenos diás,Al inicia el ordenador y una vez iniciado cada media hora me sale este mensaje de error:”Esta version de windows expirara el dia 15/09/2024. Debe mover a una nueva compilacion tan pronto como sea posible, Conectarse interner para obtener mas información.”Agradeceria me indicasen como puedo eliminar dicho mensaje sin necesidad de reinstalar windows ya que tengo programas e información que no me gustaría perder. Mi versiónb de windows es original y dispondo del correspondiente codigo de activación. Aunque escriba dicho codigo de nuevo, me sigue dando el mismo error. Gracias de antemano. Un cordial saludo Read More
Request for Assistance with Microsoft 365 Security (customer development) in APAC’s specific countr
I have observed that many companies in my country (within the APAC region) are not fully aware of the capabilities offered by Microsoft 365 Security. As a result, they often opt for alternative products with fewer features, despite having already purchased Microsoft 365 licenses.
I would like to discuss this issue directly with the Microsoft customer development/training team to explore potential solutions and improve awareness about Microsoft 365 Security in our region.
is there anyone know that how to contact the appropriate team or provide any resources that could assist in addressing this concern?
I have observed that many companies in my country (within the APAC region) are not fully aware of the capabilities offered by Microsoft 365 Security. As a result, they often opt for alternative products with fewer features, despite having already purchased Microsoft 365 licenses.I would like to discuss this issue directly with the Microsoft customer development/training team to explore potential solutions and improve awareness about Microsoft 365 Security in our region.is there anyone know that how to contact the appropriate team or provide any resources that could assist in addressing this concern? Read More
System Center Licences help
Hi,
I`m planning to buy System Center and have some doubts about witch licences i need.
I have a 3 node vmware cluster with 96 total physycal cores.
I’m planning to use configuration manager to manage deployment, updates and app installation on near 400 client pc.
As i understand if i buy datacenter edition i can manage all windows servers on the cluster and have to buy 400 operations manager client licences for client pc’s and with standard i have to buy client licences for servers to.
Is that ok?
Thanks
Hi,I`m planning to buy System Center and have some doubts about witch licences i need.I have a 3 node vmware cluster with 96 total physycal cores.I’m planning to use configuration manager to manage deployment, updates and app installation on near 400 client pc. As i understand if i buy datacenter edition i can manage all windows servers on the cluster and have to buy 400 operations manager client licences for client pc’s and with standard i have to buy client licences for servers to.Is that ok? Thanks Read More
Adding TEAMS meetings to personal calendar -Free version
Hi!
I am trying to work out how to add my Teams meetings to my calendar whilst using the free version. There seems to be no calendar link at all. I have seen some extensions but they only work for the organisation/work package. I would prefer to link my Google calendar though have an Outlook calendar I could link if it’s easier.
Can anyone help? Thanks 😁
Hi! I am trying to work out how to add my Teams meetings to my calendar whilst using the free version. There seems to be no calendar link at all. I have seen some extensions but they only work for the organisation/work package. I would prefer to link my Google calendar though have an Outlook calendar I could link if it’s easier. Can anyone help? Thanks 😁 Read More
Copilot Does Not Summarise Slides in Powerpoint
I have a 40 slide presentation. Some of the slides are particularly wordy, so what I was planning to do was to ask Copilot to summarise a series of slides and add that as a companion document to the presentation.
When I ask it to summarise a single slide by asking it to “Summarise slide 5” it grabs a title from a previous headline slide and creates a summary based seemingly on the whole presentation. If I ask it to summarise multiple slides with “Please summarise slides 5, 7, 10….” It creates a headline for each slide but summarises the wrong slides throughout and places the wrong titles on each slide in the response.
Anyone else tried summarising specific slides in a presentation?
I have a 40 slide presentation. Some of the slides are particularly wordy, so what I was planning to do was to ask Copilot to summarise a series of slides and add that as a companion document to the presentation. When I ask it to summarise a single slide by asking it to “Summarise slide 5” it grabs a title from a previous headline slide and creates a summary based seemingly on the whole presentation. If I ask it to summarise multiple slides with “Please summarise slides 5, 7, 10….” It creates a headline for each slide but summarises the wrong slides throughout and places the wrong titles on each slide in the response. Anyone else tried summarising specific slides in a presentation? Read More
The New Entra ID Photo Update Settings Policy for User Profile Photos
A new Entra ID photo update settings policy aims to cure the mish-mash of existing settings controlling how user profile photos are updated in Microsoft 365. The new policy is based on a Microsoft Graph resource. Work is needed to update clients to respect the policy settings and take over from current controls, like the OWA mailbox policy.
https://office365itpros.com/2024/09/16/photo-update-settings-policy/
A new Entra ID photo update settings policy aims to cure the mish-mash of existing settings controlling how user profile photos are updated in Microsoft 365. The new policy is based on a Microsoft Graph resource. Work is needed to update clients to respect the policy settings and take over from current controls, like the OWA mailbox policy.
https://office365itpros.com/2024/09/16/photo-update-settings-policy/ Read More
How do I get HP Bloatware script to run during enrollment?
Hi all
I am wanting to put a script within Intune so during the deployment phase of autopilot it would remove the HP Bloatware however if I attach this script
https://gist.github.com/mark05e/a79221b4245962a477a49eb281d97388 into the deployment policy it would fail everytime.
I can only remove it by going to the start menu , run powershell as admin and then run the script manually from there.
What do I need to add so the script can run automatically?
It wouldn’t matter if it can’t be run during the enrollment stage but I do want to somehow automatic this .
Thanks
Hi all I am wanting to put a script within Intune so during the deployment phase of autopilot it would remove the HP Bloatware however if I attach this scripthttps://gist.github.com/mark05e/a79221b4245962a477a49eb281d97388 into the deployment policy it would fail everytime. I can only remove it by going to the start menu , run powershell as admin and then run the script manually from there. What do I need to add so the script can run automatically? It wouldn’t matter if it can’t be run during the enrollment stage but I do want to somehow automatic this . Thanks Read More
Windows 365 GPOs instead of Intune Policies
Hi,
can i set the Windows 365 specific settings (except the provisioning policy) like RDS-Policy via Group Policies, or due i always have to use Intune Profiles?
If GPO are possible, where do i find the requires admx-files
Best Regards
Carsten.
Hi,can i set the Windows 365 specific settings (except the provisioning policy) like RDS-Policy via Group Policies, or due i always have to use Intune Profiles? If GPO are possible, where do i find the requires admx-files Best RegardsCarsten. Read More
Moving from Amazon Quantum Ledger Database (QLDB) to ledger in Azure SQL
Overview
Amazon Web Services (AWS) has announced the discontinuation of its Amazon Quantum Ledger Database (QLDB). Their documentation has been updated to indicate that support for QLDB will end on July 31, 2025. AWS’s decision has prompted many customers to explore alternative solutions for their ledger database needs.
Introducing ledger in Azure SQL
AWS propose Aurora PostgreSQL for audit use cases as an alternative to QLDB for common ledger database use cases. While Aurora offers detailed audit logging and permanent log retention, it does not include cryptographic verifiability.
Microsoft offers an excellent replacement through its ledger feature in Azure SQL. It provides similar functionalities, ensuring data integrity through cryptographic verification, and leverages the full capabilities of Azure SQL. Ledger is a feature that offers the power of Blockchain in Azure SQL Database, Azure SQL Managed Instance and SQL Server. Ledger allows establishing trust across different business entities while maintaining the simplicity and performance of a relational database. The data is centrally managed, and you can cryptographically attest to other parties, such as auditors or business partners, that your data can be trusted and hasn’t been tampered with.
More information about ledger in Azure SQL and SQL Server can be found in the ledger documentation.
Key features of ledger
Captures and cryptographically links data changes to make the data tamper-evident and verifiable.
Uses the same SQL environment you already know.
Is easy to deploy and maintain.
It comes with NO extra cost.
Migration support
Amazon QLDB uses a document-oriented data model. The complexity lies in normalizing data during migration, converting the document model into a relational model, and handling any changes to the document model. Microsoft can assist organizations in migrating from Amazon QLDB to Azure SQL Database. For more detailed information and to initiate the migration process, organizations are encouraged to contact Microsoft support or their Microsoft Account Manager.
Conclusion
Even though QLDB is being phased out, Microsoft offers an excellent alternative for users to host their data with cryptographic immutability. This ensures they can uphold rigorous data integrity standards. Ledger in Azure SQL serves as a strong alternative, with effortless integration into the Azure SQL environment.
Useful links
For more information and to get started with ledger in Azure SQL, see:
Explore the Azure SQL Database ledger documentation
Read the whitepaper
GitHub demo/sample
Data Exposed episode (video)
Listen to the ledger podcast
Microsoft Tech Community – Latest Blogs –Read More