OFDM IFFT question

Hi,
I found the OFDM IFFT caculation is very different from what I got in
MATLAB.
In detail, my command is shown below
./benchmark_ofdm_tx.py -f 10M -i 512 --fft-length=64
–occupied-tones=32
–cp-length=4 (bpsk)

The packet size is 8 bits, after a serials of operation, it added 4
bytes
in front, and 5 bytes afterward.
For example, I compare the 0C0C IFFT transfer ( 0C0C is the 4 bytes
header), since only 30 carriers are actually filled up with data, so,
the
binary number are X= 0(repeat 16 times) 1 (repeat 10 times) -1 -1 1 1 1
00
1 (repeat 11 times) -1 -1 1 1 0(repeat 16 times)
and in matlab the IFFT(X, 64)=

   0.3438

-0.2123 + 0.0408i
-0.0122 + 0.0184i
0.0799 - 0.1137i
-0.0080 + 0.1171i
-0.0278 - 0.0266i
0.0027 - 0.0499i
-0.0154 + 0.0531i
0.0488 - 0.0202i
0.0036 + 0.0030i
-0.1120 - 0.0136i
0.1315 + 0.0317i
-0.0437 - 0.0186i
-0.0124 - 0.0452i
-0.0280 + 0.1096i
0.0650 - 0.0959i
-0.0156 + 0.0156i
-0.0587 + 0.0278i
0.0648 + 0.0077i
-0.0114 - 0.0391i
-0.0317 - 0.0003i
0.0355 + 0.0512i
-0.0212 - 0.0339i
0.0128 - 0.0225i
-0.0175 + 0.0423i
0.0261 - 0.0253i
-0.0204 + 0.0182i
-0.0030 - 0.0217i
0.0209 + 0.0104i
-0.0155 + 0.0028i
0.0012 + 0.0049i
0.0022 - 0.0135i
0
0.0022 + 0.0135i
0.0012 - 0.0049i
-0.0155 - 0.0028i
0.0209 - 0.0104i
-0.0030 + 0.0217i
-0.0204 - 0.0182i
0.0261 + 0.0253i
-0.0175 - 0.0423i
0.0128 + 0.0225i
-0.0212 + 0.0339i
0.0355 - 0.0512i
-0.0317 + 0.0003i
-0.0114 + 0.0391i
0.0648 - 0.0077i
-0.0587 - 0.0278i
-0.0156 - 0.0156i
0.0650 + 0.0959i
-0.0280 - 0.1096i
-0.0124 + 0.0452i
-0.0437 + 0.0186i
0.1315 - 0.0317i
-0.1120 + 0.0136i
0.0036 - 0.0030i
0.0488 + 0.0202i
-0.0154 - 0.0531i
0.0027 + 0.0499i
-0.0278 + 0.0266i
-0.0080 - 0.1171i
0.0799 + 0.1137i
-0.0122 - 0.0184i
-0.2123 - 0.0408i
which is very much different from what I got from the output of
gnuradio
the gr_ofdm_cyclic_prefixer.cc. (This is the second output of whole
packet
since the first output 67 complex numbers are preamble, I guess the
second
output should match to the partial of the header 0C0C)

cyclic 0 -0.5097 -7.4924 cyclic 1 -5.1105 -7.2764 cyclic 2 -0.7801
-1.1804 cyclic 3 13.5876 2.6097 (CP)

cyclic 4 22.0000 0.0000
cyclic 5 13.5876 -2.6097 cyclic 6 -0.7801 1.1804 cyclic 7 -5.1105
7.2764 cyclic
8 -0.5097 7.4924 cyclic 9 1.7798 1.6997 cyclic 10 0.1735 -3.1954
cyclic
11 0.9864 -3.3997 cyclic 12 3.1213 -1.2929 cyclic 13 -0.2281 -0.1922
cyclic
14 -7.1693 -0.8714 cyclic 15 -8.4139 -2.0297 cyclic 16 -2.7969
-1.1926 cyclic
17 0.7941 2.8952 cyclic 18 -1.7896 7.0168 cyclic 19 -4.1604 6.1374
cyclic
20 -1.0000 1.0000 cyclic 21 3.7586 -1.7804 cyclic 22 4.1488 0.4929
cyclic
23 0.7278 2.5028 cyclic 24 -2.0315 -0.0211 cyclic 25 -2.2737 -3.2793
cyclic
26 -1.3547 -2.1691 cyclic 27 -0.8221 1.4382 cyclic 28 -1.1213 2.7071
cyclic
29 -1.6704 1.6217 cyclic 30 -1.3064 1.1638 cyclic 31 0.1896 1.3886
cyclic
32 1.3381 0.6640 cyclic 33 0.9932 -0.1775 cyclic 34 0.0778 0.3133
cyclic
35 -0.1378 0.8635 cyclic 36 0.0000 0.0000 cyclic 37 -0.1378 -0.8635
cyclic
38 0.0778 -0.3133 cyclic 39 0.9932 0.1775 cyclic 40 1.3381 -0.6640
cyclic
41 0.1896 -1.3886 cyclic 42 -1.3064 -1.1638 cyclic 43 -1.6704 -1.6217
cyclic
44 -1.1213 -2.7071 cyclic 45 -0.8221 -1.4382 cyclic 46 -1.3547 2.1691
cyclic
47 -2.2737 3.2793 cyclic 48 -2.0315 0.0211 cyclic 49 0.7278 -2.5028
cyclic
50 4.1488 -0.4929 cyclic 51 3.7586 1.7804 cyclic 52 -1.0000 -1.0000
cyclic
53 -4.1604 -6.1374 cyclic 54 -1.7896 -7.0168 cyclic 55 0.7941 -2.8952
cyclic
56 -2.7969 1.1926 cyclic 57 -8.4139 2.0297 cyclic 58 -7.1693 0.8714
cyclic
59 -0.2281 0.1922 cyclic 60 3.1213 1.2929 cyclic 61 0.9864 3.3997
cyclic
62 0.1735 3.1954 cyclic 63 1.7798 -1.6997 cyclic 64 -0.5097 -7.4924
cyclic
65 -5.1105 -7.2764 cyclic 66 -0.7801 -1.1804 cyclic 67 13.5876 2.6097
Anyone knows the reason? Or Did I misunderstand how it works?
Thanks,
Bin

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs