I have a matrix of 4095 by 4. i need to divide it into submatrices of 117 by 1.
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Sajid Sarwar
am 9 Nov. 2018
Kommentiert: Walter Roberson
am 19 Nov. 2018
How can I do this using for loop? I mean I have to select first 117 rows and 1st column then first 117 rows and 2nd column, then first 117 rows and 3rd column and then 1st 117 rows and 4th column. after that repeat this for next 117 rows and so on uptill 4095 rows.
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 9 Nov. 2018
Baserow = (column-1) * 117;
Subset = YourImage(Baserow+(1:117),column, :) ;
6 Kommentare
Walter Roberson
am 19 Nov. 2018
You do not need 2D data for awgn. You might need a row vector for ofdmDemod though.
st=rand(9945,4)
for n=1:85
Baserow = (n-1) * 117;
for n1 = 1:4
Subset = st(Baserow+(1:117),n1, :)
txSig(n, n1, :) = ofdmMod(Subset);
y = awgn(txSig(n, n1, :), SNR(k));
sigRx(n, n1, :) = ofdmDemod(y(:).');
end
end
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Propagation and Channel Models finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!