Control Resonant Artifacts: A Practical Guide
In this article
Control resonant artifacts are unwanted oscillations or vibrations in a control system, typically caused by the interaction between the system's natural resonance and the controller's feedback loop. This guide explains what they are, why they occur, and how to mitigate them using filters, tuning adjustments, and mechanical damping.
Background: What Are Resonant Artifacts?
Every physical system has natural frequencies at which it tends to vibrate. When a control loop (like a PID controller) commands motion, it can excite these frequencies. If the controller's gain is high enough, the system can enter a state of sustained oscillation at or near that resonant frequency. These oscillations appear as visible jitter, audible hum, or rapid wear in actuators. In precision applications—such as CNC machining, robotic arms, or optical stages—these artifacts degrade accuracy and can cause premature failure.
Resonant artifacts are not a single phenomenon. They can be classified by source:
- Mechanical resonance: flexibility in couplings, belts, or load inertia.
- Electrical resonance: inductance and capacitance in motor windings or cables.
- Acoustic resonance: vibrations that produce sound, often from fans or transformers.
- Hydraulic resonance: pressure pulsations in fluid power systems.
Understanding the source is critical because the mitigation strategy differs.
How Resonance Affects Control Loops
In a closed-loop system, the sensor measures the output, and the controller adjusts the input to minimize error. If the system has a resonance peak in its frequency response, the controller's gain at that frequency is effectively amplified. A standard PID controller, which has a fixed gain across all frequencies, will amplify the resonance if its gain is set too high. The result is a limit cycle—a self-sustaining oscillation that the controller cannot correct because it is the cause.
The classic symptom is a high-frequency whine or vibration that appears only when the loop is active. Turning off the controller stops the artifact. This distinguishes it from pure mechanical vibration, which persists without control.
Identifying the Resonant Frequency
Before you can filter a resonance, you need to know its frequency. The most reliable method is a frequency response test. Apply a sinusoidal command at varying frequencies and measure the output amplitude. The frequency at which the output peaks is the resonant frequency. This can be done with a dynamic signal analyzer or, in many modern drives, with built-in autotuning routines that sweep frequencies automatically.
If you cannot run a formal test, you can estimate the resonance from the system's physical properties. For a simple inertia-spring system, the resonant frequency f in Hertz is:
f = (1 / 2π) × √(k / J)
where k is the stiffness (N·m/rad) and J is the inertia (kg·m²). This formula is approximate but gives a starting point for filter settings.
Mitigation Techniques
Several methods can suppress resonant artifacts. The most common in industrial controls are:
- Notch filters: A notch filter removes a narrow band of frequencies. Place the notch at the resonant frequency to block the oscillation. Most modern servo drives include a programmable notch filter with adjustable depth and width.
- Low-pass filters: A low-pass filter attenuates frequencies above a cutoff. This is simpler but also reduces the bandwidth of the control loop, which can slow response.
- Low-pass filter on the feedback: Filtering the sensor signal before it enters the controller can prevent high-frequency noise from being amplified. However, this adds phase lag, which can destabilize the loop if not accounted for.
- Reducing controller gain: Lowering the proportional and derivative gains reduces the excitation of resonance, but it also reduces performance. This is a last resort when filters are unavailable.
- Mechanical damping: Adding damping material or a tuned mass damper physically absorbs the vibration. This is often the only solution for structural resonances that are too close to the control bandwidth.
Choosing the Right Filter
The choice of filter depends on the frequency of the resonance relative to the control bandwidth. If the resonance is well above the bandwidth (at least 3 times higher), a simple low-pass filter is effective. If the resonance is near or within the bandwidth, a notch filter is better because it removes the peak without affecting the frequencies you need for control.
Here is a practical decision process:
- Measure the resonant frequency f and the control bandwidth f_bw.
- If f > 3 × f_bw: use a low-pass filter with cutoff at ~2 × f_bw.
- If f is between 1.5 and 3 × f_bw: use a notch filter centered at f.
- If f < 1.5 × f_bw: consider mechanical changes or a more advanced control algorithm (e.g., H∞ control).
When setting a notch filter, start with a narrow width (Q factor of 10 or higher) and a depth of about 20 dB. Then adjust while monitoring the system's step response. Too narrow a notch may not fully suppress the resonance; too wide a notch will reduce phase margin.
Common Mistakes and Misconceptions
One frequent mistake is applying a notch filter at the wrong frequency, often because the resonance shifts with load or temperature. Re-tune after any mechanical change. Another error is using a low-pass filter on the command signal instead of the feedback. Filtering the command does not reduce the resonance because the resonance is in the plant, not the command.
A common misconception is that increasing the derivative gain (D in PID) will dampen resonance. In reality, derivative gain amplifies high-frequency noise, which can worsen the artifact. The derivative term should be filtered with a low-pass filter (often called a derivative filter) to avoid this.
Another misconception is that resonance is always caused by the controller. If the artifact appears even with the loop open, it is a mechanical or electrical issue, not a control artifact.
Advanced Approaches
For difficult cases, more advanced techniques are available:
- Adaptive notch filters: These automatically track the resonant frequency as it changes. They are useful in systems with variable load inertia.
- Feedback linearization: This method cancels the nonlinear dynamics that can excite resonance. It requires a accurate model of the system.
- Observer-based state feedback: An observer estimates the unmeasured states, allowing the controller to compensate for resonance without a direct measurement.
- Input shaping: This technique modifies the command signal to avoid exciting the resonance. It is often used in cranes and flexible robots.
These methods are typically implemented in high-end motion controllers or PLCs with specialized function blocks. They require a deeper understanding of control theory and system identification.
Frequently Asked Questions
Why does my motor whine only when the controller is on?
That whine is a resonant artifact. The controller's gain amplifies the motor's natural resonance. When the controller is off, no feedback signal is present to sustain the oscillation. Turning off the loop removes the excitation.
Can a notch filter fix all resonance problems?
No. A notch filter only removes a single frequency. If there are multiple resonances, you need multiple notches. Also, if the resonance frequency shifts significantly, a fixed notch may become ineffective. In such cases, adaptive filters or mechanical damping are better.
What is the difference between a notch filter and a low-pass filter?
A low-pass filter attenuates all frequencies above a cutoff, which reduces noise but also reduces the control bandwidth. A notch filter only attenuates a narrow band around a specific frequency, leaving other frequencies unaffected. Use a notch when you know the exact resonant frequency.
How do I find the resonant frequency without special equipment?
You can perform a simple test: apply a step input and observe the oscillation frequency in the response. Or, if you have a drive with autotuning, it will often report the resonant frequency. For a rough estimate, use the formula f = (1/2π)√(k/J) if you know the stiffness and inertia.
Will reducing the PID gains always stop the artifact?
Lowering gains will reduce the amplitude of the oscillation, but it may not eliminate it. Also, it will slow the response and could make the system too sluggish. Filters are a better solution because they remove the resonance without sacrificing performance.
Can resonance damage my equipment?
Yes. Sustained oscillation can cause mechanical fatigue, loosen fasteners, and overheat motors. In severe cases, it can break shafts or couplings. Addressing resonant artifacts promptly is important for equipment longevity.