## Section: New Results

### Control and scheduling co-design

Participants : D. Simon [ contact person ] , O. Sename, M. Ben Gaid, A. Desvages, D. Robert.

We propose here a control/scheduling co-design approach. We aim to provide an
*Integrated control and scheduling co-design* approach. Indeed closing the loop between the control performance and the computing activity seems to be promising for both adaptivity and robustness issues.

#### Synthesis of variable sampling control

As variable control periods are used as actuators in feedback schedulers it is necessary to ensure the stability of the control laws under variable sampling conditions. Indeed it is known that on-line switches between stable controlled systems sampled at different rates may lead to instability. The synthesis of control laws using variable sampling has been developed via new extensions of the gain scheduling and Linear Parameter Varying (LPV) design methods, considering here that the sampling period is the varying parameter [Oops!] .

The first point is the problem formulation such that it can be solved following the LPV design of
[26] . We first propose a parametrised discretization of the continuous time plant and of the weighting
functions, leading to the discrete-time LPV polytopic system (
1 ) with
h ranging in
[
h_{min};
h_{max}] . To get a polytopic model (and then apply an LPV design), we approximate the exponential by a Taylor series of order
N with
H= [
hh^{2}...
h^{N}] , leading to:

As the gain-scheduled controller will be a convex combination of
2
^{N} "vertex" controllers, the choice of the series order
N gives a trade-off between the approximation accuracy and the controller complexity.

To decrease the volume and number of vertices of the matrices polytope we exploit the dependency between the successive powers of the parameter
h . Recall that the vertices
_{i} of
are defined by
with
h^{i}{
h_{min}^{i},
h_{max}^{i}} . Indeed the representative point of the parameters set is constrained to be on a one dimensional curve, so that the polytope of interest can be reduced to
N+ 1 vertices

In the
framework, the general control configuration of figure
13 is considered, where
W_{i} and
W_{o} are weighting functions specifying closed-loop performances. The objective is here to find a controller
K such internal stability is achieved and
, where
represents the
attenuation level.

Classical control design assumes constant performance objectives and produces a controller with an unique sampling period. When the sampling period varies the usable controller bandwidth also varies and the closed-loop objectives should logically be adapted. Thus the performance
templates
W_{i} and
W_{o} are made partly variable as a function of the sampling frequency.

The self-scheduled controller
K(
) is the convex combination of the elementary controllers synthesised at the vertex of the polytope (
2 ); it only involves the on-line computation of the
_{i} coordinates which have simple explicit expressions for the case of the reduced polytope (
[Oops!] ,
[Oops!] ).

Under mild conditions this controller ensures the quadratic stability of the closed-loop system and the limitation of the input/output transfer -induced norm whatever are the variations of the sampling period h in the specified range.

The feasibility of the method has been assessed through various simulations and experiments ) [Oops!] , [Oops!] .

#### Process state based feedback scheduling

Variable sampling rate appears to be a decisive actuator in scheduling and CPU load control. Although it is quite conservative, the LPV based design developed in section 6.7.1 guarantees plant stability and performance level, whatever is the speed of variation of the control period inside its predefined range. Hence the control tasks periods of such controllers can be adapted on-line by an external loop (the feedback scheduler) on the basis of resource allocation and global quality of service (QoS), with no further care about the process control stability. Hence a quite simple scheduling control architecture, e.g. like a simple rescaling as proposed in [30] , or an elastic scheduler as in [29] .

Indeed, besides the flexibility and robustness provided by an adaptive scheduling, a full benefit would come by taking into account directly the controlled process state in the scheduling loop. It has been shown in [33] that even for simple case the full theoretic solution based on optimal control was too complex to be implemented in real-time. However it is possible to sketch effective solutions suited for some case studies as depicted in figure 14 taken from [Oops!] .

Conversely with previously studied CPU load regulators (
[4] ) the load allocation ratio between the control components is no longer constant and defined at design
time. It is made dependent on the measure of the quality of control (QoC) to give advantage to the controller with higher control error. The approach relies on a modified elastic scheduler algorithm, where the "stiffness" of every control task depends on the control (through the
M_{i} component in figure
14 which can be a simple gain). The approach is still simple to implement and, even if only tested in simulation up to
now, has shown significant performance improvements compared with more simple (i.e. control quality unaware) resource allocation.

However, the dynamic of the scheduling loop now includes the scheduling dependent dynamics of the process itself. Ensuring the stability of this integrated control/scheduling loop requires an adequate modelling of the relationships between the control quality and the scheduling parameters, which is still to be done in a general case.

#### Accelerable control tasks

A common assumption about the sampling rate of control tasks is that faster is the computation and better is the result, i.e. that control tasks are always accelerable. However recent investigations [27] revisited this assumption and indicated new directions.

An accelerable control task has the property that more executions are performed, better is the control performance. When used in conjunction with weakly-hard real-time scheduling design, an accelerable control task allows taking advantage of the extra computational resources that may be allocated to it, and to improve the control performance with respect to worst case design methods. In practice, however, control laws designed using standard control design methods (assuming a periodic sampling and actuation) are not necessarily accelerable. Case studies have shown that, when a control law is executed more often than allowed by the worst case execution pattern (with no gains adaption), the performance improvement may be state dependent, and that performance degradation can be observed.

Conditions for the design of accelerable tasks has been established, based on Bellman optimality principle, in the framework of a (m,k)-firm scheduling policy. Is is assumed that an optimal control law exists in the case of the worst case execution sequence, i.e. when only the
*mandatory* instances of the control task are executed to completion. It is shown that, in the chosen framework, it is possible to systematically design accelerable control laws, which control performance increases when more instances of the control task can be executed during the free
time slots of the system. The theory is quite general and does not require the process linearity.

#### Feedback-scheduling of a MPC controller for a thermal process

Model Predictive Control (MPC) is a very popular control method in industry for its ability to cope with complex non-linear systems. The basic idea consists in computing model based predictions of the future evolution of the system on a receding horizon. The main drawback of the method is its very high and variable computing cost, so that it is up to now only used for slow dynamic systems.

However, using a feedback scheduling approach allows for the on-line tuning of the timing parameters of a MPC controller, such as the sampling period and the size of the receding horizon. Such adaptation of the scheduling parameters to the operative conditions is expected to improve the method tractability w.r.t. the availability of computing resources.

The approach has been implemented on a thermal process available at Gipsa-lab. The on-line adaption of the sampling period requires the on-line discretization of the process continuous model, identified off-line as an ARMAX model. The method's overhead, due to the on-line discretization and to the elastic scheduler, are negligible compared to the constrained quadratic optimisation needed by the controller at each sample. The method has been successfully implemented using standard PCs and real-time Linux kernels, and show that it is able to easily adapt the controller's scheduling parameters w.r.t. the available computing resources ( [Oops!] ).