DSPRelated.com
Forums

OFDM simulation

Started by sheen2411 October 24, 2007
hi all

I hope that you can help me.

I actually have to simulate an ofdm system to show the graph of magnitude
against frequency. I am however stuck...

part my initial codes are as follows:


        % generating 400 symbols (block 20 x 20)->transmitted signal
        qpsk= exp(j*[pi/4 3*pi/4 5*pi/4 7*pi/4]');
        s=qpsk(randint(20,20,4)+1);
        
        %convert to time domain
        x=ifft(s);
        
**** this is where i need to show the graph****

Can anybody kindly help me. i can say that im stuck at this point.

thanking you for your assistance

sheen



On Oct 24, 4:30 am, "sheen2411" <nawshee...@hotmail.com> wrote:
> hi all > > I hope that you can help me. > > I actually have to simulate an ofdm system to show the graph of magnitude > against frequency. I am however stuck... > > part my initial codes are as follows: > > % generating 400 symbols (block 20 x 20)->transmitted signal > qpsk= exp(j*[pi/4 3*pi/4 5*pi/4 7*pi/4]'); > s=qpsk(randint(20,20,4)+1); > > %convert to time domain > x=ifft(s); > > **** this is where i need to show the graph**** > > Can anybody kindly help me. i can say that im stuck at this point. > > thanking you for your assistance > > sheen
Sheen, You need to stop what you are doing and think about what you want to show. You give the impression that if the graph isn't shown in that particular part of your code progression, then the sky is falling down. So, you would like to plot magnitude versus frequency. Let me ask you two questions. 1) How would you define the magnitude of your complex symbols (qpsk)? 2) If you are converting to the time domain, with x=ifft(s); then what domain is the vector s in prior to conversion? If you can answer those two questions, then you can plot magnitude versus freq very easy. col