Chapter 4 Multi-rate Design for Wireless NCS
4.3 Multi-rate HNCS
4.3.3 The short-window median filter
Since the online measured RTT is not reliable, a median filter which is a nonlinear digital filtering technique often used to remove noise from signals and reserve the interrupt change (Astola and Neuvo, 2002) is adopted. Thus, the present multi-rate HNCS will avoid frequent switching which may lead to improper compensation of the delay time adopted in the Smith predictor. The short-window median filter applied to the measured RTT removes the short-term variation of the measured delay time and maintains a relatively constant delay time. To obtain the output of a median filter, the sample values are sorted and the median value is used as the filter output shown as follows (Burian and Kuosmanen, 2002):
[ ] [ ( ( 1)),..., ( 3), ( 2), ( 1), ( )]
y k Median x k N x k x k x k x k (4-3) where x(k) and y(k) are the K-th samples of the input and output sequences with a
window length N, respectively. As shown in Fig. 4.13, as the numbers of sorted data N becomes larger, the switching times are reduced. The length N = 5 was suitably chosen with an elbow rule and the filtering results are shown in Fig. 4.14. Results indicate that the processed time delay can be more suitably adopted as the switching index for the sampling time.
1 2 3 4 5 6 7 8 9 10 0
50 100 150 200 250
Numbers of the sorted data
Switching times
Fig. 4.13 The total switching times versus the window length
0 50 100 150 200 250
0 50 100 150 200 250
Time delay (ms)
Samples
w/o median f ilter with median f ilter
Fig. 4.14 The responses of estimation results applying the median filter (N=5)
Fig. 4.15 The control structure of NCS with the adaptive Smith predictor
+
4.3.4 The adaptive Smith Predictor
Considering the system dynamics of HNCS, the Smith predictor can be properly adopted if the delay time is constant, as shown in Fig. 4.15. Gsp(s) is the Smith predictor, Gc(s) is the controller, Gp(s) denotes the transfer function of the plant without the delay time, and Gˆ ( )p s is its nominal model (Peng et al., 2002; Sourdille and O’wyer, 2003). The forward transfer function of the system as shown in Fig. 4.19 is transfer function then becomes
1 stability and performance of the proposed HNCS.
4.4 Experimental results
The presently developed remote control system was applied to the Panasonic AC 400W servo motor. Both algorithms of the proposed adaptive Smith Predictor control and the switching sampling time with the on-line time-delay estimator were implemented on the TI DSP 2812 microcontroller (Lai et al., 2008). The position
control loop is located on the remote/client site and the coefficients of PI controller were determined as
K
p1 K
p2 K
p3 =0.0001, Ki1 0.00000001, Ki20.000000025,and Ki3 0.000000035.When the vacant sampling occurs, the previous data are held;
when two data messages arrive at the same sampling period, only the most recent data message is adopted and all the previous data are discarded. Different controllers were implemented and tested for the following three cases:
Case 1: the switching-time PI controller only,
Case 2: the classical Smith predictor with the switching-time PI, and Case 3: the adaptive Smith predictor with the switching-time PI.
Experimental results with commands of a square wave 30000/15000 pulse indicate that the closed-loop HNCS without the Smith predictor is still stable as the delay time varied significantly by switching the sampling period, as shown in Fig. 4.16. By applying the Smith predictor with a fixed time delay, the results indicate that the delay effect is well compensated, but its performance still becomes worse as the delay increases, as shown in Fig. 4.17. The present adaptive Smith predictor with the switching sampling period obtains the best system stability and control performance, as shown in Fig. 4.18.
Fig. 4.16 Experimental results with the switching sampling time.
0 100 200 300 400 500 600 700 800 900 1000
Fig. 4.17 Experimental results with a Smith predictor and the switching sampling time.
4.5 Summary
The goal is to achieve improved stability and performance for remote control systems considering the network congestion effect in an ad-hoc wireless network. In this chapter, based on the online time delay estimated by applying the short-window medium filter, a multi-rate HNCS combining the adaptive Smith predictor is proposed for HNCS in this chapter. Experimental results are summarized as follows:
(1) The on-line estimation of time delay has been applied successfully to HNCS.
By applying the short-window median filter, the smooth response of the estimation results was obtained and the unnecessary frequent change was thus avoided. Also, the immediate change of the different levels of delay was encountered in the present design.
(2) By applying the proposed switching sampling time, both congestion effect and stability of HNCS are improved in real applications.
Chapter 5
Model-free Perfect Delay Compensation Scheme
Most available networked control system (NCS) designs are developed with known system models and the delay time. However, such design approaches become impractical in real concerns due to the nature of significantly varied network- induced time delay, which in turn leads to a serious phase lag and jeopardizes the stability of NCS. To deal with the network- induced time delay, this study presents a novel NCS structure with the proposed perfect delay compensation (PDC) scheme. The PDC is a model-free approach and consists of only modified butterfly elements. Both analytical and simulation results in this chapter prove that the proposed model-free PDC scheme effectively compensates for the unknown and variable delay effects successfully even without information on the system model and the delay time. Furthermore, the proposed PDC is carried out using Ethernet tested from a 15 Km distance, and a well-tuned PI controller, obtained simply as a digital control for the AC servo motor, was directly networked to the NCS. Experimental results indicate that the significantly changed delay, measured as the round-time trip (RTT) in the range of 50 ms to 700 ms, is effectively handled to maintain a stable remote control system. Moreover, a notch filter precisely designed for vibration suppression, which is sensitive to its model of a flexible arm, was also directly applied at its remote node. Successful results indicate that as the time delay is significantly varied in real NCS applications, the proposed PDC renders satisfactory and desirable design results by considering all design procedures, implementation, and control performances.
5.1 Introduction
The challenges of NCS have attracted the attention of researchers in recent studies on time delay and packet loss. Lian et al. (2002) have identified several key components of the time delay to determine suitable sampling periods for the NCS.
Nilsson (1998) has conducted an extensive work for the network-delay model with both forward and feedback delays formulated as a Markov chain process (Shi and Yu,
2009). The robust Smith predictor with the TCP model has also been implemented with the online measured RTT delay (Chen et al., 2007). Considering system modeling, robust methods and state feedback design are achieved generally assuming that the varied delay is relatively smaller than its system sampling time (Gao and Chen, 2008;
Tang et al., 2008). Thus, those robust design results are merely suitable for NCS with a very small time delay, such as in the Intranet only within a limited range. The switched system to study asymptotical stability for a large but known time-delay model was also investigated (Xie et al, 2008; Li et al., 2009). A packet-based control framework has also been proposed with a sequence of control signals to be sent to compensate for the time delay with a known communication constraints (Yang et al., 2007; Zhao et al, 2009). In real remote control systems implemented in the Internet, the time delay, which usually varies depending on the number of user nodes and communication data loads, is relatively larger compared with the sampling time. Tipsuwan and Chow (2004) have proposed the use of a gain scheduler middleware (GSM) to adjust the controller gains externally at the controller output in order to maintain control performance and stabilize the system with respect to the current network traffic conditions with the measured RTT in real time. An adaptive Smith predictor was proposed to handle the problem on varying-time delays in accordance with an online estimated delay and an accurate system model (Lai and Hsu, 2010). A time-delayed control system with an unknown and fixed delay time based on network disturbance as the communication disturbance observer (CDOB) has also been proposed (Natori and Ohnishi, 2008).
Recently, the scattering transformation with known system model and controller has also been proposed to effectively compensate for unknown constant delays (Matiakis et al., 2009). Under the NCS structure with the scattering transformation, its closed-loop transfer function is equivalent to its original control design with a pure time delay item without considering the time delay. However, the design of that operator is not straightforward and the varied time-delay will not be compensated properly within the control loop in NCS.
In this chapter, the perfect delay compensation (PDC) with the butterfly elements is proposed to deal with unknown and varied time delay without considering the system
servo motor from a 15 Km distance through the Ethernet, render satisfactory control performance to further indicate that the proposed PDC is feasible and reliable With the proposed PDC element in NCS, the remote control system can be realized directly from the digital control design. An example for suppressing vibration of a motor-driven flexible arm through the Internet has been successfully provided to prove that the precisely-designed control block can be directly applied to its NCS realization.
5.2 Background
As shown in Fig. 5.1, the transfer function of the closed-loop system without network-induced delay (t1 and t2) is obtained as follows:
o
( ) ( )
( ) 1 ( ) ( )
c p
c p
G s G s G s G s G s
(5-1) Moreover, the NCS communication network can be modeled as the time delays t1 and
t
2 on the forward direction for the controller and on the feedback direction for the sensor, respectively, and Gp(s) denotes the transfer function of the plant without the delay time, and Gc(s) is the controller, as shown in Fig. 5.1.Fig. 5.1 The block diagram of the general NCS
The network-induced delays are different depending on the hardware and software used in the network. Most control designs for the time-delay NCS have been proposed with a known system model and a constant network-induced time delay. Traditionally, the known- delayed process can be effectively handled by applying the Smith predictor and eliminating the time-delay effect from its closed control loop. Furthermore, some methods have been proposed in real applications mainly in the adaptive Smith predictor
(Lai and Hsu, 2010), the communication disturbance observer (CDOB) (Natori and Ohnishi, 2008), and scattering transformation (Matiakis et al., 2009). Basically, all these methods require a system model or an online estimated time delay.
5.2.1 Adaptive Smith predictor
Compared with the Smith predictor with a fixed time delay, the adaptive Smith predictor is proposed with the online estimated time delay (tm) to achieve an improved performance of NCS in real applications (Lai and Hsu, 2010). As shown in Fig. 5.2, its equivalent transfer function of the general NCS with an adaptive Smith predictor can be expressed by
Fig. 5.2 The NCS with the adaptive Smith predictor (Lai and Hsu, 2010)
When the model Gˆp( )s is equal to the real system Gp(s) and tm = t1 + t2, the significantly and it requires on-line measurement for the adaptive Smith predictor. In addition, because parameter uncertainties exist in both the system model and the time
delay, a robust control design was preferred for the NCS with the adaptive Smith predictor to further improve performance (Natori and Ohnishi, 2008). However, given that the on-line measurement for the time delay consumes the bandwidth of network transmission and the system model is also varied in practice, Equation (5-3) may not be held and its performance is thus degraded compared with the original design without considering the network implementation.
5.2.2 Communication disturbance observer (CDOB)
A time-delay compensation method based on the communication disturbance observer (CDOB) has been proposed by Natori et al. (2008) to estimate and compensate for the delay effect. CDOB obtains desirable closed-loop system performance with a pure delay term as shown in Fig. 3. Based on the known the The state space equations for the NCS are then obtained as follows
( ) ( ) ( ) ( ) If the disturbance item is accurately estimated, the effect of the delay in NCS can be properly eliminated as shown in Fig. 5.3. Thus, with a general DOB algorithm (Natori and Ohnishi, 2008), the equivalent transfer function of NCS with the CDOB is feedback time-varying delay t2 as shown in Fig. 5.1.
Fig. 5.3 The block diagram of CDOB (Natori and Ohnishi, 2008)
5.2.3 Scattering transformation
The scattering transformation is recently proposed to deal with an unknown constant time delay (Matiakis et al., 2009), as shown in Fig. 5.4. The transfer function of the closed loop system is obtained as follows
1
If K(s) = 1 holds with a suitable b, the closed loop transfer function of NCS is reduced to Smith predictor and CDOB, the scattering transformation does not need the time-delay model. However, it is difficult to make K(s) equal to one for all s. If K(s)1, performance of the scattering transformation is thus degraded.
All the aforementioned methods require an accurate system model; some of them require that the time delay is known and constant. These requirements are impractical since in real NCS, the system model is uncertain and the time delay is unknown and significantly varied. Thus it is desirable to design a network time-delay compensation
Fig. 5.4 NCS with scattering transformation (Matiakis et al., 2009)
5.3 Perfect delay compensation
Our survey of previous methods has shown that network time-delay compensation should be designed without including the time-delay model, since network time delay significantly varies due to all the varied network loads, scheduling, number of nodes, and protocols. As the time delay induced during the transmission over the communication network, it becomes more unpredictable. Also, the data dropout becomes more irregular and the NCS control design based on a nominal model with a known delay time also becomes invalid. In this study, the PDC with the modified butterfly elements is proposed to effectively deal with network-induced delays requiring neither the delay time model nor the plant model.
5.3.1 The delay compensation operator
The architecture of the scattering transformation uses the passivity formalism and concepts from network theory to construct a passive block with the interconnection element as shown in Fig. 5.4.
Fig. 5.5 The scattering transformation (Matiakis et al., 2009)
Based on the condition of the delay compensation operator guaranteed passivity of the network block, which is independent of networks, the scattering transformation
shown in Fig. 5.5 are given as The transfer function from input Ur to output Vr is obtained as
Positive realness is an equivalent notion to passivity for linear time-invariant (LTI) systems in the frequency domain. In the case of b > 0, a transfer function Gr(s)is positive real if and only if the H norm of the scattering operator is less than or equal to one (Matiakis et al., 2009). Given that the passivity condition is satisfied, the input/output behavior is considered as a passive system. With a suitably designed b and
K(s) = 1, the NCS becomes a desirable closed-loop control system with a pure delay
term. Note that b is not easily obtained, and the system model for the plant is required in this structure. As the delay time varies in a real application, the K(s) = 1 does not hold and Eq. (5-9) of the scattering transformation could not be valid in practice.5.3.2 Modified butterfly element
According to the basic concept of scattering transformation, the modified butterfly element is proposed in the present PDC design for delay compensation. The butterfly elements are the basic blocks in the FFT/IFFT processor, as shown in Fig. 5.6(a), which are used to save computations with inputs (X0, X1) and outputs (Y0, Y1) as follows:
0 0 1 ; 1 0 1
Y
X
X Y
X
X
(5-12)
(b) (c)
Fig. 5.6 (a) Butterfly element, (b) modified anti-butterfly element, and (c) modified butterfly element
A novel design for PDC is proposed here to modify the butterfly element by reversing two interconnections, as shown in Figs. 5.6 (b) and (c). The modified butterfly element is applied to the passive communication network as follows:
( ) ( ) (s) ; (s) ( ) (s)
p r p r p p
U s U s Y Y U s Y (5-13) Thus, the transfer function from input Ur to output Yr becomes
( ) (s) ( ) 1 ( )
( ) , where ( )
( ) ( ) (s) ( ) 1 ( )
p p p p
r p
r p p p p
U s Y G s Y s
Y s G s
U s U s Y G s U s
(5-14)
The formulation of the modified butterfly element is similar to the scattering transformation as shown in Eq. (5-11). However, the modified butterfly element can be directly obtained with much easier design and realization.
To simplify the derivation of PDC, the control structure, as shown in the right of Fig. 5.7, is first located in the client node. The modified butterfly and anti-butterfly elements are implemented in both sides of the network. Note that both butterfly elements are implemented without knowing any delay information of the network communication.
Fig. 5.7 The control structure with PDC in the proposed NCS
Similarly, the output transformation equations of modified butterfly element can be obtained as follows:
( ) ( ) (s) ; (s) ( ) (s)
p r p r p p
U s U s Y Y U s Y (5-15) The transfer function from input Ur to output Yr is given as follows:
( ) (s) ( ) ( ) 1
To analyze the effects of the proposed structure, the signal flow is characterized by considering the relationship between the modified butterfly element and the anti-butterfly element. Figure 5.7 shows the open-loop transfer function between the input Uc and the output Yc, which are on the left of the element and can be expressed
Moreover, the forward loop of the NCS from R to Yc is expressed as follows:
1 2 Combining Eq. (5-17) with Eq. (5-18) yields:
( ) ( ) (s) close-loop system of the present NCS with the PDC structure can be directly obtained as follows: Equation (5-21) shows that the complicated NCS with delay time now becomes two
simple parts: (a) the desirable transfer function of the system Go(s) without the delay time and (b) the pure time delay t1, as in Eq. (5-21). There is no time-delay effect in the closed loop of the NCS, and the stability obtained without considering the network in
G
o(s) can be thus properly maintained in the implementation with NCS for remote control systems.Fig. 5.8 The control structure with PDC in the general NCS
5.3.3 The general element of PDC in NCS
Without losing generality, the controller Gc(s) in the client node with PDC is extended to a general NCS by implementing the controller in the remote node, as shown in Fig. 5.8. The output equations of the modified butterfly element can also be expressed as
( ) ( ) ( ) (s) ; (s) ( ) ( ) (s)
p r c p r c p p
U s U s G s Y Y G s U s Y (5-22) The transfer function from input Ur to output Yr becomes
( ) ( ) (s) ( ) ( )
Also, the transfer function of the open-loop system can be expressed by
1 2
Thus, the transfer function of the close-loop NCS can be obtained by:
1 Equation (5-26) also shows that the equivalent system presents the same desirable closed-loop transfer function Go
(s) with the pure forward delay time t
1. Note that the controller Gc(s) is originally designed for the system without the network
implementation. The feedback time delay t2 will not affect the output response of the present NCS with the PDC structure. For example, considering the worst case if the feedback loop is disconnected and t2 is infinite and the forward path is still in normal operation with the delay t1, the transfer function of the close-loop system of the network only possess the function of sending the forward command message.5.4 Simulation
In this section, an example is considered to illustrate the effectiveness of the proposed PDC. By applying equal forward and feedback time delays t1 = t2 = (RTT/2), both conditions of constant and varied time delays were tested with the plant
( ) 73 (s +10.15 s)2
Gp s as provided by (Matiakis et al., 2009), and the lead-lag controller is obtained as G sc( ) 1.3981(s+ 9.9114) (s+ 9.1558) with b = 0.6203. In the constant time t1 = t2 = 200 ms as shown in Fig. 5.9 (a), simulation results indicate that NCS performance had a slower response and less overshoot by applying the scattering transformation shown in Fig. 5.9 (b). The original design leads to 147 ms rise time and zero steady-state error. As summarized in Table 5.1, due to the fact that K(s) is not equal to unit through the whole frequency range. Its 254.8 ms rise time becomes
slower with a 0.013 steady-state error. On the other hand, the NCS with the PDC presents the same system performance (rise time = 147 ms, overshoot = 19.2 %, and steady-state error = 0) without the network delay effect and only with a pure delay 200
ms. In the time-varying case as shown Fig. 5.10 (a), an online measured time delay
RTT in real network was used. The results also showed that the system response became unstable using scattering transformation as shown Fig. 5.10 (b). In addition, the PDC obtained better performance as shown Fig. 5.10 (c). Note that the PDC with varied time delay maintained its original performance with a pure delay.0 0.5 1 1.5 2 2.5 3
Table 5.1 Comparison of control performance under different methods
Methods Rise time
transformation 254.8 5.4 0.013
PDC 147.0 19.2 0