Online and Real-Time Trajectory Generation Method for Unforeseen Events Using a Modified Spline Approach

This letter focuses on the problem of online and instantaneous generation of smooth trajectories and their analytical time derivatives, where future reference signals provided by a trajectory planner or a user are a-priori unknown. For this purpose, we propose a modified cubic spline polynomial which transforms the instantaneous piecewise references into smooth and continuous functions for digital control systems. The resulting reference signals are not only smooth and continuous in time but also analytically differentiable. The inferred derivative values could then be used in a variety of linear and non-linear controllers such as, Proportional-Integral-Derivative (PID), sliding mode, and backstepping. We also provide optimum and boundary values for the parameters used in the proposed technique. In addition, we present a lightweight implementation (a few lines of code) of the algorithm by which real-time computations are rapidly performed using a microcontroller. Both simulation and real experiments demonstrate that for the plants having different degrees of complexities, the proposed approach with a PD / PID controller outperforms the conventional filtered derivative-based one in terms of overshoot in the step response, robustness against noise, and trajectory tracking error.