Quote:
Originally Posted by Kevbo
In general, you need to convert the differential equation into an approximately equivalent difference equation.

Integrating the differential equations using RungeKutta is better because the differential equation can be nonlinear and it is easier to model disturbances.
Quote:
Beware that higher order equations may exhibit oscillatory response (limit cycling) when converted to discreet time form when the the continuous time form was stable. For this reason it is better to design the system with discreet time/difference equations from the outset.

I never had that problem because I know where to place the closed loop poles and the sample times on a motion controller are fast and deterministic.