In this article, I am going to write about the Sliding Mode Control (SMC) algorithm.
Sliding Mode Control algorithm is a robust controller for nonlinear systems.
Robust control means that even though the system model has a certain error, if the controller can control the system, we say that the controller is robust.
SMC has two fundamental ideas.
1. To attract the system states to the surface.
2. To make the state slide on the surface toward the origin.
To explain the above two ideas more easily, let’s assume a typical control problem.
— (1)
— (2) if it is nonlinear, you need to know Lie Derivatives.
To achieve the first idea, we need to define a surface like the below. (Let’s assume that is a scalar and differentiable.)
where — (3)
Here we need to select a_0 and a_1 to make y->0 as t-> inf,s=0. You will see the reason after more several lines.
Let’s take the derivative of s(x) w.r.t. x. Then we can get the below equation.
— (4)
In addition, if we add the additional term – we can obtain the below equation,
— (5)
Through a simple Lyapunov theorem, we can easily prove s-> 0 at t->inf .
if s=0, e-> 0 and \dot(e)-> 0, because we selected a_0 and a_1 to be like this.
Let’s look at (5),
=>
=>
=>
With this control input, we can control a nonlinear system with SMC.
it is difficult to explain quickly within short explanations…., if you need more explanation or questions, please leave me a reply.
Do you have matlab code for sliding mode observer?
Sorry I have only some code for controlling, not observer.
Thanks for your reply sir.
Great explanation! I am working on a project about second order sliding mode for trajector tracking and i have stuck on the part of the controller so I would like to ask if you can send me a part of matlab code about smc to understand the equations
hello sir,
Would you please leave some tip how to control four Dynamixel servo independently ? bulk_readWrite makes them run all together.
Thank you