xkhainguyen / L1AC-Basics

L1 Adaptive Control basic simulation
MIT License
7 stars 0 forks source link

On the filter problem of the controller in the program #1

Closed yanglyao0623 closed 1 year ago

yanglyao0623 commented 1 year ago

I am very glad to read the L1 adaptive control code you wrote. I do not understand something, and I would like to ask for your guidance. I don't know what the variable u_prev stands for, so I can't understand u_f = (params. Ts/params.tau)u + (1-params.Ts/params.tau)u_prev; This line of code, hope to get your answer, thank you.

xkhainguyen commented 1 year ago

Thank you for your question. u_prev stands for the previous control input. That line of code is a simple low-pass filter: y = alphax + (1-alpha)y, this helps the controller more robust (avoids rapid changes due to adaptability).

yanglyao0623 commented 1 year ago

Oh, thank you for your answer. I see. Your other L1 adaptive control for the quadrotor is also great! I am understanding. I wish you a happy life and a successful work

xkhainguyen commented 1 year ago

Thanks. Good luck to you!