0
$\begingroup$

I have a signal from a PWM inverter that was sampled at 3,84 kHz. The PWM has a switching frequency of 5 kHz. The pwm signal is feeding an induction motor. If I low-pass filter the PWM signal it should result in a pure sinusoid: A*cos(2*pi*60*t+phi) of 60 Hz, which is the reference signal to the pwm.

But the sampling frequency fs=3.84KHz does not respect the Nyquist theorem that says that the sampling frequency should be twice the highest frequency of the signal, that is, it should be 2*5KHz = 10KHz. So the pwm signal is under-sampled.

By just filtering the sampled signal I believe that aliasing will happen. Right? Then I would not be able to obtain the purely sinusoidal reference.

If I linearly interpolate the PWM sampled signal so that it would go from fs=3.84KHz to fs=10KHz then, I would make the sampling rate equal to the Nyquist frequency. Now, if I filter it, aliasing would not happen anymore. Is this right?

If not, I was wondering if there is any way to filter the pwm signal and obtain the purely sinusoidal reference without aliasing. Interpolation? Resampling? I know a priori that the filtered pwm signal should result in a sinusoid, maybe that could help to reconstruct the sinusoid signal?

Thank you, L.

In this image you can see an schematic

$\endgroup$
  • $\begingroup$ I don't understand – if your signal is bandlimited to 60 Hz, then there's no violation of Nyquist at all! $\endgroup$ – Marcus Müller Feb 6 '17 at 21:26
  • 1
    $\begingroup$ Please write down the equations of the "voltage signal" and the "PWM signal". $\endgroup$ – MBaz Feb 6 '17 at 22:29
  • $\begingroup$ Please take a look at my updated answer. $\endgroup$ – MBaz Feb 8 '17 at 17:40
1
$\begingroup$

PWM is a non-linear process, and it contains rectangular pulses; in theory at least, it cannot be sampled without aliasing because its bandwidth is infinite. In practice, a sampling rate of 5 times the fundamental is enough in many applications; this would mean that you need a sampling rate of at least 25 kHz.

Once the signal is sampled, you can't eliminate aliasing by interpolating. The interpolated signal will still contain all aliases. In fact, it is in general impossible to eliminate aliasing once it occurs.

Even worse, the spectrum of the PWM signal is continuous, which means that the aliases will probably swamp the sideband at 60 Hz. In other words, your problem may have no solution.


EDIT: Would a narrow bandpass filter at 60 Hz work?

Short answer: I don't think it will, because there are likely to be aliases at 60 Hz; these will modify the amplitude and phase of the signal component at 60 Hz.

Longer answer: the spectrum of the undersampled signal is quite complex. First, the analog PWM process is non-linear, which introduces harmonics at multiples of 5 Khz. The actual shape of these harmonics is, I think, not trivial to calculate, but we can assume that they will include sinc-like spectra of very large bandwidth (since the PWM pulses can be very narrow). Adding to this the undersampling at 3.84 kHz, there will probably be complex aliasing happening at 60 Hz.

One thing you can do is look at the analog PWM signal in a spectrum analyzer. Set the tracing to "average" and let it run for a while. Find the bandwdith of each harmonic, and then see if any of them will alias at 60 Hz when undersampled. If (and only if) by a sheer strike of luck none of them do, then the narrow bandpass filter will work as you want.

$\endgroup$
  • $\begingroup$ I understand. Thank you for your answer What if I apply a really narrow bandpass filter around 60 Hz? Let's say 59 to 61 Hz. I really don't care about the amplitude of the 60Hz component, I just want to minimize the modulation caused by the sidebands. $\endgroup$ – Loius Linux Feb 8 '17 at 14:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.