Hi, everyone! i need help to make this , instead of getting a matrix FTTx ( 4x8) i need to get a column vector (1x32) with the same values but i iam not able to do it , thank you

1 vue (au cours des 30 derniers jours)
Lx=20;
N=4;
P=8;
L=2;
xBuff=zeros(N,1);
b=0.5;
x = filter(sqrt(1-b^2), [1 -b], (1/(sqrt(4)))*(randn(Lx,1)) );
FFTX = zeros(N,P); %%%%%%% FFTX = zeros(N*P,1);
for k = 1 : L : 20 % k=1 ,2,3 .............. etc
nn = k : k + L - 1; %1:2 , 2:3 , 3:4 ; 4:5.............etc
xBuff(1 : N, :) = [ xBuff(L+1 : N, : ) ; x(nn, :) ];
FFTX(:,2:P) = FFTX(:,1:P-1);
FFTX(:,1) = fft(xBuff);
end
  1 commentaire
mina massoud
mina massoud le 9 Mai 2019
Modifié(e) : dpb le 9 Mai 2019
% this is my code but the answer is not the same , i don't know why
Lx=20;
N=4;
P=8;
L=2;
xBuff=zeros(N,1);
b=0.5;
x = filter(sqrt(1-b^2), [1 -b], (1/(sqrt(4)))*(randn(Lx,1)) );
FFTX = zeros(N*P,1);
for k = 1 : L : 20 % BlkSize = KK*F.L, KK integer
nn = k : k + L - 1; %1:2 , 2:3 , 3:4 ; 4:5.............etc
xBuff(1 : N, :) = [ xBuff(L+1 : N, : ) ; x(nn, :) ];
%FFTX(:,2:P) = FFTX(:,1:P-1);
FFTX(2:P,1) = FFTX(1:P-1,1);
FFTX(1:4,1) = fft(xBuff);
end

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Downloads dans Help Center et File Exchange

Produits


Version

R2018b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by