Thread Subject: ofdm question

Subject: ofdm question

From: Robert Orzechowski

Date: 23 Nov, 2009 22:10:21

Message: 1 of 2

Hello,

I tried to implement very simple OFDM channel. However i met an issue, i cannot solve myself. Could you please help me ?
This is the code:

data=randint(1,k,n);
modulated = pskmod(data);
OFDMmodulated=ifft(modulated);
receivedmodulated = fft(OFDMmodulated);
out = (receivedmodulated ~= modulated);


Why do I got every time receivedmodulated different from modulated, if k is greater than 8 ? I think this is something with fft/ifft usage.

thank you for your help
Robert

Subject: ofdm question

From: Robert Orzechowski

Date: 25 Nov, 2009 23:10:23

Message: 2 of 2

Hi,

I "improved ?" my programm a little bit:
function out = smallofdm

k=8
n=4
data=randint(1,k,n);

modulated = pskmod(data)
OFDMmodulated=ifft(modulated,2*k);
receivedmodulated1 = fft(OFDMmodulated, 2*k)
receivedmodulated = [receivedmodulated1(1:k)]
if receivedmodulated == modulated
    msgbox('succeed!')
else
    msgbox('not succeed')
end


and now it seems it is almost good. But I am still confused.
my questions are now:
1) why I need to do fft 2*k points for the vector of the length k ? is it something with a Nyquist frequency ?

2) why i got 'not succeed' message, when the vectors seems to be equal... ? I saw while displaying vectors are like:
receivedmodulated =

  Columns 1 through 7

        0 - 1.0000i -0.0000 - 1.0000i 1.0000 - 0.0000i -0.0000 + 1.0000i 1.0000 0.0000 + 1.0000i 1.0000 + 0.0000i

  Column 8

   1.0000 - 0.0000i

How to make value like -0.000i or other values close to zero just not important ? I can imagine it is something with round-off values by PC, but how to workaround it in my code ?

thank you for the help
Robert

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
ofdm channel Robert Orzechowski 24 Nov, 2009 16:14:20
ifft Robert Orzechowski 23 Nov, 2009 17:14:08
fft Robert Orzechowski 23 Nov, 2009 17:14:08
modulation Robert Orzechowski 23 Nov, 2009 17:14:08
ofdm Robert Orzechowski 23 Nov, 2009 17:14:08
rssFeed for this Thread
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com