dkpy architecture overview

dkpy implements each step in the D-K iteration algorithm as an abstract class. This ensures that each step satisfies the interface required by the algorithm while leaving the numerical implementation up to the user. Sensible implementations of each of these steps are provided in dkpy. However, the user can create custom implementations via the abstract classes. Therefore, anyone aiming to extend or customize dkpy should familiarize themselves with them. The abstract classes are provided below.

dkpy.ControllerSynthesis()

Controller synthesis base class.

dkpy.StructuredSingularValue()

Structured singular value base class.

dkpy.DScaleFit()

D-scale fit base class.

dkpy.DkIteration(controller_synthesis, ...)

D-K iteration base class.

The steps of the D-K iteration algorithm are as follows [SP06].

  1. Controller synthesis (ControllerSynthesis): Synthesize an H-infinity controller for the scaled problem with fixed fitted D-scales.

  2. Structured singular value and D-scale computation (StructuredSingularValue): Compute the structured singular value and the D-scales over a discrete grid of frequencies with a fixed controller.

  3. D-scale fit (DScaleFit): Fit the magnitude of each D-scale to a stable minimum-phase LTI system.

The D-K iteration algorithm, specified by a DkIteration object, loops through these three steps until the robustness criteria are satisfied. Therefore, the algorithm is specified using implementations of each of the abstract classes ControllerSynthesis, StructuredSingularValue, and DScaleFit.

D-K iteration methods

The D-K iteration methods provided by dkpy are presented below. Each one implements the interface specified in DkIteration. The difference between these methods is the way the D-scale fit order is selected. It can either be fixed, specified via a list, selected automatically, or selected interactively.

dkpy.DkIterFixedOrder(controller_synthesis, ...)

D-K iteration with a fixed number of iterations and fixed fit order.

dkpy.DkIterListOrder(controller_synthesis, ...)

D-K iteration with a fixed list of fit orders.

dkpy.DkIterAutoOrder(controller_synthesis, ...)

D-K iteration with automatically selected fit orders.

dkpy.DkIterInteractiveOrder(...[, max_fit_order])

D-K iteration with interactively selected fit orders.

Each DkIteration.synthesize() method returns (among other things) a list of IterResult objects. These objects summarize the status of the D-K iteration process at each step. They can be plotted with plot_D() and plot_mu() to assess the accuracy of the D-scale fit and its impact on the structured singular value.

dkpy.IterResult(omega, mu_omega, D_l_omega, ...)

Information about the current iteration of the D-K iteration process.

dkpy.plot_mu(d_scale_info[, ax, plot_kw, hide])

Plot mu.

dkpy.plot_D(d_scale_info[, ax, plot_kw, ...])

Plot D.

Controller synthesis

Supported continuous-time H-infinity controller synthesis methods are provided below. Each one implements the interface specified in ControllerSynthesis.

dkpy.HinfSynSlicot()

H-infinity synthesis using SLICOT's Riccati equation method.

dkpy.HinfSynLmi([lmi_strictness, solver_params])

H-infinity synthesis using a linear matrix inequality approach.

dkpy.HinfSynLmiBisection([bisection_atol, ...])

H-infinity synthesis using an LMI approach with bisection.

Structured singular value

Supported structured singular value computation methods are provided below. Only one approach is provided, which implements the interface in StructuredSingularValue. The LMI solver settings may need to be adjusted depending on the problem.

dkpy.SsvLmiBisection([bisection_atol, ...])

Structured singular value using an LMI approach with bisection.

D-scale fit

Supported D-scale fitting methods are provided below. Only one approach is provided currently, which implements the interface in DScaleFit. There are currently no ways to customize the D-scale magnitude fitting process beyond selecting the order in DScaleFit.fit().

dkpy.DScaleFitSlicot()

Fit D-scale magnitudes with SLICOT.

Uncertainty block structure

The uncertainty block structure is specified via an UncertaintyBlockStructure object, which encodes the block diagonal uncertainty structure. The UncertaintyBlockStructure object is composed of individual uncertainty blocks that satisfy the interface in UncertaintyBlock, which are provided below.

dkpy.RealDiagonalBlock(num_channels)

Real-valued diagonal uncertainty block.

dkpy.ComplexDiagonalBlock(num_channels)

Complex-valued diagonal uncertainty block.

dkpy.ComplexFullBlock(n_exogenous_inputs, ...)

Complex-valued full uncertainty block.

The UncertaintyBlockStructure object can also be specified using the MATLAB two-column array format (see MATLAB documentation <https://www.mathworks.com/help/robust/ref/mussv.html>) for users that are more comfortable with this notation.