OFDM : How can I fix error "To RESHAPE the number of elements must not change"
1 回表示 (過去 30 日間)
古いコメントを表示
- Bit_Num = 4; FFT_Num = 64;
- Carrier_Num = 48; OFDM_per_Symbol = 1;
- CP = 16; LI = 12;
- Np = 4; Carriers = 1:Carrier_Num + Np;
- N_Num = Bit_Num * Carrier_Num * OFDM_per_Symbol;
- BitTx = randi(1,N_Num);
- N_Num = length(BitTx);
- SymQAMtmp = reshape(BitTx,4,N_Num/4).';
- SymQAMtmptmp=bi2de(SymQAMtmp,2,'left-msb');
0 件のコメント
回答 (1 件)
Sumeet Gadagkar
2018 年 3 月 6 日
Hey Mohammad,
The error "To RESHAPE the number of elements must not change" is thrown when the size of the matrix to be reshaped and the size you want to reshape it to do not match i.e the total number of elements in both the matrices should be the same. Assume you have two matrices 'A' and 'B' of sizes (m x n) and (i x j), to reshape matrix 'A' to the size of matrix 'B' the constraint is that --> (m*n = i*j).
In simple terms the number of elements in both matrix 'A' and 'B' should be the same. Make sure that this condition is satisfied while using the "reshape" function.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で OFDM についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!