| NGMV Control Toolbox | ![]() |
Writing a Master Script
At this point it is best to write a master script that will perform the controller synthesis and run the simulations. Open the template file “ngmvtmpl” that runs a simple example and shows a comparison between PID and NGMV controllers. Run the script choosing “no algebraic loop solution” (option 1). If everything works correctly, you should obtain the following plot:

Now modify the script, tailoring it to our engine speed control example. Here are a few guidelines:
Ts = -1k = 0 and k = 1 may be tried.
nref = [0 2000; 5 3000; 11 5000; 15 4000];
stop_time = 10;
sim('enginewc_ngmv',stop_time)
simdata={Nsp,N,TA};
where nref defines the speed reference as a two-column matrix [time, values].
Plot the results using simplots command and compare with PI performance.
|
NGMV Controller Synthesis | Tuning the NGMV Dynamic Weightings | ![]() |