Second-Order Sliding Mode Control of Induction

0 downloads 0 Views 2MB Size Report
Oct 21, 2009 - realization will be limited to a finite switching frequency. ..... Figure 2.1: Two phase plane plots qualitatively showing behavior of ... Assume a plant with m inputs given in the n-dimensional ...... control object (4.10) with respect to the virtual outputs s1 and s2 to be ..... and strong negative acceleration (t ≈ 4s).
Nils Emil Pejstrup Larsen

Second-Order Sliding Mode Control of an Induction Motor Master’s thesis, October 2009

Second-Order Sliding Mode Control of an Induction Motor

Rapporten er udarbejdet af: Nils Emil Pejstrup Larsen Vejleder: Elbert Hendricks

DTU Elektro Automation and Control Danmarks Tekniske Universitet 2800 Kgs. Lyngby Denmark [email protected]

Projektperiode:

1.4.2009 – 1.11.2009

ECTS:

30

Uddannelse:

Kandidat

Retning:

Elektro

Klasse:

Offentlig

Bemærkninger:

Denne rapport er indleveret som led i opfyldelse af kravene til ovenstående uddannelse på Danmarks Tekniske Universitet.

Rettigheder:

© Nils Emil Pejstrup Larsen, 2009

Abstract The induction motor is probably the most used electrical motor today. Its main advantage over other motors is that it can be built without brushes for electrical power transfer to the rotor. It is thus very reliable. Although it was invented almost 130 years ago, it is only recently that the problem of speed control was solved efficiently. Still, the performance of existing controllers suffers from sensitivity to motor parameter variations. The rotor resistance is of particular importance because it can increase drastically when the temperature rises. One class of controllers adapt to parameter changes by estimating them online. This strategy, called adaptive control, might not work in all operation regimes and increases overall controller complexity. Another strategy is to design a controller which is less sensitive to parameter variations (robust control). That is the focus of this work. In the 1950s and 1960s, Russian scientists investigated switching control laws, e.g., control laws with an on/off element. Their goal was to realize robust control systems, i.e., control systems which are less sensitive to parameter variations and disturbances. Their research evolved into the theory of sliding mode control. The fundamental result of the theory is that an infinitely fast switching control can constrain the controlled system to only evolve (slide) along a certain surface, which has a lower dimension than the original system dynamics. On this so-called sliding surface, the system is perfectly immune to a broad class of disturbances. Of course, any practical realization will be limited to a finite switching frequency. This will introduce an error. This work is focused on second-order sliding mode controllers. They feature smaller errors than standard sliding mode controllers when the switching frequency is not infinite. Such a controller is designed for an induction motor with the goal of achieving highly robust speed control. The design also includes a sliding mode observer to estimate the rotor flux. The flux is used as part of the feedback control. Certain derivatives of motor state variables are required by the controller as well. A recently developed robust finite-time differentiator is applied to estimate those derivatives. To test the proposed design, a 1.5 kW induction motor is chosen, a load benchmark is specified and the control system performance is carefully examined by simulation.

Preface This master’s thesis is the final project for receiving the Master of Science in Engineering degree at the Danish Technical University. The work has been carried out at the Technische Universit¨at Dresden, Germany in the period from April to October, 2009. I would like to thank my supervisor, Dr.-Ing. Jens Weber, and the Chair of Power Electronics for their support. I would also like to thank my supervisor at the Danish Technical University, Elbert Hendricks, for his ideas, advice and support. Nils Emil Pejstrup Larsen Dresden, October 21, 2009

Contents 1 Introduction 1.1 Background and state of the art . . . . . . . . . . . . . . . . . 1.2 Goals and organization of the thesis . . . . . . . . . . . . . .

9 9 11

2 Sliding mode control: Theory and motivation of its use 13 2.1 Standard first-order continuous-time SMC . . . . . . . . . . . 13 2.2 Mathematical introduction of 1-SMC . . . . . . . . . . . . . . 15 3 2-SMC: A generalization of 1-SMC 3.1 From 1-SMC to 2-SMC . . . . . . 3.2 2-SMC algorithms . . . . . . . . . 3.2.1 Preliminaries . . . . . . . . 3.2.2 Twisting algorithm . . . . . 3.2.3 The sub-optimal algorithm 3.2.4 Super-twisting algorithm . 3.3 Two short notes on relative degree 3.4 Estimation of needed derivatives .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

. . . . . . . .

4 Robust induction motor control using 2-SMC 4.1 Preliminary remarks and control goal . . . . . . . . . 4.2 Assumptions . . . . . . . . . . . . . . . . . . . . . . 4.3 Induction motor model . . . . . . . . . . . . . . . . . 4.3.1 Model states and coordinates . . . . . . . . . 4.4 Control design . . . . . . . . . . . . . . . . . . . . . 4.4.1 Mathematical formulation of control problem 4.4.2 Control design – decoupling . . . . . . . . . . 4.4.3 Derivatives of sliding variables . . . . . . . . 4.4.4 Control design – preliminary attempt . . . . 4.4.5 Sliding mode control design . . . . . . . . . . 4.4.6 Sliding mode observer . . . . . . . . . . . . . 4.4.7 Differentiator . . . . . . . . . . . . . . . . . . 4.4.8 Discretization and PWM issues . . . . . . . . 4.5 Initial magnetization . . . . . . . . . . . . . . . . . .

. . . . . . . .

. . . . . . . . . . . . . .

. . . . . . . .

. . . . . . . . . . . . . .

. . . . . . . .

. . . . . . . . . . . . . .

. . . . . . . .

. . . . . . . . . . . . . .

. . . . . . . .

19 19 22 23 24 24 25 28 28

. . . . . . . . . . . . . .

31 31 32 34 36 36 36 37 38 39 39 40 43 44 47

6

CONTENTS

4.6

Construction of simulation model . . . . . . . . . . . . . . . .

5 Design example and simulation 5.1 Choice of conditions . . . . . . . . . . . . . . . . . . 5.1.1 Control task definition and motor parameters 5.1.2 Simulation conditions . . . . . . . . . . . . . 5.2 Controller parameter tuning . . . . . . . . . . . . . . 5.2.1 Stage 1 . . . . . . . . . . . . . . . . . . . . . 5.2.2 Stage 2 . . . . . . . . . . . . . . . . . . . . . 5.2.3 Stage 3 . . . . . . . . . . . . . . . . . . . . . 5.2.4 Stage 4 . . . . . . . . . . . . . . . . . . . . . 5.2.5 Result of stage 1–4 . . . . . . . . . . . . . . . 5.2.6 Robustness analysis . . . . . . . . . . . . . .

. . . . . . . . . .

. . . . . . . . . .

. . . . . . . . . .

. . . . . . . . . .

. . . . . . . . . .

47 49 49 49 51 51 55 59 60 60 62 62

6 Conclusions 65 6.1 Future work . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Appendices

71

A Simulink model 71 A.1 Source code for compiled blocks . . . . . . . . . . . . . . . . . 73 Bibliography

81

Nomenclature ω

The actual motor angular velocity

ωref

The desired motor angular velocity

φ2r

The squared magnitude of the rotor flux vector

φrα

The α component of the rotor flux vector

φrβ

The β component of the rotor flux vector

σ

Induction motor loss factor, see (4.6)

d

A general disturbance signal

dm

A matched disturbance signal

du

A unmatched disturbance signal

isα

Induction motor stator current, α component

isβ

Induction motor stator current, β component

Lh

Induction motor mutual inductance

Lr

Induction motor rotor inductance (leakage+mutual inductance)

Ls

Induction motor stator inductance (leakage+mutual inductance)

M

The torque generated by the motor

ML

The load torque attacking on the motor shaft

O(τ q )

A function smaller than a constant times τ q (“big O-notation”)

p

The number of pole pairs of the motor

Rr

Induction motor rotor resistance

Rs

Induction motor stator resistance

s

The sliding variable

Tr

Non-singular matrix for transforming a system into the regular form

8

CONTENTS

1-SMC First order sliding mode control 2-SMC Second order sliding mode control AC

Alternating Current

DC

Direct Current

EMC

Electromagnetic compatibility

FOC

Field-Oriented Control

PD

Proportional-differential, e.g., PD-controller

PWM

Pulse Width Modulation

Chapter 1

Introduction This chapter presents the current role of induction motors in the society and gives a short overview of the control problem associated with the use of this kind of motors. It is justified why sliding mode control (SMC) is of interest as a control strategy and the goals of this work are specified. Finally, an overview of the thesis is given.

1.1

Background and state of the art

This master’s thesis is dedicated to robust speed control of induction motors. The induction motor was invented in 1882 by Nikola Tesla. Initially, this motor type was only used in applications where accurate speed control is unimportant, e.g., in some home appliances, fans and pumps. No efficient way to implement speed control with induction motors was available until about 30 years ago, [1, p. 160]. Due to technological development, the three-phase induction motor fed by power semiconductors is now widely used in high performance and high power applications where accurate speed is important—for example, in paper or textile industry, in steel rolling mills or for electrical railway traction. The main advantage of the induction motor is that it can be built without using brushes for electrical power transfer to the rotor. Other types of motors, including the synchronous motor and DC motor, require brushes and are subject to brush sparking and wear. The induction motor thus features decreased maintenance costs and decreased risk of failure which are two major advantages. It is challenging to realize speed control of an induction motor. Before the problem was solved efficiently, several technologies and techniques had to

10

Introduction

be invented, including: The state-space approach (1956)1 which provided a better understanding of multivariable systems, fast semiconductor-based power converters which can be used as variable-frequency power sources, the rise in performance of digital computers, and the Field-Oriented Control (FOC; F. Blaschke, 1971). FOC is a decoupling technique for induction motors that reduces the control problem to be similar to that of a DC motor, [3, p. 191]. DC motors are known to be relatively easy to control and existing solutions have long been available. FOC works by transforming the motor variables into a coordinate system which rotates with the rotor flux, i.e., the (d, q) frame. In these coordinates, the system is decoupled into two subsystems: one for the motor torque and one for the excitation flux. A controller can be designed for each subsystem independently. The control design is relatively simple due to the decoupled structure. The controller outputs are transformed back in motor coordinates before they are fed to the semiconductor-based power converter. This control strategy is being used with success since then 1980s to achieve accurate speed control. FOC relies on exact knowledge of the rotor flux angle which can either be measured directly, e.g., using Hall sensors, or be estimated using an observer. Flux observers generally work based on rotor speed and stator current measurements. Due to the fact that Hall sensors complicate the mechanical motor design, are expensive and subject to drift of measurements, they are used more rarely than observers. If the flux estimate is not perfect, the coordinate transform will in turn result in imperfect decoupling and degradation of overall control performance. The most critical motor parameter is the rotor resistance, which value can increase up to 100% when the motor temperature rises, [4]. It is clear that the developments in induction motor control did not end with the invention of FOC. Current topics in research include a higher level of robustness against unknown load and parameter variations, faster response and a higher level of energy efficiency. Sliding mode control, which is treated in this thesis, is a promising modern control strategy for electric drives due to its ability to suppress load and parameter variations. Its foundations were laid by Russian scientists in the 1950s and 1960s. It relies on fast switching, which made its implementation at that time difficult due to the lack of fast digital computers and fast semiconductor-based power converters. The recent revolutions of computers and power semiconductors have made SMC a major and today very actual field of research by many scientists in many countries. 1

The state-space model is the central element of the so-called modern control theory. In the historical background section of the introductory book on modern linear control theory, [2, p. 7], 1956 is named as the year when the classical control theory based on transfer functions was supplemented with “modern” tools.

1.2 Goals and organization of the thesis

11

Currently, researchers in the field of SMC are striving to reduce the socalled chattering problem. Chattering is defined as unwanted and harmful oscillations in the motor outputs. It is caused by unmodeled delays in the control loop and by the fact that the switching frequency cannot be infinite as assumed in the theory of SMC. Another actual research activity is to design accurate and fast observers to successfully implement the sliding mode controllers which usually require full state feedback. It has already been proposed that second-order sliding mode control (2SMC) could be used for chattering reduction in induction motor control. The author is aware of a single paper only, [5], about 2-SMC of an induction motor. That paper is unfortunately incomplete in its treatment; it does not reveal how certain derivatives of motor outputs are calculated. Several researchers have treated the problem of derivative estimation in detail, e.g., [6], [7], but not explicitly in connection with induction motor control. The author is not aware of any publication demonstrating 2-SMC of an induction motor or other AC motor while also proposing a method for determining the required derivatives.

1.2

Goals and organization of the thesis

The justification for examining second-order sliding mode controllers is that they potentially can be used to obtain smoother speed control of induction motors. Standard sliding mode control (1-SMC) promises speed control with fast suppression of randomly applied load transients and robust operation in a wide temperature range. As already mentioned, 1-SMC suffers from the chattering problem. It is expected that 2-SMC can reduce the chattering problem (i.e., obtain smoother output) while retaining the advantages of 1-SMC. This could obviously be an economical advantage in the industry. The goals are • To introduce standard SMC (1-SMC). • To choose an induction motor model and implement it in a simulation system. • To determine if 2-SMC can be realized for that motor model without relying on exact knowledge of motor parameters and motor output derivatives. And if it is possible, to built up a simulation model for the whole control system. • To determine a usable strategy for tuning of the controller parameters and to examine the system behavior by means of simulation.

12

Introduction

In chapter 2, the theoretical foundation of 1-SMC is shortly summarized. Next, 2-SMC is introduced and treated in greater detail in chapter 3. Chapter 4 presents the theoretical results regarding the main problem of this work: Robust speed control of the induction motor using 2-SMC. Finally, chapter 5 describes the strategy for parameter tuning developed by the author. Based on simulation, the process is carried out for a chosen induction motor and the results are analyzed.

Chapter 2

Sliding mode control: Theory and motivation of its use In the previous chapter, the main goal of this work was defined; namely, to design a robust controller for an induction motor while maintaining smooth (chattering-free) operation. A justification (based on expectations) for examining 2-SMC to achieve this was given. This chapter will introduce the standard 1-SMC mathematically to lay the foundations. It is shown how Lyapunov’s Direct Method can be used to prove stability.

2.1

Standard first-order continuous-time SMC

This semiformal introduction of SMC and its associated vocabulary are largely based on [8, pp. 11–13,16]. SMC is a control strategy to stabilize the output(s) of a plant at a certain set point or around a certain trajectory. Sliding modes have first been described by scientists in the former Soviet Union in the 1950s or in the 1960s (see for example the standard work Sliding Modes in Control and Optimization [9], first published in Russian in 1981, by Prof. Vadim Utkin, one of the main contributors to the SMC methodology). Utkin and his colleges were studying variable structure systems and relay control. These control systems incorporate some kind of value-discontinuous control law. It is therefore a nonlinear control strategy. Some very simple examples of other (not SMC) discontinuous control laws are found in ordinary electrical home appliances with on/off regulators like ovens, irons and domestic heaters. In contrast to variable structure systems are control systems with value-continuous control laws, i.e., control laws that can generate any value within a continuous range (e.g., an analog voltage for a DC motor armature winding). Notice

14

Sliding mode control: Theory and motivation of its use



x˙1

s≡0

0

0

x1

0

0

s

Figure 2.1: Two phase plane plots qualitatively showing behavior of 1-SMC. The plant is defined as x˙ 1 = x2 , x˙ 2 = u + d with the output (the sliding variable) s = cx1 + x2 . The simplest 1-SMC controller u = −K sign(s) is applied with a hysteresis. In the left phase plot, the initial reaching phase before reaching the sliding phase where s ≡ 0 is clearly identifiable. After the initial reaching period, the controller is forcing the trajectories to stay on the line s = cx1 + x2 which corresponds to exponential decay of x1 with the rate defined by the control parameter c. The system has been reduced from being two-dimensional to be of just one dimension, i.e., the sliding surface s = 0 along which the system slides. When the hysteresis tend to zero width, any bounded disturbance will be rejected if K is chosen sufficiently large. This disturbance rejection is known as the invariance property. These are the main advantages of SMC. The chattering in the sliding phase is the main problem with 1-SMC. The right plot is the s-s˙ phase plane. After the initial transient, it is clear that s = 0 and that s˙ = cx2 − K sign(s) + d is discontinuous. Deviations are due to the hysteresis which is an imperfection.

2.2 Mathematical introduction of 1-SMC

15

that this distinction is a different one than the distinction between discretetime (sampled) and continuous-time control systems and that sliding mode controller variants exist in both sampled and continuous-time versions. The strength of SMC lies in its robustness against plant parameter uncertainties and its ability to decompose control problems into two subproblems of lower dimension (as will be shown later). High feedback gain is necessary to achieve these goals. In SMC, a high (theoretically infinite) gain is attained using a control signal with a discontinuous element (e.g., a sign function). Consider for example the simplest discontinuous control law u = −K sign s. Even the slightest change across s = 0 will flip the control output from K to −K or vice versa. Such a control law is theoretically realizing infinite feedback gain with a finite-valued control signal. In [10, p. 24], Utkin writes: “...the [discontinuous] element implements high (theoretically infinite) gain, that is the conventional mean to suppress influence of disturbances and uncertainties in system behavior ” and “Unlike systems with continuous control the invariance is attained using finite control actions”. In the second quote he is referring to the fact that continuous control can only attain an infinite gain using an infinite control signal. A typical trajectory of an uncertain system being controlled with 1-SMC is shown in figure 2.1. No values are specified on the axes because the intent is only to qualitatively show characteristic properties: the order reduction and the invariance to disturbances (see figure text). This figure will be referred to later in the thesis (figure 3.2) after the mathematical background has been introduced.

2.2

Mathematical introduction of 1-SMC

To motivate the use of sliding modes in control, a simple design procedure is presented here. It is shown how a stabilizing controller can be designed for a multiple-input multiple-output linear plant using sliding mode control. Further, it is shown that the system can be brought into sliding mode in finite time despite the presence of a class of bounded disturbances/parameter variations, and that the closed-loop system dynamics can be specified at will. This entire section is largely based on [11, pp. 14-20] and [10, pp. 25–28], but the author has highlighted some points which were not made very clear in those texts (see the note below). Assume a plant with m inputs given in the n-dimensional state-space representation x˙ = Ax + Bu + d,

(2.1)

16

Sliding mode control: Theory and motivation of its use

with x, d ∈ Rn , u ∈ Rm and A,B matrices of consistent dimensions. The goal is to stabilize the system at the origin x ≡ 0 despite the disturbing signal d which is assumed to be bounded. In many cases, it is practically possible to give such an upper bound for the disturbance, for example for an unknown load torque of an electric drive. To be able to show that SMC can make the control system invariant (immune) to disturbances d and parameter variations in A and B, it is necessary to perform a state transformation. It will become clear why. The following non-singular transformation   x ¯1 = Tr x (2.2) x ¯2 turns (2.1) into a new state-space representation x ¯˙ 1 = A¯11 x ¯1 + A¯12 x ¯ 2 + du ¯ ¯ 2 u + dm x ¯˙ 2 = A21 x ¯1 + A¯22 x ¯2 + B

(2.3)

of the so-called regular form which is thoroughly described in [12]. The transformation is sought to be carried out in such a way that 1) all plant parameters subject to unknown disturbances are carried in A¯21 and A¯22 , leaving only structural ones and zeros in A¯11 and A¯12 , and 2) such that all disturbances d in (2.1) are carried by dm , the so-called matched disturbance, leaving the unmatched disturbance du zero1 . In this form, the design procedure can be carried out in two stages (as it is done by Utkin in [10]), each concerning problems of order lower than the original control problem: In stage 1, design a new virtual output function s = Sx = STr x = S¯1 x ¯1 + S¯2 x ¯2 ,

s ∈ Rm

(2.4)

with as many scalar components as inputs of the plant (2.1). Later it will be shown that the dynamics of the closed-loop system is determined by S alone after the sliding mode has been reached. In stage 2, design a feedback control law u with a discontinuous element to stabilize the new output s at the origin s ≡ 0 in finite time and despite disturbances. The system stability and the finite-time convergence property are to be proved using a Lyapunov function candidate. Assume first the success of stage 2, i.e., assume s ≡ 0. Using (2.4), x ¯2 = ¯1 , reduces the system (2.3) to −S¯2−1 S¯1 x x ¯˙ 1 = (A¯11 − A¯12 S¯2−1 S¯1 )¯ x1 + du ,

1

(2.5)

The terms matched and unmatched disturbances are explained in [13, p. 17]. According to [3, pp. 42–43], they have been introduced by Drazenovic in 1969. Matched disturbances are those to which a variable structure system can be made invariant to. The condition for invariance is given as the theoretical existence of a u in (2.1) which would neutralize d (i.e., ∃u : Bu = −d) meaning the disturbance acts in the control space.

2.2 Mathematical introduction of 1-SMC

17

which has the dimension n − m compared to n of the original system (2.3). Also called the zero dynamics 2 with respect to s, it fully describes the dynamic behavior of the system when the controller is forcing s ≡ 0. The remaining states can be calculated algebraically using (2.4), i.e., x ¯2 = −S¯2−1 S¯1 x ¯1 .

If the transformation (2.2) was made in such a way that du = 0, and A¯11 , A¯12 only contain structural ones and zeros (i.e., no plant parameters), it is obvious that the dynamics of the reduced system can be specified at will with S, for example using pole placement or LQR methods3 . The chosen dynamics is completely invariant in the presence of parameter variations in A¯21 and A¯22 and matched disturbances dm since they do not appear in (2.5) (the controller designed in stage 2 neutralizes them). This was the rationale for performing the transformation (2.2) at all. Now that the closed-loop dynamics has been defined, the design of the discontinuous control law in stage 2 is given attention. The following function is used as Lyapunov function candidate: 1 V = sT s . 2

(2.6)

It is positive definite (V > 0 ∀s 6= 0) and radially unbounded (V → ∞ if just a single component of s → ∞). Differentiation yields V˙ = sT s˙ = sT S x˙ = sT S(Ax + Bu + d) = sT (SAx + SBu + Sd)

(2.7)

By choosing the discontinuous control law4 u = −(SB)−1 SAx − k(SB)−1

s ksk

the time-derivative along V reduces to s + Sd) = −kksk + sT Sd V˙ = sT (−k ksk

(2.8)

(2.9)

and because of the Cauchy-Schwarz inequality sT Sd ≤ ksk · kSdk η

z }| { V˙ < − (k − kSdk) ksk = −ηksk

s 6= 0 .

(2.10)

2 Zero dynamics and also relative degree are concepts defined by A. Isidori in [14]. They will be used later in this thesis as well. 3 Equation (2.5) corresponds to eq. 13 in [10]. In that paper by Utkin it is not obvious that it is really possible to assign closed-loop eigenvalues at will in the general case of a plant with unknown parameter variations of A11 and A12 . A note in [11] led the author of this work to the idea that the state transformation (2.2) can be carried out such that those two matrices only contain structural ones and zeros (i.e., no parameters subject to disturbances) making it a trivial task to design S in (2.5). 4 s Note that ksk is a multidimensional generalization of sign(s). It is called unit control in [3, p. 43] because the term always has the absolute value of one everywhere except on the discontinuity surface.

18

Sliding mode control: Theory and motivation of its use

In the nominal case (i.e., the plant does not deviate from the parameters in A and B), a value of η greater than zero (achievable by choosing k ≥ kSdk) ensures a negative definite V˙ . In a more realistic case, the plant has unknown (but bounded) parameter variations. If the effects of those variations can be included as a disturbance (in d), k can be chosen large enough to ensure a negative definite V˙ even in the presence of such disturbances. Thus, according to Lyapunov’s Direct Method, s = 0 is globally asymptotically stable. However, according to [11, p. 16], an even stronger property applies: The special form of (2.10) (ss˙ ≤ −η|s|) is called the η-reachability condition which for η > 0 guarantees finite-time convergence to s ≡ 0. It ensures that s˙ does not vanish in the vicinity of s like it would in case of a stable continuous control law. Moreover, s˙ remains unzero (except at s = 0 where it is formally undefined) and its sign steers to system back to s = 0. When the η-reachability condition is satisfied, the minimum step of s˙ at the s = 0 crossing is 2η. By proper design, it is thus possible (even in presence of disturbances) to force the system to reach s = 0 after a finite time and let it stay there. No continuous feedback controller can achieve this. Note that in a real system there will always be a delay and s = 0 will only be satisfied at isolated time instants. Rather, The system trajectories will be confined to a small region around s = 0. This mode is called real sliding as opposed to ideal sliding where s = 0 is always satisfied. Generally, with 1-SMC, the size of the region is directly proportional to the delay. Arie Levant has termed this sliding order 1 in his publication from 1993, [15], in which he also introduced the terms real/ideal sliding and higher order sliding modes, which are the topic of the next chapter.

Chapter 3

2-SMC: A generalization of 1-SMC Based on the introduction of 1-SMC in the last chapter, 2-SMC will now be presented as an extension of 1-SMC.

3.1

From 1-SMC to 2-SMC

Some advantages of first-order sliding mode control (1-SMC) have been motivated in the preceding sections. In particular, those are the invariance property, the simplicity of implementation of the controller itself (no precise plant model is needed) and the order reduction when the system is on the sliding surface. In all practical implementations, there are some important potential problems to be faced when using 1-SMC though: 1. Chattering: Defined as unwanted fast oscillations of the system trajectories near the sliding surface, chattering needs to be considered in any 1-SMC implementation. Because any 1-SMC control signal is of fastswitching nature, there is always the chance that those fast switchings will excite plant eigenmodes not accounted for in the design—which in turn can lead to chattering. A smooth control signal might not excite these eigenmodes. Chattering is also caused when the control law is implemented in a sampled system, which is mostly the case. Because sampled control systems act as open-loop systems between two sampling instants, it is impossible for any sampled control algorithm to satisfy a constraint with infinite accuracy when acting on a plant with uncertain internal and/or external disturbances. Also in the case of 1SMC, the trajectories will inevitably leave the sliding surface between sliding instants (discretization chattering).

20

2-SMC: A generalization of 1-SMC

ss˙ < 0, ssM > 0

ss˙ > 0, ssM < 0



sM 2

sM 3

sM 1

0

ss˙ > 0, ssM < 0

ss˙ < 0, ssM > 0 0

s



Figure 3.1: 2-SMC. Qualitative display of the reaching phase of the twisting algorithm (sliding takes place in the origin only). The points sM 1 , sM 2 and sM 3 are the first singular values of s, respectively. They are relevant for the treatment of the “sub-optimal algorithm”. The twisting is always clockwise which implies ss˙ > 0 ⇔ ssM < 0 and ss˙ < 0 ⇔ ssM > 0.

0

0

s

Figure 3.2: 1-SMC reaching phase (same as figure 2.1 right). Sliding takes place on the s = 0 axis. Compare with figure 3.1. The smooth s˙ in figure 3.1 is the main advantage of 2-SMC.

3.1 From 1-SMC to 2-SMC

21

2. Accuracy: It has been shown in [15] that real, sampled 1-SMC algorithms can keep the sliding constraint s = 0 no better than with an error proportional to the sampling time τ , i.e., the sliding error is O(τ ). 3. Relative degree one limitation: Finite-time stabilization of the sliding variable at the origin, s = 0, is only guaranteed with a 1-SMC algorithm if the algorithm can assign the sign of s˙ directly. In other words, the input must appear explicitly in the first derivative of s, i.e. the system must have relative degree one with respect to s. If more levels of differentiation of s are required before the input appears, i.e., in case of higher relative degree, 1-SMC algorithms might not be able to stabilize the system at all. There are different ways to reduce the impacts of the mentioned disadvantages and among them is application of higher order sliding mode controllers, introduced by Arie Levant (formerly L.V. Levantovsky). By definition, these controllers achieve better accuracy. Indeed, in [15], Levant has defined qth order real sliding algorithms as those SMC algorithms able to keep a constraint, s = 0, with an error O(τ q ) where τ is the sampling time. In the same paper, he shows that a necessary condition to achieve this is a that s = s˙ = · · · = s(q−1) = 0 is satisfied in an ideal sliding mode. In a later paper, [16], he adds that the qth derivative s(q) mostly is “supposed to be discontinuous or non-existent”. It is important to note this: While in standard 1-SMC, s˙ is value-discontinuous, in q-SMC, the discontinuity appears only after (at least) q-times differentiation, in s(q) . This is why s is smoother the higher the sliding order. Levant also proposes some 2-SMC control laws and provides conditions for finite-time convergence to s = s˙ = 0. Among his proposed 2-SMC algorithms are the “twisting algorithm” and the “drift algorithm”. Other authors have contributed with other 2-SMC algorithms. 2-SMC controllers as a special case of higher order sliding mode control preserve the desirable properties (in particular: invariance and order reduction) but they achieve better accuracy and guarantee finite-time stabilization of relative degree two systems. There are new problems to be faced, however: 1. 2-SMC controllers generally need tuning of several parameters. Theoretically, it is possible to find the parameters by using the convergence conditions (some are presented later on) for the controllers together with a worst-case estimate of the plant error. The convergence conditions are generally sufficient, but might be too conservative. This leaves the control engineer with the complex problem of finding the ideal set of control parameters. Some authors, [7, p. 367], [17, p. 341], suggest the trial-and-error method to solve the problem—a solution which is far from ideal in the opinion of the author: In the lack of

22

2-SMC: A generalization of 1-SMC

a more intelligent algorithm, the design engineer might try doing a “dumb” grid search, but this optimization problem may be of such high dimension/complexity that it is practically impossible to find the optimal set of parameters in the sense of some cost function. 2. In general, 2-SMC controllers rely on known s (like in 1-SMC) and additionally s. ˙ In a real application, these signals are probably not available, at least not without the use of observers or differentiators—those again being sensitive to noise and disturbances. In the literature, successful experiments using sliding mode observers [5] or robust sliding mode differentiators [18] to reconstruct s and s˙ have been reported1 , but it is generally difficult to prove the closed-loop stability, even if the controller and the observer can be proved convergent separately—the separation theorem generally cannot be applied in nonlinear control systems. Apart from troubles proving stability, the use of observers/differentiators introduces additional parameters potentially hard to determine/tune. 3. It is harder to prove stability with 2-SMC than for 1-SMC. While Lyapunov’s Direct Method can be used (see section 2.2) for 1-SMC designs, Lyapunov functions are not known for most 2-SMC designs. The first Lyapunov function to prove stability of a 2-SMC algorithm was presented in 2008, in [19], for the so-called super-twisting algorithm (introduced below). Because the Lyapunov approach generally does not lead to a conclusion on stability, “special treatments, often non-systematic, are needed ” ([18]) and Bartolini presents such a proof in several parts in [20] using a multistep algorithm. In the next sections, an overview of some important 2-SMC algorithms and their properties is given.

3.2

2-SMC algorithms

A variety of 2-SMC control algorithms have been proposed by different authors. The algorithms differ with respect to the following aspects: • Some are formulated in continuous-time (which must be discretized) and others explicitly in discrete-time (e.g., the drift algorithm is formulated in discrete-time in [15]). • Most 2-SMC algorithms are able to stabilize a sliding constraint s with relative degree r = 2. One notable exception is the super-twisting 1 The way the sliding derivatives are calculated in [5] is probably through explicit substitution in the motor model equations—a method which is sensitive to any parameter variation and thus appalling.

3.2 2-SMC algorithms

23

algorithm (to be presented) which can only stabilize r = 1 plants. • The algorithms differ in the number of necessary parameters to tune. • Most algorithms require knowledge of s and s, ˙ but some require less real-time plant information (the super-twisting algorithm) and some require other information (e.g., it will be shown that the sub-optimal algorithm is different with respect to this).

3.2.1

Preliminaries

Considered are plants which are affine in the input x˙ = f (t, x) + b(t, x)u

(3.1)

where x ∈ Rn is the system state, t the time, f , b are smooth uncertain vector functions and u ∈ R is the plant input. A sliding manifold is introduced as a control design parameter s = s(t, x) ∈ R

(3.2)

and treated as a new output of the system. s can be designed such that it has the relative degree r and a corresponding stable zero dynamics s = 0. Relative degree r means that s must be differentiated r times before the input u appears. The zero dynamics of the system (3.1) with respect to s is simply the remaining dynamics when s = 0 is forced to zero. It has the dimension n − 1. See the book by Isidori, [14], for additional information on zero dynamics and relative degree. The treatment is additionally limited to systems with constant relative degree. If the system has a relative degree r = 1 with respect to s, 1-SMC can stabilize s = 0 in finite time, but s˙ is nonzero which can easily lead to chattering in the output trajectory as described in previous sections. 2SMC can stabilize the same system (with r = 1) on the sliding set s = s˙ = 0 in finite time. Because 2-SMC additionally keeps s˙ = 0 it is an effective means of removing or reducing chattering. In sampled systems, the constraints naturally cannot be held perfectly at zero; however, the error is vanishing fast with decreasing sample times. Per definition, [15], s is O(τ 2 ) and s˙ is O(τ ) in 2-SMC. For systems with r = 2, 1-SMC can only in some case achieve exponential stability (finite-time stability being impossible) and other systems become unstable, [21, p. 64]. Therefore, at least a second-order controller is normally required for a relative degree two system. Below, some notable 2-SMC control laws are presented.

24

3.2.2

2-SMC: A generalization of 1-SMC

Twisting algorithm

The twisting algorithm, one of the first known 2-SMC algorithms, was introduced by L.V. Levantovsky (now Arie Levant) in a Russian publication in 1985. In a paper from 1993, [15], he formally introduces sliding order and higher order sliding mode as concepts and he presents the twisting algorithm again for the first time in English. Assume that s(t, x) ∈ R has been defined for the uncertain plant (3.1) such that the corresponding zero dynamics s ≡ 0 is stable and achieves the control goal. Assume a relative degree of the system with respect to s of r = 2. The remaining control problem is to stabilize s¨ = φ(t, x) + γ(t, x)u

(3.3)

of which only the bounds Φ, Γm , ΓM and s0 are known: |φ(t, x)| < Φ, 0 < Γm ≤ γ(t, x) ≤ ΓM , |s(t, x)| < s0 .

(3.4)

The twisting algorithm u=



−Vm sign(s) if ss˙ ≤ 0 −VM sign(s) if ss˙ > 0

(3.5)

ensures stabilization of the sliding set s = s˙ = 0 in finite time given a proper choice of VM and Vm . Sufficient conditions are (these might be too conservative!), [15], VM > Vm Vm > 4Γs0M . Vm > ΓΦm Γm VM − Φ > Γ M Vm + Φ

(3.6)

The trajectories in the s-s˙ plane rotate (“twist”) around the origin an infinite number of times while the distance to the origin is decreasing. The origin is reached in finite time. See figure 3.1. Note that sliding only takes place in the origin. In the reaching phase (i.e., the time before sliding commences), s converges non-monotonically.

3.2.3

The sub-optimal algorithm

The so-called sub-optimal algorithm introduced by Bartolini, Ferrara and Usai in [22] and the twisting algorithm presented above belong to the same class of 2-SMC algorithms defined by, [18],  −U sign(s − βsM ) if (s − βsM )sM ≥ 0 u= (3.7) ∗ −α U sign(s − βsM ) if (s − βsM )sM < 0

3.2 2-SMC algorithms

25

where U > 0 is the minimum control magnitude, α∗ > 1 is the modulation factor, β is the anticipation factor, and sM is the value of s at the last instant where s˙ = 0. sM is in other words the last local minimum, maximum or inflection point and is called the last singular value of s (terminology according to [18]). The sufficient conditions for finite-time convergence to the sliding set s = s˙ = 0 are, [18], U > ΓΦm   2Φ+(1−β)ΓM U ∗ . (3.8) α ∈ [1; ∞) ∩ (1+β)Γm U ; ∞ β ∈ [0; 1)

Contrary to the special case of the twisting algorithm, this general algorithm (3.7) does not only commute on the axes, see figure 3.3. It turns into the twisting algorithm (3.5) under the conditions β = 0, U = Vm , α∗ = VM /Vm which is easily verified. That ssM > 0 ⇔ ss˙ < 0 and ssM < 0 ⇔ ss˙ > 0

(3.9)

applies is easily assured for the special case β = 0 - see figure 3.1. While the twisting algorithm shows non-monotonous convergence of s in the reaching phase, the general algorithm can provide monotonous convergence by choosing parameters stricter than indicated in (3.8). This will generally increase the convergence time, however. The set of stricter parameters and the maximal duration of the reaching phase are given in [18]. With β = 0.5, (3.7) becomes the sub-optimal algorithm. A typical reaching phase is depicted in figure 3.3. Note that controller structure shifts (commutations) do not only take place on the axes. The parameter β is used to influence this in such a way that the maximal s˙ stays smaller than if the twisting algorithm were used. This could be an advantage.

3.2.4

Super-twisting algorithm

Another algorithm, the super-twisting algorithm, was introduced by Levant in 1993, in [15], and the name has been used since the publication [23] by Bartolini from 2000. It is a 2-SMC algorithm capable of stabilizing s = s˙ = 0 in finite time for relative degree one systems only. The control law u = −λ|s|ρ sign s + u1

(3.10)

u˙1 = −W sign s

is continuous in contradiction to those of the class (3.7) and it only requires measurements of s.

26

2-SMC: A generalization of 1-SMC

5



0 −5 −10 −15 −0.5

0

0.5

1

1.5

s

2

2.5

500

1

u

x1

2 0

0 0

0.2

0.4

t

0.6

−500

0

0.2

0.4

0.6

t

Figure 3.3: A typical reaching phase of the sub-optimal algorithm (U = 150, α∗ = 3, β = 0.5). Notice the “bouncing” behavior and compare with the twisting algorithm in figure 3.1. Because commutation of the sub-optimal control signal is not limited to take place on the axes, it is possible to achieve a lower maximal s˙ which might be an advantage. Plant (with sinusoidal disturbance): x¨1 = 5x1 + 50 sin 10t + u with initial conditions x1 = 2, x˙ 1 = 5. Sliding manifold: s = x1 . Simulation in Simulink with Euler fixed step T = 1 × 10−4 s.

3.2 2-SMC algorithms

27

s˙ new

1000 0 −1000 −2000 −40

−20

0

20

snew

40

60

80

100

1000 2 1

u

x1

500

0 −1

0 −500

0

0.2

0.4

t

0.6

−1000

0

0.2

0.4

0.6

t

Figure 3.4: Reaching phase using super twisting algorithm (W = 550, λ = 100, ρ = 0.5). Same plant/disturbance/initial conditions/simulation conditions as in figure 3.3, but new sliding surface snew = 40x1 + x˙ 1 . Sliding commences at t = 0.305 s after which x1 is governed by the zero dynamics snew ≡ 0 (exponential decay).

28

2-SMC: A generalization of 1-SMC

The sufficient conditions for finite-time convergence are, [21], Φ ΓM 4ΦΓM (W + Φ) λ2 ≥ Γ3m (W − Φ) 0 < ρ ≤ 0.5 W >

(3.11)

where Φ, Γm and ΓM are the same as in (3.3) and (3.4) where u has been replaced by u. ˙ To be able to compare the super-twisting with the sub-optimal algorithm, the sliding manifold has been redefined such that it has relative degree one. The simulation results are depicted in figure 3.4. Note that the controller parameters have been chosen heuristically because the convergence conditions (3.11) result in practically useless results (i.e., much too high values of s) ˙ because they are too conservative. Note also that the necessary redefinition of the sliding manifold to include the derivative x˙ 1 can be interpreted as a disadvantage of this algorithm, because it has a wider information demand.

3.3

Two short notes on relative degree

Most SMC algorithms require a certain, constant relative degree. Some nonlinear systems do not have constant relative degree (consider for example a system in which the coefficient of the input u vanishes for some system states2 ). Such systems consequently require special treatment. Another issue related with relative degree is that of fast actuators. If a systems is modeled as having a well-defined relative degree of 2, the real system might be controlled by an actuator with a very fast unmodeled dynamic behavior. In theory, this would increase the relative degree by the order of the unmodeled dynamics, but it might not render the designed control useless— at least not if the system is still fundamentally acting as a relative degree two system. As a result, oscillations in a limit cycle might arise (chattering). For 2-SMC, the error of s and s˙ is limited by O(τ 2 ) and O(τ ) respectively, where τ is the small time constant of the fast actuator [24].

3.4

Estimation of needed derivatives

As it has become clear above, it is generally necessary to estimate certain derivatives to deploy sliding mode control in practice. Indeed, the 2-SMC 2 This is also the case for the induction motor which will be treated later. It has a relative degree 2 with respect to some outputs but this number increases if the flux is zero.

3.4 Estimation of needed derivatives

29

controllers generally need the sign of s. ˙ The super-twisting algorithm does not need this information, but works only for relative degree one systems. If, for example, the twisting algorithm is to stabilize the sliding variable s of relative degree two in finite time, it would require the sign of s. ˙ To use the super-twisting algorithm, it would be necessary the redefine the sliding variable as snew = cs + s. ˙ This redefinition decreases the relative degree to one and allows the super-twisting algorithm to stabilize snew in finite time. The convergence of s would by exponential only, however. Since the new sliding surface includes s, ˙ the necessary number of derivatives is not really smaller. A way to find one or more derivatives of a virtual output must be found. If it is not feasible or possible to add an additional sensor, means of estimation must be considered. The author has found two main solutions in the literature: Using observers combined with direct evaluation of differential equations of the plant (inherently subject to accuracy problems in case of parameter variations) or using differentiators not including even a nominal plant model. The latter possibility is explored in section 4.4.7.

This page intentionally contains only this sentence.

Chapter 4

Robust induction motor control using 2-SMC In this chapter, a robust speed controller based on 2-SMC is developed for the induction motor. A mathematical model of the induction is selected and presented. The control problem is formulated and each part of the controller is presented, also including how required, but immeasurable, functions of the motor state are estimated. The problem of finding suitable controller parameters will be left to the following chapter 5.

4.1

Preliminary remarks and control goal

From now on, the control system in figure 4.1 is studied. The goal is to make an induction motor turn the shaft of a work machine accurately at the

Trajectory generator

Controller & observer

Inverter

Work machine

Motor

Current sensors 4

3

2

Speed sensor

1

Figure 4.1: Subdivisions 1–4 of the control system (the numbers are referred to in sec. 4.2): (1) Work machine, a mechanical device performing a task, (2) motor, with sensors and inverter, (3) controller & observer and (4) speed trajectory generator.

32

Robust induction motor control using 2-SMC

speed given by the trajectory generator. A feedback controller (acquiring measurements from sensors) is needed to achieve this goal because knowledge of inverter, motor and work machine parameters is only approximatively available. The following section presents what is assumed about the system. Based on these assumptions the controller design is carried out.

4.2

Assumptions

1. The work machine is the load—a torque working on the motor shaft. Very different load characteristics are possible; for example, an elevator or crane provides approximately a constant (gravitational) load torque with constant sign independent of direction and speed while a fan is dominated by speed-dependent forces. A very problematic case is the slip-stick effect caused by transitions between static and dynamic friction in some mechanical systems. The slip-stick phenomenon results in steep jumps in load torque. Here, no certain kind of load is specified initially. Instead, the load torque and its derivative are assumed smooth and bounded: ¯ L, |ML | < M

¯˙ |M˙ L | < M L

(4.1)

2. The motor is a three-phase squirrel-cage induction motor. A detailed dynamical model is used for control design, but as any other model it does not reproduce every physical characteristic. Specifically, the magnetic circuit is assumed to be operated in a saturation-free, linear region (i.e., no hysteresis losses). The iron permeability is taken to be infinite such that only the permeability of the uniform, narrow air gap affects the magnetic circuit. Additionally, the stator winding distribution is sinusoidal (to ensure steady torque generation when the motor is spinning under steady-state conditions). Effects of windings being concentrated in slots are ignored. The mathematical formulation of the model will be described in the next section. The model does take account for stator and rotor leakage inductances (i.e., the unwanted self-inductances of the stator and rotor windings). The motor parameters are assumed to be nominally known. Deviations from the nominal values are allowed if bounded. It is known that the rotor resistance is especially sensitive to temperature variations and it can increase up to factor two in some cases [4]. It is expected that a speed sensor delivers the shaft speed ω accurately and with a specified upper bound for the noise. It could work by

4.2 Assumptions

33

differentiating an optical encoder signal (for instance, using robust finite-time differentiators as described later in section 4.4.7). The way ω is estimated is not considered any further here. Similarly, current clamps and amplifiers deliver the three phase currents. These signals might be corrupted by noise from the inverter but its effect is assumed small. The motor is powered by a pulse-width modulation controlled threephase inverter. The duty cycles for each phase is provided directly from the control algorithm to be designed. The dynamics of the power semiconductors is not modeled. 3. It is assumed that the desired speed trajectory signals ωref , ω˙ ref , ω ¨ ref , the measured actual speed ω and stator phase currents ia , ib and ic are available to controller and observer. It is furthermore assumed that the algorithms are implemented in a computer with sufficient computational power to maintain a fixed sampling frequency at least two times higher than the fastest eigenfrequency of the motor electrical and mechanical subsystems (in order to satisfy the Nyquist sampling theorem). 4. The trajectory generator provides the desired shaft rotational speed ωref and its derivatives ω˙ ref , ω ¨ ref . Since the motor is supposed to track this trajectory accurately, it is necessary to assume smooth ωref , ω˙ ref and ω ¨ ref (i.e., no steps) bound by physical limitations |ωref | < ω ¯ ref ,

¯˙ , |ω˙ ref | < ω ref

¯¨ . |¨ ωref | < ω ref

(4.2)

A simple way to implement the trajectory generator if the externally provided speed setpoint ωdisc has discontinuities (e.g., steps) is to use a third-order state-space low-pass filter to get smooth ωref , ω˙ ref and ω ¨ ref . The principle is the same as for the second-order low-pass filter in figure 4.2: With properly chosen ks, the error at the summing point converges to zero quickly, i.e., ωref follows ωdisc closely but with a small delay. The derivatives of the filtered signal are available at the integrator inputs. The author used MATLAB’s besself function to design a Bessel low-pass filter (see the source code in the appendix on page 80). The cut-off frequency is to be chosen high enough to let the important reference signal part pass, but choosing a lower frequency reduces the maximal derivatives (which in turn limits mechanical stress and eases controller design).

34

Robust induction motor control using 2-SMC

2 wref'

1 wdisc

1 s

1 s

1 wref

k2 k1

Figure 4.2: Using a second-order linear low-pass filter to generate smooth and consistent ωref , ω˙ ref from a discontinuous input.

4.3

Induction motor model

In this work, a dynamical model of the induction motor has been used. The physical quantities are mapped into a certain coordinate system to be able to handle the model in a common state-space form. This form is used in several publications treating SMC of induction motors by Utkin, [9], [10], [25], and by other authors, [5], [26], [4] and [27], to mention a few. Different conventions in regard to how the physical quantities are mapped into the mentioned coordinate system are used, however, and the authors are not always explicit. This results in a factor 32 appearing in the expressions for the electrical torque M in some publications and in other not. To investigate this, the author decided to derive the state-space form from a more fundamental model from the popular book by W. Leonhard on electric motors, [1]. In the book, he derives the following model equations based on the simplifying assumptions specified in the previous section: Rs is + Rr ir +

dφs dt dφr dt φs

φr dθ dt dω J dt

= us =0 = Ls is + Lh ejpθ ir = Lh e−jpθ is + Lr ir =ω = M − ML M = pIm(i∗r φr ).

(4.3)

The mechanical rotor angle is denoted θ and the angular velocity ω. p is the number of pole pairs such that pω is the so-called electrical rotor speed. ir and is are the complex vector sums of rotor and stator currents, us is the complex vector sum of the stator input voltage, and φr and φs are the complex fluxes due to the rotor and stator currents, respectively. The effects of rotor and stator resistances are described through the parameters Rr and Rs . The mutual inductance between rotor and stator is denoted Lh . The unwanted leakage inductances Lrσ , Lsσ are included in the total inductances of the rotor and stator, in Lr = Lh + Lrσ and Lr = Lh + Lsσ . Im denotes

4.3 Induction motor model

35

the imaginary part, j is the imaginary unit and e is Euler’s number. Eliminating φs and then ir in the first four equations yields  d ejpθ φr − Lh is = us Rs is + Ls didts + LLhr dt (4.4) dφr Rr Lh −jpθ r is = −R dt Lr φr + Lr e and introducing the complex rotor flux in stator coordinates φ˜r = ejpθ φr instead of rotor coordinates simplifies the equations further to σLs didts dφ˜r dt

= −Rλ is − µjpω φ˜r + µαr φ˜r + us = jpω φ˜r − αr φ˜r + Lh αr is

(4.5)

where σ =1−

L2h , Ls Lr

µ=

Lh , Lr

Rλ = Rs +

L2h Rr , L2r

αr =

Rr Lr

(4.6)

have been used. The complex equations are then written in their real components using is = isα + jisβ

and φ˜r = φrα + jφrβ .

(4.7)

The motor torque M has been evaluated using the fourth equation of (4.3) for ir and φr = e−jpθ φ˜r again. After cancelations, the expression becomes M = pµ(isβ φrα − isα φrβ ).

(4.8)

This equation for the torque does not correspond to the one used in simulations which are presented later in the report. Rather, the equation 3pµ (isβ φrα − isα φrβ ), (4.9) M= 2 has been used since an early stage of the project. Equation (4.9) is in accordance with Utkin in [25]. The discrepancy was discovered late and it was decided to continue using (4.9). Regardless, it does not effect the conclusions because it is just a small scaling factor. It remains to be determined which expression is right. Finally, the complete model can be described in state-space form as d J dt ω d dt φrα d dt φrβ d σLs dt isα d σLs dt isβ

= 3pµ 2 (isβ φrα − isα φrβ ) − ML = Lh αr isα − αr φrα − pωφrβ = Lh αr isβ − αr φrβ + pωφrα = −Rλ isα + µαr φrα + µpωφrβ + usα = −Rλ isβ + µαr φrβ − µpωφrα + usβ .

(4.10)

The state variables ω, φrα , φrβ , isα , isβ describe the mechanical rotor speed, the rotor flux and stator currents, and uα , uβ are the stator voltage inputs— all in the stator-fixed (α, β) reference frame. It is straightforward to convert the (α, β) coordinates into physical quantities as will be shown in section 4.3.1.

36

4.3.1

Robust induction motor control using 2-SMC

Model states and coordinates

The state-space model of the induction motor has already been given in (4.10). It must be kept in mind that other state-space representations with another choice of states equivalently can describe the motor. Common variants include 1) rotor flux components and stator current components in rotor flux-oriented (d, q) coordinates [3, p. 216] and 2) rotor flux components and stator current components in stator-oriented (α, β) coordinates [3, p. 214]. The latter variant is used in this work because a controller designed for these coordinates does not need a rotor flux angle-depending coordinate transform to be implemented (which is the case for the former variant). In this work, the controller output (uα , uβ stator-oriented voltages) is transformed into the actual phase voltages ua , ub , uc using the static transform [3, p. 215] 

   T  ua −1/2 −1/2 uα  ub  = 1 √ √ uβ 0 3/2 − 3/2 uc

(4.11)

and the compliant transform to calculate (α, β) current components from actual, measured ia , ib , ic phase currents [3, p. 215] 

iα iβ



= 2/3



1 √ −1/2 −1/2 √ 3/2 − 3/2 0



 ia  ib  . ic 

(4.12)

To derive the inverter voltages u1 , u2 and u3 yet another time-invariant transform is necessary depending on whether the phases are connected in delta or star arrangement. For the purpose of simulation, none of these trivial transformations are required: Only the (α, β) coordinates are considered below. For real implementation or for comparison between simulation results and real experimental data, it is unproblematic to apply the relevant (time-invariant) transforms.

4.4 4.4.1

Control design Mathematical formulation of control problem

The model of the control object (4.10) has 5 states, 2 inputs uα , uβ and an unknown load torque ML which is seen as a disturbance. Three of the states, ω, isα , isβ , are directly measured using sensors—see figure 4.1. For the following treatment it is desirable to choose some virtual outputs in such a way that keeping these outputs zero will achieve the control goal. It

4.4 Control design

37

turns out that it is suitable to specify two such virtual outputs. If they are defined as s1 = ω(t) − ωref (t) (4.13) s2 = ||φr (t)||2 − ||φr,ref ||2 a successful controller would guarantee tracking of the external speed reference ωref (t) and keep the rotor flux magnitude constant at ||Φref ||. It has intentionally been chosen to operate with constant rotor flux in order to simplify the control design. A varying rotor flux is necessary in order to optimize power consumption, but the scope of this work is another, i.e., to examine sliding mode control. To recapitulate: The controller is successful if it can be designed to keep s1 ≡ 0, s2 ≡ 0.

4.4.2

Control design – decoupling

Since the goal has been formulated to stabilize s1 , s2 at the origin, the system should be analyzed with respect to this virtual output. The dynamics can be written        uα A11 A12 D1 s¨1 (4.14) + = uβ A21 A22 D2 s¨2 where D1 , D2 , A11 , A12 , A21 , A22 are scalar functions of the system states ω, φrα , φrβ , isα , isβ , of the motor parameters and of the load torque derivative M˙ L , but not of uα and uβ —the dependence is explicitly given in (4.22) in the following section. Equation (4.14) reveals the relative degrees of the control object (4.10) with respect to the virtual outputs s1 and s2 to be both two (the inputs appear after two times differentiation). Analyzing the matrix definitions closer, it is seen that zero rotor flux must be handled as a separate case (see section 4.5). If a new control v is introduced as u = A−1 (−D + v)

(4.15)

(with self-evident matrix definitions) it reduces the system (4.14) to     v1 s¨1 (4.16) = v2 s¨2 which can be identified as a very simple system: Two independent double integrators. The new control is thus ideally achieving a feedback linearization and has simplified the solution of the problem. Now, controllers just have to be designed for the independent subsystems s¨1 = v1 and s¨2 = v2 . The prerequisites for this to work is perfect feedback linearization which requires exact knowledge of all motor parameters, load torque derivative, system states and reference trajectories. In a practical situation, some of

38

Robust induction motor control using 2-SMC

these parameters are known with good accuracy and others only with limited accuracy or not at all. Disturbance terms can be added to include the errors which arise due to limited accuracy or no knowledge and (4.16) turns into       s¨1 v1 d1 = + . (4.17) s¨2 v2 d2 If the load torque and its derivative and all parameters uncertainties are limited such that the bounds |d1 | < d¯1 , |d2 | < d¯2 (4.18) exist, it is possible to design a s1 , s2 -stabilizing controller for (4.17).

4.4.3

Derivatives of sliding variables

The feedback linearization need the second derivatives of the sliding variables. The are calculated explicitly below. The sliding variables s1 = ω(t) − ωref (t) s2 = ||Φ(t)||2 − ||Φref ||2

(4.19)

which were defined in (4.13) and are functions of the state variables of (4.10) are differentiated once s˙ 1 = J1 32 pµ(isβ φrα − isα φrβ ) − J1 ML − ω˙ ref (4.20) s˙ 2 = 2Lh αr (φrα isα + φrβ isβ ) − 2αr (φ2rα + φ2rβ )

and once again, to yield the matrix equation        s¨1 D1 A11 A12 uα = + s¨2 D2 A21 A22 uβ with

D1 =

D2 =

A11 A12 A21 A22

= = = =

Rλ − J1 23 pµ(φrα isβ − φrβ isα )(αr + σL )+ s µ 13 2 2 J 2 pµ(φrα + φrβ )pω(− σLs )+ 13 J 2 pµ(−φrα isα − φrβ isβ )(pω)+ −1 ˙ ¨ ref J ML − ω h αr (φrα isα + φrβ isβ )(−6Lh αr2 − 2Rλ LσL )+ s ω(φrα isβ − φrβ isα )(2pLh αr )+ 2 h αr µ )+ (φ2rα + φ2rβ )(4αr2 + 2 LσL s 2 2 2 2 (isα + isβ )(2Lh αr ) pµ ) − 23 (φrβ JσL s pµ 3 2 (φrα JσLs ) h αr φrα 2LσL s h αr . φrβ 2LσL s

(4.21)

(4.22)

The scalars D1 , D2 , A11 , A12 , A21 , A22 are needed by the linearizing feedback. Note that they depend on all motor parameters, all motor states, on the speed reference signals and on M˙ L . They do not depend on ML .

4.4 Control design

4.4.4

39

Control design – preliminary attempt

The simplest imaginable way to proceed would be to use the linear feedback controls v1 = −k11 s˙ 1 − k10 s1 (4.23) v2 = −k21 s˙ 2 − k20 s2 where the control engineer can place the closed-loop poles at will by choosing proper ks. The real control output uα , uβ would be calculated using (4.15) and subsequently by applying the transforms described in section 4.3.1. Assigning proper values to s¨1 and s¨2 is basically the way to stabilize the system. This proportional-differential controller directly assigns values to s¨1 and s¨2 if d1 = d2 = 0. If the errors s1 , s2 are small compared to nonzero disturbances δ1 , δ2 , the errors—rather than the controller—assign the signs of s¨1 and s¨2 . The controller is said to have little authority under these conditions. An integral term could be added to remove any steady-state error, but before the integral term can possible take authority of s¨1 and s¨2 , an error must have been present for some time. In the next section, a sliding mode controller is designed. Since discontinuous feedback based on the sign of the error is used in SMC, the controller has a high authority of s¨1 and s¨2 even for very small errors. This is a significant difference compared with continuous feedback control. With SMC, small errors are acted upon swiftly and with an amplitude designed to dominate the disturbances.

4.4.5

Sliding mode control design

With a sliding mode control, it is possible to ensure finite-time stabilization of s1 , s2 at the origin if the disturbances are bounded as in (4.18). A firstorder sliding mode control will usually not be able to stabilize s1 , s2 because the relative degree of the system with respect to these variables is 2. In this case, 2-SMC or even higher order SMC is necessary. Here, the twisting algorithm (a 2-SMC algorithm) is used. While a discontinuous control has strong authority of the controlled system in the vicinity of the sliding surface, the same is no true far from the sliding surface. On the contrary, a continuous proportional-differential (PD) feedback has limited authority near the sliding surface, but a strong one far from it. For the same reasons, i.e., to improve the convergence rate and to achieve a wider domain of attraction, [19, p. 2858] and [5] suggest to add a continuous feedback vc to the discontinuous one. This procedure is adopted here and called composite 2-SMC+PD control. The resulting control becomes vi = vd,i + vc,i

i = 1, 2

(4.24)

40

Robust induction motor control using 2-SMC

where vd,i is the output of the twisting algorithm  −Vm,i sign si if si s˙i ≤ 0 vd,i = −VM,i sign si if si s˙i > 0

i = 1, 2

(4.25)

and vid is the linear state feedback vc,i = −ki2 si − 2ki s˙ i

i = 1, 2.

(4.26)

Note that this control law reduces the plant to have same the behavior as two critically damped oscillators of the form s¨i + 2ki si + ki2 si = 0 (valid in the absence of the discontinuous feedback and plant disturbances). Critical damping means fastest possible convergence without overshoot. If the disturbances are bounded as in (4.18), it is possible (see section 3.2.2) to choose the gains Vm,1 , VM,1 , Vm,2 , VM,2 such that s1 , s˙ 1 , s2 , s˙ 2 converge to zero in finite time and stay there.

4.4.6

Sliding mode observer

To realize the feedback law (4.15) and (4.24), the following quantities are required: The inverse of the A matrix and the D matrix for linearizing feedback, the two sliding variables s1 , s2 and their derivatives s˙ 1 , s˙ 2 . The sliding variables do only depend on reference speed ωref , actual speed ω, reference rotor flux and actual rotor flux φ2r = φ2rα + φ2rβ . The matrices A−1 and D, however, depend on all motor parameters, on all 5 state variables, on the reference signal ω ¨ ref and on the derivative of the load torque M˙ L . For the linearizing feedback, the controller will use nominal motor parameters. The reference signal ω ¨ ref is provided. The derivative of the load torque M˙ L is impossible to forecast so it will be approximated to M˙ L ≡ 0 (corresponding to a slowly varying load). Of the 5 state variables, only the rotor flux components φrα , φrβ are unknown and have to be estimated. This is done using an observer which is presented below. In the next section, it is shown how the derivatives of the sliding variables are estimated without relying on exact knowledge of the motor parameters. The simplest way to estimate the rotor flux is to integrate the second and third equation of (4.10) online in the controller hardware. This requires the use of the measured signals ω, isα and isβ . In [25, p. 279], it is shown (using a simple Lyapunov candidate function) that the estimation errors φ¯rα = φˆrα − φrα and φ¯rβ = φˆrβ − φrβ converge to zero. The rate of convergence is not adjustable, however, and this method of estimation may be too slow. There exist several ways to estimate the flux while being able to adjust the convergence rate. One way would be to implement an Extended Kalman Filter, which is a recursive state estimator for nonlinear systems. In each time step, the motor equations would be linearized. Then a feedback gain

4.4 Control design

41

matrix, optimal with respect to process and measurement noise, would be calculated. Since this process is calculation intensive and because this report is on sliding mode control, a sliding mode observer is used instead. It is nonlinear by nature and no online linearization and optimization is needed. Its convergence can be shown using Lyapunov’s Direct Method. The sliding mode observer proposed by the authors of [26] is used. It is similar to the sliding mode flux observer presented by Utkin in [3] but the gains have been modified to be rotor speed dependent to improve the convergence rate. An extra equation for online rotor resistance estimation has been left out here in order to reduce complexity. The observer differential equations are d ˆ dt φrα d ˆ dt φrβ dˆ isα σLs dt dˆ σLs dt isβ

= Lh αrˆisα − αr φˆrα − pω φˆrβ + Gx1 Is = Lh αrˆisβ − αr φˆrβ + pω φˆrα + Gx2 Is = −Rλˆisα + µαr φˆrα + µpω φˆrβ + usα + Gz1 Is = −Rλˆisβ + µαr φˆrβ − µpω φˆrα + usβ + Gz2 Is

(4.27)

which are the last four equations of (4.10) with ω as a parameter instead of an observer variable and with added discontinuous gains based on the switching function     sign(isα − ˆisα ) − sign(¯isα ) Is = = . (4.28) − sign(¯isβ ) sign(isβ − ˆisβ ) This is a first-order sliding mode observer. By proper choice of the gains Gz1 and Gz2 , the observer will reach the intersection of the sliding surfaces defined by ¯isα = ˆisα − isα = 0, ¯isβ = ˆisβ − isβ = 0 in finite time. After arriving in sliding mode, and if Gx1 and Gx2 are properly chosen, the errors φ¯rα = φˆrα − φrα and φ¯rβ = φˆrβ − φrβ converge asymptotically to zero as will be shown using Lyapunov theory. The gain matrices are given as follows     η1 0 Gz1 (4.29) = Gz = 0 η1 Gz2 # "   −q2 ω q2 αr − µ1 Gx1 (4.30) Gx = = η1 q2 ω q2 αr − µ1 Gx2 where η1 and q2 are the observer gains to be tuned. The observer error dynamics is d ¯ dt φrα d ¯ dt φrβ d¯ σLs dt isα d¯ σLs dt isβ

= Lh αr¯isα − αr φ¯rα − pω φ¯rβ + Gx1 Is = Lh αr¯isβ − αr φ¯rβ + pω φ¯rα + Gx2 Is = −Rλ¯isα + µαr φ¯rα + µpω φ¯rβ + Gz1 Is = −Rλ¯isβ + µαr φ¯rβ − µpω φ¯rα + Gz2 Is .

(4.31)

42

Robust induction motor control using 2-SMC

To prove observer convergence, it is first shown that sliding mode will take place on the sliding surfaces ¯isα = 0, ¯isβ = 0 using the positive definite Lyapunov candidate function Vi = 12 (¯i2sα + ¯i2sα ). Its derivative is V˙ i = ¯isα¯˙isα + ¯isβ¯˙isβ = 1 ¯ ¯ ¯ ¯ ¯ σLs isα (−Rλ isα + µαr φrα + µpω φrβ − η1 sign isα ) 1 ¯ ¯ ¯ ¯ + σLs isβ (−Rλ isβ + µαr φrβ − µpω φrα − η1 sign ¯isβ ) = 1 − σL [|¯isα |(η1 − fα sign ¯isα ) + |¯isβ |(η1 − fβ sign ¯isβ )] s Rλ ¯2 − σLs (isα + ¯i2sα )

(4.32)

where fα = µ(αr φ¯rα + pω φ¯rβ ) and fβ = µ(αr φ¯rβ − pω φ¯rα ). If the condition η1 > |fα | ∧ η1 > |fβ |

(4.33)

is fulfilled, V˙ i is negative definite and satisfies even the η-reachability condtion (which was also used in chapter 2.2, see (2.10)). Finite-time convergence of ¯isα = 0, ¯isβ = 0 is thus given. Next, the asymptotic convergence of φ¯rα and φ¯rβ to zero must be proved. In order to do so, it is useful to determine a continuous version of Is (denoted Is,eq ) which would have the same effect on the system as the actual (discontinuous) signal. Such a signal is called the equivalent control, [9, p. 14], and is obtained by formally setting ¯isα = 0, ¯i˙ sα = 0, ¯isβ = 0, ¯i˙ sβ = 0 and solving for Is in the two lower equations of (4.31). The equivalent control is " # − η1 (µαr φ¯rα + µpω φ¯rβ ) Is,eq = . (4.34) − η1 (µαr φ¯rβ − µpω φ¯rα ) Notice that the equivalent control is just at tool to demonstrate convergence; it could not be used as actual input to the observer since it depend on unknown variables. When substituted for Is in the upper two equations of (4.31), the flux error dynamics gets d ¯ dt φrα d ¯ dt φrβ

= φ¯rα q2 (−αr2 µ − ω 2 µp) + φ¯rβ q2 (ωµαr − αr µpω) = φ¯rβ q2 (−αr2 µ − ω 2 µp) + φ¯rα q2 (−ωµαr + αr µpω)

(4.35)

where ¯isα = 0, ¯isβ = 0 have been used once more. The Lyapunov candidate function Vφ = 21 (φ¯2rα + φ¯2rβ ) will be used to prove that the flux estimation errors converge to zero. Its derivative V˙ φ = −q2 (φ¯2rα + φ¯2rβ )(αr2 µ + ω 2 µp)

(4.36)

is negative definite for q2 > 0 which proves that flux observation error decreases asymptotically (not in finite time because the η-reachability condition does not hold for (4.36)).

4.4 Control design

43

To recapitulate: In order to make the observer converge, η1 must be chosen larger than the maximal value of a function depending on motor parameters, rotor speed and observer error (condition (4.33)). It is not possible to give an exact value for the maximal observer error (because it depends on unknown initial conditions), so an alternative approach would be to make a qualified guess and verify it through simulation. After successful choice of η1 , the rate of asymptotic convergence of the flux estimate should be tuned. It is governed by q2 > 0.

4.4.7

Differentiator

In the previous section, it has been described how all quantities necessary for an approximative linearizing feedback can be estimated. Even though the linearization is only approximate, it is expected to ease control significantly. The result of a non-ideal linearization must be compensated for by the sliding mode control feedback. In order to make that work, the sliding variables on the one hand and their derivatives on the other must be consistent. The time derivatives of the sliding variables s˙ 1 , s˙ 2 along the trajectories of the induction motor equations (4.10) depend algebraically on the torque load ML and on several of the physical motor parameters of which no exact knowledge is assumed. The explicit expression for the derivative was given as (4.20). Using the explicit expressions in (4.20) to calculate the derivatives will lead to inconsistency with the sliding variables in the case of uncertain parameters and unknown ML . The derivatives are thus estimated through numerical differentiation which is now described. Estimation of sliding derivatives through numerical differentiation is treated in [18] for several mechanical systems. The author is not aware of any publication using numerical differentiation in connection with sliding mode control of an induction motor. It is known that numerical differentiation is sensitive to noise. It is normally necessary to low-pass filter (i.e., to limit the bandwidth of) the signal of interest. This introduces a phase shift which might not be acceptable. A recent development in this domain is the contributions of Arie Levant since 1998 with his family of robust exact finite-time differentiators based on 2SMC. The author of this thesis decided to use Levant’s differentiators after failure using ordinary backward difference derivative combined with a lowpass filter. In [16], Levant proposed a differentiator with the differential equations √ p z˙0 = −1.5 L |z0 − s| sign |z0 − s| + z1 (4.37) z˙1 = −1.1L sign(z0 − s) where the numbers 1.5 and 1.1 are “suitable factors” determined through

44

Robust induction motor control using 2-SMC

simulation by Levant and L is a tunable parameter which must satisfy the condition |¨ s| ≤ L. In the absence of noise, Levant has shown that the estimates are exact after finite time: z0 = s and z1 = s. ˙ In the presence of noise characterized by the simple inequality |s−s0 | ≤ ǫ where s0 is the noisefree signal of interest and s is the actual signal with noise, the estimation errors are as low as, [16], |z0 − s0 | ≤ µ0 ǫ 1 |z1 − s˙ 0 | ≤ µ1 ǫ 2

µ0 > 0, µ1 > 0

(4.38)

where µ0 and µ1 are constants bounded by the properties of the input signal s. To demonstrate the effectiveness of the differentiator, simulation examples with two different test signals are shown in figure 4.3 and 4.4. Gaussian distributed noise has been added for realism. The algorithm is discretized using the Euler method and the time step is T = 1 × 10−5 . The value for L is 50000. The results are compared to linear backward differentiation ) (x′ ≈ x(t)−x(t−τ ) of the low-pass filtered test signals. The first test signal τ is not physical because its second derivative is discontinuous and does thus not satisfy the condition |¨ s| ≤ L. It is seen that the derivative is nonetheless estimated properly after a short transient of finite duration. The second test signal has a continuous second derivative with a maximal value close to −9000 which fulfills |¨ s| ≤ L, which was given as the condition for finite-time exact differentiation. Indeed, the derivative calculated through Levant’s algorithm cannot be visually distinguished from the ideal value. In both cases, the noise level in the derivative is approximately 10 times lower when using Levant’s differentiator than when using linear backward differentiation. Levant’s differentiator thus seems to be a good alternative to linear backward differentiation with respect to convergence time and noise level, and suitable for obtaining a consistent estimate of the derivatives of the sliding variables.

4.4.8

Discretization and PWM issues

While the induction motor and the load make up an analog (time-continuous) system, the inverters which are normally used to feed the stator windings are always operated in a sampled on/off mode (the only exception is for very small motors with output power in the order of few watts). It is standard practice to operate the power semiconductors at a fixed frequency (this is due to various reasons; among them to ease output filter design and to be able to cope with EMC constraints). This switching frequency must be low enough to keep switching losses acceptable but also high enough to reduce ripple and delay. When present, the latter is a challenge for control performance. In this work, the delay is taken into account because it is one of the imperfections which prevent ideal sliding mode to occur. The internal

4.4 Control design

45

(a) Test signal plus white Gaussian noise 100 0 −100 0

0.5

1

1.5

2

0.5

1

1.5

2

0.5

1

1.5

2

(b) Num. derivative using low-pass filter and Simulink derivative block 1000 0 −1000 0

(c) Num. derivative using Levant differentiator

1000 0 −1000 0

Figure 4.3: Numerical differentiation. Test signal (a) has discontinuous derivative. White Gaussian noise (variance σx2 = 1) has been added to (a). The exact derivative consists of a sequence of steps from zero to ±100 and ±1000. (b) is the noisy 1 and slowly converging result of low-pass filtering ( 0.01s+1 ) followed by linear differentiation using the Simulink block. The output from the Levant differentiator (c) converges faster and has 10 times lower noise level even though convergence for discontinuous-derivative signals is not proved for the Levant differentiator.

(a) Continuously differentiable test signal plus white gaussian noise 150 100 50 0 0

1

2

3

4

5

1

2

3

4

5

1

2

3

4

5

(b) Num. derivative: Low-pass filter and Simulink derivative block 500 0 −500 0

(c) Num. derivative: Levant differentiator

500 0 −500 0

Figure 4.4: Like figure 4.3, but with continuously differentiable test signal (a) with Gaussian noise (variance σx2 = 1). The exact derivative has additionally been plotted in (c), but is not visible due to almost perfect tracking using Levant differentiator.

46

Robust induction motor control using 2-SMC

working of the inverter is not modeled and, for simplicity, it is assumed that the inverter can deliver any given voltage (up to the link voltage), hold this voltage one sampling period, and apply a new voltage in the next sampling period. In reality, due to the on/off mode of operation, this has to be approximated by programming a new duty cycle in each switching period such that the average voltage in each period equals the desired voltage, i.e., Pulse Width Modulation (PWM). This simplification is not expected to introduce any significant error; after all, the delay is the same and the averaged voltage is the same no matter which way it is simulated. Different parts of the control algorithm could operate at different sample times. While there is no point in generating output voltages faster than the inverter switching frequency, it could be useful to measure outputs and update the observer at a faster rate. The author has considered simulating the whole control system at a fixed time step equal to the fastest sample time of all control units. For this to be valid, that sample frequency should also be significantly faster than the fastest eigenfrequency of the motor/loadsubsystem. In order to achieve a better trade-off between accuracy and computational resources, it was instead decided to use the Dormand-Princeintegrator with variable time step as it is implemented in MATLAB Simulink (ode45). It is a combined fourth- and fifth-order integration algorithm which means that the error made in each step is smaller than k1 h4 and k2 h5 (h being the step size and k1 , k2 some constants), respectively. The local error of the fourth-order part is estimated as the difference between the fourthand fifth-order result and this error is used to adaptively calculate the step size in order to keep the local error below a given limit. This approach still allows some parts of the simulated system to work at a fixed sampling frequency. Sliding mode control algorithms are typically defined and described in continuous time in the literature. When used with inverters, as described above, the output of the control algorithm must be discretized by connecting it to a sample and hold block with a time period equal to the switching period. This imperfection will introduce a limit cycle in the vicinity of the ideal sliding surface (this will be studied later on, in chapter 5). The dynamic parts of the sliding mode control algorithms (specifically: differentiators and observer) are calculated using simple Euler integration with fixed step size as recommended by Arie Levant in several of his publications, [15], [28], [16]. Levant did not provide an explanation for this. The author has indeed chosen to use Euler integration for the discretization of differentiators and observer—not because of Levant’s statement but because of the simplicity and because it turned out to be working well. This procedure is used for simulation, but it would also be suitable to implement in a digital signal processor.

4.5 Initial magnetization

4.5

47

Initial magnetization

In the control design above, a nonzero rotor flux has been assumed, meaning at least one of φrα , φrβ must be nonzero. If the flux is zero, the A matrix of the linearizing feedback becomes singular (not invertible). Likewise, the relative degree of the system with respect to the sliding variables would increase from two to three, which would violate the convergence conditions of the sliding control algorithm. Since the controller is keeping the flux constant and nonzero during operation, the case of zero flux only has to be considered for the start-up of a demagnetized motor. The motor could be magnetized initially using an open-loop controller. After a short start-up time, the control algorithm designed here could take over. This has not been considered further within the scope of this work. Rather, nonzero initial values of the rotor flux variables are assumed.

4.6

Construction of simulation model

The described motor model as well as the composite 2-SMC+PD controller, the sliding mode observer and the Levant differentiator have been implemented as MATLAB Simulink model blocks and connected graphically in a Simulink model file. The model files are found in appendix A. The blocks were initially written as MATLAB “Level 1 M s-functions” in MATLAB’s “M” scripting language but they were found to be too slow. In order reduce simulation time, they were rewritten as MATLAB “Level 2 C s-functions” in the C programming language. They must be compiled for the computer platform on which they are to run. In the process, they get optimized to use the specific architecture and processor features available (in this case, a Intel Pentium Dualcore 1.80 GHz running Windows XP). The MEX compiler which is bundled with MATLAB was used. The increase in speed was noticeable. The motor model was written with “continuous” sample time. Notice the zero-order hold and the rate transition blocks in the model on page 71. They ensure that the voltages controlling the motor get updated just once every “inverter switching period”, as was described in section 4.4.8. The torque load is by nature not sampled so it is applied without delay. The observer is supposed to operate in a digital signal processor, so it is implemented with fixed sample time, just like the differentiators are. While the advanced Dormand-Prince integrator is used by Simulink for the blocks

48

Robust induction motor control using 2-SMC

with “continuous” sample time, the much simpler Euler integration algorithm has been built into the observer and differentiator blocks. While the Euler algorithm certainly is less accurate, it is easier to implement in a digital signal processor. The source code is available in appendix A for the most important blocks. The rest of the code and the files describing the particular configuration of each simulation setup, can be found on the included CD-ROM.

Chapter 5

Design example and simulation The controller which has been presented in the previous chapter is now tested by simulation. First, a control task is defined and a suitable motor is chosen. Then, the controller and observer gains are determined using an approach developed by the author. The behavior of the control system is analyzed.

5.1 5.1.1

Choice of conditions Control task definition and motor parameters

The control task is defined in figure 5.1. The desired trajectory of the shaft angular speed (left side of the figure) is available to the controller together with the first and second derivatives which are continuous. The load torque in the right of the figure is applied on the motor shaft. It has a continuous derivative. The load torque is not available to the control algorithm, but the control design has been carried out under the assumption that the load torque has a bounded continuous derivative. These trajectories were designed to test different operation regimes of the motor. They have been chosen inspired by the induction motor benchmark in [5] and they do not correspond to a real world problem. Tested regimes are: Zero speed with no load (t < 0.5 s) and varying load (t > 4.5 s); full rated speed with no load (t ≈ 3 s), half rated load and full rated load; and strong negative acceleration (t ≈ 4 s). Although no frequency response analysis is carried out, the successful tracking of a steep reference trajectory

50

Design example and simulation

15

ML (Nm)

ωref (s−1 )

200 100 0 −100

0

2

4

6

8

10 5 0 −5

10

0

2

0

2

4

6

8

10

4

6

8

10

M˙ L (kNms−1 )

ω˙ ref (ks−2 )

0.5 0 −0.5 −1

0

2

4

6

8

0.1 0 −0.1

10

Time t (s)

ω ¨ ref (ks−3 )

5 0 −5 −10

0

2

4

6

8

10

Time t (s) Figure 5.1: Speed (right) and load torque (left) references. Notice the units.

Stator resistance Rotor resistance Stator inductance Rotor inductance Mutual inductance Number of pole pairs Rotor moment of inertia DC link voltage Max. load torque Max. speed Nom. stator flux magnitude Max. power

Rs Rr Ls Lr Lh p J

= = = = = = =

φ0

=

1.633 Ω 0.93 Ω 0.142 H 0.076 H 0.099 H 2 0.029 kg m2 450V ±7 N m 1430 rpm 0.59 V s 1500 W

Table 5.1: Leroy Somer A3L induction motor parameters (all referenced to stator side) and ratings. Sources: [27], [5].

5.2 Controller parameter tuning

51

in presence of steep load variation is an indicator of high controller bandwidth. It was described in section 4.2 how the trajectories are generated for simulation purposes. The motor with the parameters given in table 5.1 is selected for simulation. Its rated speed and its rated load are tested to the limit with the above described control task. The switching frequency of the power semiconductors is initially fixed at the value f = 20 kHz which is a normal value for output powers in the order of 1 kW. When specific hardware is chosen to carry out a real experiment, the switching frequency as well as all other physical parameters and conditions should be adjusted.

5.1.2

Simulation conditions

Simulink version 7.0 in MATLAB 2007b is used for simulation with the variable step solver Dormand-Prince (ode45). The relative tolerance is set to 1 × 10−6 . This means that an integration step will be repeated with a smaller step size until the estimated error in this step is smaller than 0.0001% compared to the current state variable. Note that the errors might sum up and the absolute error after several steps can be more significant. To ascertain that the simulator is providing reliable results, some of the simulations have been tested with deviating tolerance settings. Small changes in these settings should not change the character of the results.

5.2

Controller parameter tuning

In the following, it is shown how the controller parameters are determined for this motor. As mentioned in chapter 3, the convergence conditions for the 2-SMC algorithms are not very useful for design because they are too conservative. The same is the case for the Levant differentiators because it is not easy to know the bandwidth of the sliding variables s1 and s2 which are to differentiated. No solution to this problem can be found in the sliding mode literature currently. As part of this work, the author has developed an iterative approach to find a working set of parameters. It is based on four stages which will be referred to through the rest of this chapter. The principle is to start off letting the controller know all relevant parameters and variables exactly in stage 1. Then, step-by-step, exact knowledge is replaced by estimates while analyzing changes in closed-loop behavior

52

Design example and simulation

Stage Linearizing feedback Motor parameters Load torque derivative Ref. trajectories Motor ω, isα , isβ Motor φrα , φrβ Sliding vars s1 , s2 Ref. trajectories Motor ω Motor φrα , φrβ Sliding derivatives s˙ 1 , s˙ 2 Motor parameters Load torque Ref. trajectories Motor ω, isα , isβ Motor φrα , φrβ

1&2

3

4

exact exact exact exact exact

exact M˙ L ≡ 0 exact exact observed

exact M˙ L ≡ 0 exact exact observed

exact exact exact

exact exact exact

exact exact exact exact exact

exact exact exact exact exact

exact exact observed differentiated n/a n/a n/a n/a n/a

Table 5.2: How information is made available to the controller in the four control stages.

carefully. In stage 4, the controller is only using information realistically available. The idea behind each stage is now presented. In stage 1, the 6 parameters of the 2-SMC and PD controllers are determined. Perfect knowledge of all motor parameters, states and of load torque derivative M˙ L is assumed so far. The control algorithm requires the availability of • the time-varying matrices realizing the feedback linearization (A11 , A12 , A21 , A22 , D1 and D2 ) which depend on all motor parameters and all states, load torque derivative M˙ L and reference trajectories, • the sliding variables s1 , s2 which are only depending on motor states and reference trajectories, and • the derivatives of the sliding variables s˙ 1 , s˙ 2 which can be calculated algebraically only knowing motor the parameters and the states, the load torque derivative and reference trajectories. In stage 1, information which is not realistically available is demanded (e.g., directly measured flux values and M˙ L ). The purpose of the stages 2–4 is to find proper parameters for the observer and for the two differentiators. The proposition is that the controller will work with observer and differ-

5.2 Controller parameter tuning

M˙ L v1 v2

ω ¨ ref

53

ML usα usβ

LFB

IM 5

ω, φrα , φrβ , isα , isβ

usα ,usβ 2 ω, isα , isβ SMO 3

ωref Twist. 1

s1

ω

ML , ω˙ ref Lin. 1

s˙ 1

4 φrα , φrβ , isα , isβ

φref Twist. 2

s2

Lin. 2

s˙ 2

2 φrα , φrβ 4

φrα , φrβ , isα , isβ

Figure 5.2: Simplified block diagram of stage 1 (determine controller gains) and stage 2 (determine observer gains). IM=Induction Motor, LFB=Linearizing Feedback, SMO=Sliding Mode Observer, Twist.=Twisting algorithm, Lin.=Linear Feedback

54

Design example and simulation

0 v1 v2

ω ¨ ref

ML usα usβ

LFB

IM 3

ω, isα , isβ φˆrα , φˆrβ

usα ,usβ 2 ω, isα , isβ SMO 3 2

ωref s1

Twist. 1

ω

ML , ω˙ ref Lin. 1

s˙ 1

Twist. 2

s2

Lin. 2

s˙ 2

4

φrα , φrβ , isα , isβ φref 2 φrα , φrβ 4 φrα , φrβ , isα , isβ

Figure 5.3: Simplified block diagram of stage 3 (test with realistic linearizing feedback ). Compare to figure 5.2; the actual flux values and load torque derivative are no longer available to the LFB. Observed values are used instead and the load torque derivative M˙ L is assumed zero (good approximation for slowly varying load).

0 v1 v2

ω ¨ ref

ML usα usβ

LFB

IM 3

ω, isα , isβ φˆrα , φˆrβ

s1

ω

s˙ 1 SMD φref s2

Twist. 2 Lin. 2

2

ωref

Twist. 1 Lin. 1

usα ,usβ 2 ω, isα , isβ SMO 3

s˙ 2

2 ˆ ˆ φrα , φrβ

SMD

Figure 5.4: Simplified block diagram of stage 4 (determine differentiator gains). The sliding derivatives are estimated by means of Levant Sliding Mode Differentiators (SMD) to ensure consistency between the sliding variables and their derivatives.

5.2 Controller parameter tuning

55

entiator estimates as well, such that only measured signals are used. The realistic configuration corresponds to stage 4. No proof is provided. The separation theorem1 from linear control theory can generally not be applied on nonlinear systems. The stages are 1. Determine controller gains (block diagram 5.2): Vm,1 , Vm,2 , VM,1 , VM,2 as well as k1 and k2 . Perfect knowledge of all parameters and states is assumed. 2. Determine observer gains (block diagram as above): η1 , q2 . The observer is not yet in the loop, but it is acquiring input from the closedloop system which dynamics already should be final. 3. Test with realistic linearizing feedback (block diagram 5.3). Use observer flux estimates and the approximation M˙ L = 0 in the feedback. Is the system dynamics basically unchanged? 4. Determine differentiator gains L1 , L2 with observer and differentiator in loop (block diagram 5.4). The differentiators are now used for estimation of the sliding derivatives. Only actually measured signals are now used by the controller. Is the system dynamics still acceptable? Refer to the block diagrams and the table 5.2 to see how signals are routed in each stage. Note: The set of controller parameters and system initial conditions given in table 5.3 will be used for all simulations when nothing else is stated. The values are used as reference values and are the final values found. In the following it is described how they were found.

5.2.1

Stage 1

The purpose of stage 1 is to find suitable controller gains for the twisting algorithm Vm,1 , Vm,2 , VM,1 , VM,2 as well as k1 and k2 for the additional linear feedback. First, linear feedback gains are found without using SMC feedback at all. Different values for k1 , k2 are tested by simulation and k1 = 60, k2 = 60 are found to provide a reasonable small error (after the initial transient, the speed error is less than 0.2 s−1 ). See figure 5.5(a). Notice the steady-state error. It is initially surprising that there is a steady-state error: The linearizing feedback is exact in stage 1 so there should be no work to do for the feedback controller after the settling of the initial conditions. The 1 In linear control systems, the separation theorem allows to conclude that the total observer+controller system is stable if the controller and observers are stable independently. There exists no generalization of the separation theorem for nonlinear systems.

56

Design example and simulation

Inverter Switching period Motor initial conditions Angular speed Rotor flux Stator current Observer initial conditions Rotor flux Stator current Controller Linear feedback Twisting 2-SMC

Tinv

=

50 × 10−6 s

ω(0) φrα (0) φrβ (0) isα (0) isβ (0)

= = = = =

15 s−1 √ 0.9φ0 /√2 0.9φ0 / 2 0 0

φˆrα (0) φˆrβ (0) ˆisα (0) ˆisβ (0)

= = = =

√ 2.0φ0 / 2 √ 0.5φ0 / 2 0 0

k1 k2

= = = = = =

60 60 10000 2000 20000 5000

Tobs

= = =

10 0.02 Tinv

z0 (0) z1 (0) L1 Tdiff,1

= = = =

ω0 0 50000 Tinv /5

z0 (0) z1 (0) L2 Tdiff,2

= = = =

0 0 500000 Tinv /5

VM,1 Vm,1 VM,2 Vm,2

Observer η1 q2 Sample time Differentiator for s1 Initial z0 Initial z1 Gain Sample time Differentiator for s2 Initial z0 Initial z1 Gain Sample time

Table 5.3: Parameters used for simulation when nothing else is stated.

x 0.1

2 1 0 −1 −2

−4

4

x 10

2 0 −2

8 6 4 2 0

−4

2

x 10

1 0 −1

0

2

−4

x 10 4 2 0 −2 −4

Flux error s2 (V2 s2 )

−2 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (b) Stage 1 with 2-SMC+PD controller. The addition of a discontinuous feedback had the same effect as very high gain. As seen from the plot, the error after the initial transient is lower than 0.4 × 10−4 s−1 . Speed error s1 (s−1 )

−4

Flux error s2 (V2 s2 )

2

x 0.01

4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (a) Stage 1 with PD controller only. The PD controller inherently exhibit a steady-state error, as seen in the plot. Speed error lower than 0.2 s−1 . Speed error s1 (s−1 )

0

57

Flux error s2 (V2 s2 )

Speed error s1 (s−1 )

5.2 Controller parameter tuning

−4

2

x 10

1 0 −1

2

−3

x 10 8 4 0 −4 −8

Flux error s2 (V2 s2 )

Speed error s1 (s−1 )

−2 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (c) Stage 3. Same 2-SMC+PD controller, but with “realistic” linearizing feedback. Except for two spikes at 2.5 s and 3.5 s (coincident with large values of M˙ L ), the error did not increase more than 50%. 0

2

x 0.01

1 0 −1

−2 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (d) Stage 4. Same 2-SMC+PD controller. Only “realistically” available information. The speed error is lower than 0.008 s−1 except at 2.5 s. 0

2

Figure 5.5: Speed error (s1 ) and squared flux error (s2 ) for different controllers. Parameters in table 5.3.

58

Design example and simulation

0.00s to 0.30s

0.000s to 0.300s

100 20

0

10 s˙ 2

s˙ 1

−100 −200

0

−300

−10

−400

0

10 s1 0.15s to 0.30s

20

−0.1

0

0 s2 0.150s to 0.300s

0.1

0.015

s˙ 2

s˙ 1

0.01 −0.5

0.005 −1

0

0.01 s1

0 −4

0.02

−2 s2

0 −4

x 10

(a) PD controller only (Vm,1 = Vm,2 = VM,1 = VM,2 = 0). 0.00s to 0.15s

0.000s to 0.150s

100 20

0

10 s˙ 2

s˙ 1

−100 −200

0

−300 −400

−10 0

10 s1 0.09s to 0.15s

20

−0.1

5

0 s2 0.011s to 0.150s

0.1

4

s˙ 2

s˙ 1

2 0

0 −2

−5 −5

0 s1

5 −3

x 10

−4 −5

0

5 s2

10 −4

x 10

(b) 2-SMC+PD feedback. Figure 5.6: Stage 1. Phase plane plot of the sliding variables in the initial reaching phase (notice time interval) for two different controller configurations.

5.2 Controller parameter tuning

59

answer lies in the discretization; the feedforward linearization is sampled and then held for an inverter clock cycle and nothing special has been done to correct for the error which arises due to the delay2 . For a phase plane plot of the initial reaching phase, see figure 5.6(a). Next, the 2-SMC feedback will be designed. It is expected to keep the constraints s1 = 0, s2 = 0 with no steady-state error because of its high gain character. It is also expected that convergence takes place in finite time. The sliding gains Vm,1 , Vm,2 , VM,1 , VM,2 are found heuristically, starting with small values and increasing until sliding mode is realized. It is clear when this happens; the error drop to a very small value and stays there. Only gains satisfying VM > 3Vm are considered—a necessary condition which can be derived from the conditions for finite-time convergence of the twisting algorithm (3.6) for the present case of unity input gain, Γm = ΓM = 1 (see (4.17)). The simulation results with ks unchanged and Vm,1 = 2000, VM,1 = 10000, Vm,2 = 5000, VM,2 = 20000 are seen in figure 5.5(b) and 5.6(b). Compare with the previous results without SMC feedback. The change is clear; convergence to the sliding surfaces now takes place in finite time and the error shrunk by three orders of magnitude. The error is now dominated by high-frequency oscillations (chattering). Notice the similarity of the upper left of the phase plane plots 5.6(a) and (b): When far away from the sliding surface, the linear control determines system behavior rather than the discontinuous feedback, as it is expected.

5.2.2

Stage 2

The goal of stage 2 is to determine the observer gains, η1 and q2 . It is done using the same configuration as for stage 1 (refer to the block diagram 5.2). The estimated states are not used in the feedback yet. Rather, the “unrealistic” availability of actual motor states is used like above. The reason is that a poor observer configuration would lead to poor flux estimation which again would degrade the closed-loop performance or lead to instability. In such a case, it would be hard to conclude anything else than it does not work. When choosing to leave the closed-loop performance intact (by not using the observer estimates), it gets easier to interpret the results. The gains η1 and q2 cannot be chosen independently of each other. An initial value for η1 can be estimated using (4.33). For example, it can be assumed that the motor is standing or running slowly at startup (e.g., ω < 15 rad s−1 ) and that the flux error is limited to 10% of the nominal flux, i.e., φ¯rα < 0.05 V s. Inserting these quantities together with the motor 2 To verify this, a simulation with inverter period one order of magnitude smaller (Tinv /10) was run. It resulted in much smaller errors.

60

Design example and simulation

parameters in (4.33) gives a minimum value η1 = 2.4 to assure attractivity of the observer sliding surface. To give some room for parameters errors, an initial value of η1 = 5.0 is chosen. q2 must be chosen larger than zero and large enough to ascertain fast convergence of the observer flux error to zero. The treatment on observer design in section 4.4.6 did not provide an inequality or another means to judge the magnitude of this constant in advance, however. It is thus found by repeated simulation. This search problem is of acceptable complexity—since an initial value of η1 is known, the search is only one-dimsensional. The observer errors are shown for three of the tested sets of gains in figure 5.7. To interpret the magnitude of the error, refer to the actual motor states in the top of the figure. The lower plots of figure 5.7 show the current errors (right) and the flux errors (left). The gains are shown in the figure captions and are increasing gradually, from top to bottom. Of the three sets of observer gains, the first one with the lowest gains provides the best estimates. The last one with the highest gains provide a faster initial convergence at the cost of an higher ripple. The middle set has been chosen as a compromise, i.e. η1 = 10, q2 = 0.02.

5.2.3

Stage 3

In the transition from stage 2 to stage 3 the perfect feedback linearization is lost. The goal of stage 3 is to analyze the degradation in control performance when the linearization feedback is based on observed flux values and the approximation M˙ L = 0 instead of perfect information availability. Compare the resulting speed and flux errors in figure 5.5(c) with the errors in the previous stage, figure 5.5(b). When the initial transient and two spikes at 2.5 s and 3.5 s are ignored, the speed error increased roughly by 50% and the flux error remained within same limits. These errors are still very low, i.e., less than 4.5 × 10−4 s−1 and 1 × 10−4 V2 s2 , respectively. The spikes are coincident with the instants of maximal M˙ L at 2.5 s and 3.5 s (see figure 5.1). They have the magnitudes 1.2 × 10−2 s−1 and 1.4 × 10−3 s−1 , respectively. Since M˙ L has been approximated to zero, it is not surprising that these are critical points. The discontinuous feedback did not have authority enough to keep the system in sliding mode at these two point. It did not lead to instability though, and the error is low even including the spikes.

5.2.4

Stage 4

The goal of stage 4 is to configure the robust sliding mode differentiators to estimate the derivatives of the sliding variables s˙ 1 and s˙ 2 and test them in the loop. Differentiators are necessary because these derivatives can otherwise

5.2 Controller parameter tuning

61

Actual current 10

0.5

5

iα (A)

φα (Vs)

Actual flux 1 0 −0.5

0 −5

−10 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (a) Stage 2. Actual motor flux and current variables φrα and isα (the β-components are left out because they basically look the same). −1

0

2

Observer error, current 0.05 iα − ˜iα (A)

φα − φ˜α (Vs)

Observer error, flux 0.01 0.005 0

−0.005

0

−0.025

−0.05 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (b) Stage 2. Observer errors with observer gains η1 = 5.0, q2 = 0.01. Maximal flux error lower than 0.006 V s. Observer error, flux Observer error, current 0.01 0.05 0

2

iα − ˜iα (A)

φα − φ˜α (Vs)

−0.01

0.025

0.005 0

−0.005 −0.01

0.025 0

−0.025

−0.05 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (c) Stage 2. Observer errors with observer gains η1 = 10.0, q2 = 0.02 (like in table 5.3). Maximal flux error lower than 0.008 V s. 0

2

Observer error, current 0.125 iα − ˜iα (A)

φα − φ˜α (Vs)

Observer error, flux 0.025 0.013 0

0

−0.063

−0.013 −0.025

0.063

−0.125 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (d) Stage 2. Observer errors with observer gains η1 = 20.0, q2 = 0.04. Maximal flux error lower than 0.015 V s. 0

2

Figure 5.7: Stage 2. Three sets of gains are tested to tune the sliding mode observer. Of the three, (b) is finally selected because that observer is more accurate than (c), but probably less robust than (a).

62

Design example and simulation

only be calculated using a algebraic expressions involving the unknown load torque and uncertain motor parameters. When the differentiators are put into operation, the controller is exclusively fed with realistically available information (the focus point in stage 4 is the sliding variables and their derivatives). The gains are chosen heuristically such that the degradation in closed-loop performance is kept at a minimum in the transition from stage 3 to 4. Notice that too low gains will result in too slowly following estimates and will ruin the working of the 2-SMC algorithm. Too high gains will result in estimates with exaggerative chattering which will likewise ruin the performance of the controller. The interval of gains resulting in a working control system was found to be wide, however, and to span approximately one to two orders of magnitude. It was found that the differentiators work better at a higher update rate. It was thus decided to increase their (and their only) update rate to be five times faster the semiconductor switching frequency. The best compromise for the gains was found to be L1 = 50000, L2 = 500000. The resulting errors are seen in figure 5.5(d). In the transition from stage 3 to 4, the speed error increased by one order of magnitude and the flux error by two orders of magnitude. The spike at 2.5 s did not change in magnitude, however, and is still at 1.2 × 10−2 s−1 .

5.2.5

Result of stage 1–4

So far, the controller have had perfect knowledge of motor parameters, but not of the applied load torque. A final speed error not larger than 1.2 × 10−2 s−1 corresponding to 0.01% of the rated speed was achieved. This is a good result so far. Since the controller structure has been made with the possibility of unknown parameter variations in mind, it is expected that the performance will not degrade too much if e.g. the rotor resistance is increased. This case will be analyzed next.

5.2.6

Robustness analysis

The rotor resistance was increased by 75% compared to the nominal value known by the controller and observer. By simulation with the parameters found above (see table 5.3), the control system still turned out to be stable. An increase of the differentiator gains to L1 = 500000, L2 = 500000 led to better results: The speed error and flux error are plotted in figure 5.8 together with a phase plane view of the initial reaching phase. Compared to the ideal situation in stage 1 (see figure 5.6(b)), the reaching of a “small” region about the origin is not very smooth anymore and it is more clearly

5.2 Controller parameter tuning

63

seen that the system moves around in a limit cycle close to the origin rather than converging strictly to it. The observer performance is seriously degraded due to the increase in rotor resistance. The error grew significantly especially in the low-speed regime (t > 4 s). Due to poorly estimated rotor flux in this region, the closed-loop performance is degraded. This has led to larger speed errors.

Design example and simulation

Flux error s2 (V2 s2 )

Speed error s1 (s−1 )

64

0.2 0.1 0 −0.1 −0.2

0.02 0.01 0 −0.01

−0.02 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (a) Speed and flux errors. The speed error is lower than 0.1 s−1 except in the low-speed regime after t = 4 s where it is twice as large. 0

2

0.00s to 0.17s

0.000s to 0.150s

2000

400

1000 200

s˙ 2

s˙ 1

0 −1000

0

−2000 −3000 −10

0

10

−200 −0.5

20

s1 0.14s to 0.25s 100

0.5

0 s2

0.1

50

50

0

s˙ 2

s˙ 1

0 s2 0.003s to 0.150s

0

−50

−50 −100 −0.1

0 s1

−100 −0.1

0.1

(b) Phase plane plot of the initial reaching phase. In the disturbed case, the convergence look less like that of the twisting algorithm (compare with figure 5.6).

Observer error, flux

Observer error, current 0.3 iα − ˜iα (A)

φα − φ˜α (Vs)

0.2 0.1 0

−0.1 −0.2

0.15 0

−0.15

−0.3 4 6 8 10 0 2 4 6 8 10 Time t (s) Time t (s) (c) Observer errors. They are large especially in the low-speed regime after t = 4 s. 0

2

Figure 5.8: Stage 4, rotor resistance +75%, L1 = 500000.

Chapter 6

Conclusions In this work, a second-order sliding mode controller has been designed for an induction motor. The control problem was to track a reference trajectory for the shaft speed—and to do so even in the presence of significant unknown parameter variations and motor load transients. A complete solution to this problem using second-order sliding mode control has not been published before. The only existing paper suggesting a solution was not explicit in how certain critical signals were made available to the controller. The purpose of this work was to find out if a discontinuous feedback in the form of a second-order sliding mode controller is suitable to solve the given control problem. In particular, it is of interest if the well-known chattering problem of first-order sliding mode control is a problem for second-order sliding mode controllers as well. An “ultimate” solution of the control problem would be a major contribution to the industry where induction motors are common. A simulation model for the control system including motor, controller, and observer has been built up according to the theoretical considerations in chapter 4. The used simulation system was MATLAB Simulink 7.0 and the critical parts were written in the C programming language to allow for faster simulation. The theoretical considerations did not lead to usable rules for tuning of the controller parameters. Indeed, very little attention has been given to the choice of parameters in sliding mode algorithms by the sliding mode research community. The only existing convergence conditions are too conservative. An iterative approach for determining proper gains has been developed as part of this work and was presented in chapter 5. The work has lead to the following conclusions: • The high gain characteristic of sliding mode control makes it possible to achieve closed-loop properties which are not achievable with any

66

Conclusions

continuous controller: 1) Reduction of the output error to zero in finite time and 2) total rejection (at least theoretically) of a broad class of disturbances. The latter is achieved through immediate response to an infinitesimally small error with a finite control signal. A demonstration in the form of a comparison was provided: In figure 5.5(a) and (b) on page 57, a linear feedback controller was compared to a second-order sliding controller. The high gain characteristic of the discontinuous feedback was obvious, i.e., the error reached a region around zero in finite time and stayed there. • The first-order sliding mode observer has been shown to converge in the nominal case (exact knowledge of motor parameters) even in the presence of unknown load transients. The convergence of the observer was examined in section 5.2.2, see figure 5.7 on page 61. It has been used in the control loop successfully—at least in the nominal case. It remains to be determined what kind of observer error will be introduced in the case of unknown parameter variations. • The robust finite-time sliding mode differentiators introduced by Levant have been used in the control design. They were shown to be superior to linear differentiators both with respect to noise and to delay. See the comparison in figure 4.3 and 4.4 on the pages 45 and 45, respectively. These differentiators are a valuable tool for deploying sliding mode controllers with an order higher one. • The control system has been simulated under conditions taking the limited inverter frequency and the absence of flux and load torque measurements into account. The signals required by the controller were estimated using the mentioned observer and differentiators. Under these conditions, the system is stable and features a very small maximal error (see figure 5.5(d) on page 57). Chattering, i.e., high frequency oscillations in the outputs, is present. It remains to be determined if these oscillations can excite unmodeled eigenmodes of the motor and its mechanical load and cause damage. This can only be done by a more accurate model or by experiment. • A robustness test of the control system has been performed. The rotor resistance was increased by 75% compared to the nominal value known by the controller. Such an increase corresponds to a significant temperature rise of the rotor. The controller was still able to stabilize the error in presence of this disturbance. Following an adjustment of the controller parameters, the maximal speed error was found to be of small magnitude (less than 0.15% compared to the motor’s rated speed). See figure 5.8 on page 64. Due to the parameter disturbance, the flux observer was not anymore able to provide an satisfactory estimate. The convergence was especially bad at low rotor speeds, which

6.1 Future work

67

leads to higher speed errors.

6.1

Future work

While the work has demonstrated that second-order sliding mode control has potential for implementation of robust controllers, several issues remain to be investigated: • Stability: It has not been possible to prove the stability of the whole system. Before the controller safely can be used in critical areas, a theoretical proof of stability is a must. • Improvement of observer. A new class of second-order sliding mode observers known as step-by-step observers in the literature promises finite-time convergence of all observer states. If they are implementable on the present system, the flux estimation and thus overall control performance could be improved. • Optimal parameters: While the approach for determination of controller parameters has been shown to work, there is no guarantee that the found set of parameters is “optimal”. More work must be done in order to find the best compromise between robustness and chattering. • Operation in all regimes. The designed controller only works when the rotor flux is nonzero. The controller is thus unable to start up a demagnetized machine. It has been proposed to magnetize the motor initially using an open-loop controller, but it remains to provide a solution for this, e.g., how and when to make the changeover. • Variable flux: For simplicity, it was chosen to operate the motor with a constant rotor flux magnitude. This is a restriction for optimization of energy consumption. No structural change in the control system would be necessary to implement this, except for the addition of 1) a fluxcomputing algorithm and 2) additional terms to the sliding variables to accommodate for nonzero flux derivatives. • Experiment: It is of great importance to test whether the chattering will excite unmodeled eigenmodes of the motor and of the mechanical system. Since even detailed simulation models normally do not take high-frequency “parasitic” eigenmodes into account, the effect of chattering can only be evaluated experimentally. • Test of another second-order sliding algorithm than the used twisting algorithm: The so-called sub-optimal algorithm has an additional parameter for adjustment of the maximal derivative of the sliding vari-

68

Conclusions

able during the reaching phase. A comparison of the two algorithms could lead to new insight. • Use of a third-order sliding mode controller: This would allow for a continuous control signal while leaving the control task specification unchanged. This might be an aid in reducing chattering due to unmodeled system dynamics.

Appendices

Appendix A

Simulink model The graphical part of the MATLAB Simulink model is shown below. This is the model used in chapter 5 for tuning and analysis of the designed control system. It is thus the Simulink realization of stage 1–4 in figure 5.2, 5.3 and 5.4. To eliminate redundancy, all four stages are simulated using just one model. The difference between the stages is the signal flow. It is controlled using four sets of switches in the controller submodel (next page). Before starting a simulation, the switches must be set according to the actual stage, the blocks coded in C must be recompiled with the actual set of parameters and the parameters for the graphical Simulink blocks must be loaded using a M-file script.

voltout

x1 x2

ualp

x3 x4

ubeta

x5 ML

ML

ML'

Loadgen

Out3

Zero-Order Rate Transition Hold

motor

statesout

ML' wd

wd

wd'

wd'

wd''

wd''

Trajgen

Out4

slidingvarsout Out5

x2est x3est

Out6

Controller

observer

Main model

obsout

72

Simulink model

switches for lin fb 1 x1 11 x2est 12 x3est 5 x5

SW1

3 x3 4 x4

2 ubeta

SW2

3 Out3

controller

7 ML' 9 wd'

1 ualp

2 x2

6 ML

4 Out4

8 wd

5 Out5

SW4 10 wd''

algs1s2 6 Out6

don't touch (UP) S-Function

SW3

slidingdiffs -

algs11s21

Stage 1&2 3 4 SW1 U D D SW2 U D D SW3 U U D SW4 U U D

estexactdiffs exact s11 s21

checkdiffers

difffirstorder S-Function2

don't touch (DOWN)

algs1s2

difffirstorder S-Function3 obs s1 s2 ML unavail

Controller submodel Signal 1

Signal Builder1

x' = Ax+Bu y = Cx+Du State-Space

1 wd

refscale 3 wd''

Gain1

2 wd'

wdwddotwdddot To Workspace2

Speed reference generator submodel loadgenerator S-Function2

x' = Ax+Bu y = Cx+Du State-Space

1 ML

loadscale 2 ML'

Gain1

MLMLdot To Workspace2

Simulink model - load disturbance submodel

A.1 Source code for compiled blocks

A.1

73

Source code for compiled blocks

The source code for the four most important compiled blocks, and two files with parameter definitions, are included below: 1. motor.c (on this page): The continuous implementation of the induction motor state space model. (4.10) 2. controller.c (on page 75): The control law implementation including linearizing feedback and twisting algorithm. 3. observer.c (on page 77): The sliding mode observer (4.27) implemented using fixed time step Euler integration. 4. difffirstorder.c (on page 79): The Levant differantiator (4.37) implemented using fixed time step Euler integration. 5. myconf.h (on page 80): An excerpt of the C header file with motor and controller parameters, used by all blocks above. The full file (not included here) has a section for each set of parameters (PARMSET 0–22) and only one section is used at a time. 6. parmset0.m (on page 80): The remaining parameters in a MATLAB M-file. This is just PARMSET 0. A separate file has been made for each set of control system parameters. The files written in C conform to the standards of “MATLAB Simulink Level-2 C MEX S-Functions”. The MEX compiler included in MATLAB is used. Listing A.1: motor.c 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

#d e f i n e S FUNCTION NAME motor #d e f i n e S FUNCTION LEVEL 2 #include #include ” s i m s t r u c . h” #include ” myconf . h” /∗ F u n c t i o n : m d l I n i t i a l i z e S i z e s =============================================== ∗ I n i t i a l i z a t i o n . S e t number o f i n p u t s , o u t p u t s , s t a t e s , e t c ∗/ s t a t i c void m d l I n i t i a l i z e S i z e s ( S i m S t r u c t ∗S ) { int i ; ssSetNumSFcnParams ( S , if

5);

/∗ Number o f

expected

p a r a m e t e r s ∗/

( ssGetNumSFcnParams ( S ) != ssGetSFcnParamsCount ( S ) ) { /∗ R e t u r n i f number o f e x p e c t e d != number o f a c t u a l p a r a m e t e r s ∗/ s s S e t E r r o r S t a t u s ( S , ” ssGetNumSFcnParams ( S ) != ssGetSFcnParamsCount ( S ) ” ) ; return ;

} ssSetNumContStates ( S , ssSetNumDiscStates (S ,

5); 0);

i f ( ! s s S e t N u m I n p u t P o r t s ( S , 3 ) ) return ; f o r ( i =0; i