How to automatically update the parameters values (basically gains) in the Simulink model each time a MATLAB script file is run calculating these gains parameters values?
2 次查看(过去 30 天)
显示 更早的评论
Dear colleagues, I have established a script file that calculates the controller gain values of 3 x 3 multivariable controller, 15 different gains have been designed for such controller. The model of the controller has been also built in the Simulink in order to simulate the controller responses of the whole system and to see whether the system under the controller is well behaved, this requires me to calibrate the 15 gains values to reach the best response and needs a lot of calibrations. The problem is that I have to enter manually to the Simulink model the new values of the gains calculated by the script file each time I calculate new gains values which takes long time and exposed to many mistakes before I finally run the Simulink model. Is there any way or procedure that I link the script file with the simulation model so that the gain values are automatically updated in the Simulink avoiding entering them manually each time I run the script file?
0 个评论
回答(1 个)
Mandar Patwardhan
2017-6-26
I understand that you are using a script to manually tune the gain blocks in a Simulink model in order to calibrate and check the controller responses. This can be done by using the Gain-Scheduled PID Controllers. The following example shows how to implement gain-scheduled control in a Simulink® model using a family of PID controllers. The PID controllers are tuned for a series of steady-state operating points of the plant, which is highly nonlinear.
Another approach to tune the PID controllers in a Simulink Model programmatically is to use the slTuner interface. Refer to the following link for more information.
Last but not the least, you can consider using the systune or looptune functions to automatically tune control systems modeled in Simulink. Refer to the following link which shows the example to use these functions.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Gain Scheduling 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!