Why do I receive an "undefined command/function hinfpar" error when using the HINFGS function in the Robust Control Toolbox 3.0.1(R14SP2)?

2 次查看(过去 30 天)
When I execute the following commands:
load G_pol;
[Gopt,K] = hinfgs(G_pol,[1 1],2);
I receive the following error:
??? Undefined command/function 'hinfpar'.
Error in ==> hinfgs at 78
[A,B1,b2,C1,c2,D11,d12,d21,d22]=hinfpar(psinfo(pds,'sys',1),r);

采纳的回答

MathWorks Support Team
There is a bug in the Robust Control Toolbox 3.0.1 (R14SP2) that causes the error when using the HINFGS function. This behavior occurs because:
1. The HINFPAR, KLMI, MACH_EPS, XDIAG, GETPHI functions are only available in the "private" directory at the path: '$MATLABROOT/toolbox/robust/rctobsolete/lmi/private/'.
2. The HINFGS function exists at two places. The default version of the function is at the path: '$MATLABROOT/toolbox/robust/rctlmi/'. Since the '$MATLABROOT/toolbox/robust/rctlmi/private/' directory does not contain the HINFPAR and the other functions, MATLAB does not find these files.
To work around this issue, execute the following code in MATLAB:
path([matlabroot, '\toolbox\robust\rctobsolete\lmi'],path);
This will add the required path at the top of the current search path and thus the HINFGS function in the '\toolbox\robust\rctobsolete\lmi' directory will be invoked. The '\toolbox\robust\rctobsolete\lmi\private' directory has the HINFPAR and other functions that are necessary for the successful execution of the HINFGS function.
In all the above cases, "$MATLABROOT" is the output of executing the MATLABROOT command on the MATLAB command prompt.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 File Name Construction 的更多信息

产品


版本

R14SP2

Community Treasure Hunt

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

Start Hunting!

Translated by