Forums

Filtering PWM in MATLAB

Started by k2lr...@arrl.net July 6, 2009
Hello all. I am relativele new to using MATLAB for DSP related work, and I am looking for some direction/help. I am attempting to model a PWM signal, and how the output would look after passing through a filter. I can creat the PWM signal with out a problem. My problem comes when I see the effect a low pass filter would have(just an example). What I am currently doing is I find the FFT, and then multiply it by the amplitude of the filter. I then take that result and do an ifft. This seems like it should work, but I am not getting what I expect. For example a PWM signal representing a sinewave does not give me a sinewave after the ifft.