File Exchange

image thumbnail

Structured MIMO H-infinity design for a dual-stage platform using HIFOO and Hinfstruct

version 1.3 (5 KB) by

Code for advanced control design accompanying a journal paper. Can serve as a benchmark.



View License

This m-file first creates a linear state-space model of a real experimental motion control platform where two electrical motors are used to rotate a payload around a single (vertical) axis. This simple device was built to analyze control schemes for inertial stabilization platforms. More details can be found in the paper

M. Rezac and Z. Hurak. Structured MIMO H∞ Design for Dual-Stage Inertial Stabilization: Case Study for HIFOO and Hinfstruct Solvers. Mechatronics, Elsevier, Vol.23, Iss.8, December, 2013, pp: 1084–1093. DOI:

A rigid plate freely rotatable around a vertical axis carries a standard DC brush-type rotary motor, which via a belt transmission drives the secondary stage carrying a DC voice-coil motor, which pushes the payload. The voice-coil motor enjoys a very small friction, which is a very plausible property for inertial stabilization, but its angular stroke is limited to (+-5 deg). Therefore, the (geared) DC brush-type rotary motor is used to keep the angular devitation close to zero (this is called mid-range control in the industrial process control domain). The key disturbance is the angular velocity of the freely rotatable plate upon which the stator of the DC brushed motor resides. This mimicks the unwanted angular motion of a mobile carrier (car, aircraft, ship). The video at can help understand the principle.

Having two measured outputs and two control inputs, the control design can either be accomplished by successively closing SISO loops or designing a MIMO controller. The latter generally cannot include some resctrictions on the structure and the order of the controller. With two solvers HIFOO and Hinstruct, both providing identical functionality and comparable performance, the task of structured MIMO control design can be accomplished by minimizing the H-infinity norm of properly defined generalized plant. This is the major part of this m-file. As a side product of this code, a direct comparison of the two solvers can be done.

Comments and Ratings (4)


tran nhan

merci bcp bcp

Martin Rezac

Zdenek Hurak

Note that currently (as of July 27, 2013) there is an issue (a bug) with HIFOO in the latest version 3.5. It is activated when the user tries to input both a constraint on the structure of the controller by using a mask and an initial controller. The check if the initial controller meets the structure
requirements can actually never pass, since the init.a matrix is at first converted to a vector and then compared to a matrix mask. In other words, an n x n matrix is compared to the n^2 vector. The checking routine is be found at lines 132, 133 and 134 of the "processInitialController.m" file. See the following copy of the code. When these three lines are commented out, the hifoo code works again, but the check is not performed.

   % check if the initial controller is the same order as the
   % structure
   % if (sum(size(A) ~= size(init.a)) > 0)
   % error('The given initial controller doesn''t have the same
order as the given structure');
   % end

Text of the error message:

HIFOO Version 3.5, using options
hifoo: "plant" is an SS object, using input partitioning in "InputGroup"
hifoo: "plant" is an SS object, using output partitioning in "OutputGroup"

Error using processInitialController (line 133)
The given initial controller doesn't have the same order as the given

Error in hifoo (line 351)
[init,ssinputcont] = processInitialController(init,pars,options);

Error in dual_stage_realmotors_differentstruct_coupled (line 73)
  [K1_hifo, F, VIOL, LOC] = hifoo(P,ordR2+ordK1+ordF,OPTIONS,INIT);

The bug has been reported to the HIFOO developers and the correction is expected soon. Till then, just comment out the three lines.



Updated citation details of the paper.


Updated the link to the paper on a journal webpage (article in press).


Minor polishing of the code.

MATLAB Release
MATLAB 7.14 (R2012a)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video