How to optimize a parameter using Nonlinear model predictive controller

조회 수: 11 (최근 30일)
Hello everyone,
I am using Nonlinear model predictive controller and I wonder if I can optimize a parameter.
Let's take an example Plan Optimal Trajectory Using Nonlinear MPC on this website (https://www.mathworks.com/help/mpc/ref/nlmpc.nlmpcmove.html). In FlyingRobotStateFcn.m there are 2 given parameters alpha and beta = 0.2. Is there a way to make these paremeters also variables and calculate optimal values of alpha and beta ?
Thank you for your answers

답변 (1개)

Emmanouil Tzorakoleftherakis
Emmanouil Tzorakoleftherakis 2023년 2월 22일
편집: Emmanouil Tzorakoleftherakis 2023년 2월 23일
Looks like you are referring to parameters defined inside the prediction model/state function of the MPC controller. You can make these variables parameters/arguments to the state function by following the guidelines on this page.
To use MPC for static optimization, one idea is to use the parameter as an MV and set a MVRate constraint to zero. That would basically make this MV constant. That way you could have both dynamically changing MVs and a constant one. If you try it, please let me know if it works.
  댓글 수: 4
Ondrej Zoufaly
Ondrej Zoufaly 2023년 2월 23일
That's the problem, it is a constant. In the example the parameters are moment arms of engines, so the optimized value should be as large as possible (so no need for optimiziation). However, I want to use it in my own model, I'm just demonstrating on this example since it is very clear and easy.
Emmanouil Tzorakoleftherakis
Emmanouil Tzorakoleftherakis 2023년 2월 23일
I see. So basically you have mixed dynamic and static decision variables. I haven't tried it myself, but one idea is to still use the parameter as an MV and set a MVRate constraint to zero. That would basically make this MV constant. That way you could have both dynamically changing MVs and a constant one. If you try it, please let me know if it works.
I also updated my answer accordingly

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Refinement에 대해 자세히 알아보기

제품


릴리스

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by