Interpolation of Coarse Update Points

Most motion controllers do some form of interpolation. Some use interpolation to interpolated between points as in cubic splines. Other controllers use interpolation all the time because the controller is essenetially dumb and simply interpolates to the next point that is downloaded by a master motion profile geneator. The controller then uses the available information to do fine positon updates between the coarse positions. Few people have thought of the consequence of doing interpolations in this way. One should ask if the interpolation method being used by their controller faithfully reproduces the master’s motion profile. In some cases this is impossible. One of my favorite tests is to see how well an interpolation scheme can match a sine wave. This is impossible to do because a sine wave is geneated by a Taylor series with an infinite number of terms and low order interpolation algorithms don’t usually have terms over x³. In this case x=2πHz*Δt where Δt is the coarse update time.

One of the first questions you should ask is if the moton controller you use interpolates for common point to point moves and if they do what is the order of interpolation that they do? So why does one care? The reason is that the fine interpolation must not only compute fine positons, it must also compute fine velocities and accelerations for use with feed forwards gains. The fine velocity is also required for use with the derivative gain. Without accurate fine velocities and accelerations these cans either can’t be used or the gains must be lower than optimal to prevent the gain times the error in velocity or acceleration from generating erroneous a control output.
The pdf file examines how the resolition of the data affects the interpolation too.

So how do you know what order of interpolation is used by your controller? One can ask or look in the documentation but a a good way of finding out on your own requires a scope to look at the output of the controller. If a point to point move is made with all PID and feed forwards gains set to 0 EXCEPT the acceleration feed forward, it is easy to determine the order of interpolation. If the interpolation is second order the acceleration will change in steps each coarse update. During the acceleration during the coarse update will alway be constant or horizontal. If the acceleration changes by using linear ramps then the interpolation is third order. The slope of the ramps will change at each coarse update but the slope be constant within the coarse update. The acceleration line segments will be continuous, that is the acceleration at the end of one coarse update will be equal to the acceleration at the beginning of the next coarse update period. If the acceleration changes in a parabolic curve then the order of interpolation is fourth order or higher. Now that the order of interpolation is determined it will be easy to see how it affectsthe motion control.

Below is a PDF document about quadradic or second order interpolation. What should be noticed is that quadradic interpolation doesn’t do a very good job of generating velocities and accelerations for the feed forward and derivative gains.

If there are any questions, please ask. A similar document will be added for cubic interpolation.
Mathcad - Quadratic Interpolation.pdf (155 KB)