Professional Documents
Culture Documents
For autonomous helicopter flight, it is common to separate the flight control problem
into an innerloop that controls attitude and an outerloop that controls the trajectory
of the helicopter. The outerloop generates attitude commands that orient the main rotor forces appropriately to generate required translational accelerations. Recent work
in Neural Network based adaptive flight control may be applied to control a helicopter
where the reference commands include position, velocity, attitude and angular rate. The
outerloop is used to correct the commanded attitude in order to follow position and velocity commands. This however generally requires a model of the translational dynamics
which has some model error. This paper introduces adaptation in the outerloop using
Pseudo Control Hedging in a way that prevents adaptation to the innerloop dynamics.
Additionally, hedging is used in the innerloop to avoid incorrect adaptation while at control limits. Such an approach along with correct placement of the combined poles of
the linearized system mitigates inner/outer loop interaction problems and allows one to
increase bandwidth in the outerloop, thus, improving tracking performance further.
Nomenclature
NN
p
P CH
q
V, W
v
x
Subscripts
ad
c
d
des
f
h
m
ol
p
r
rm
adaptive signal
commanded
derivative
desired
force
hedge
moment
outerloop correction
proportional
robustifying term
reference model
Introduction
Helicopters are versatile machines that can perform aggressive maneuvers. This is evident from the
wide range of acrobatic maneuvers executed by expert pilots. Helicopters have a distinct advantage over
fixed-wing aircraft especially in an urban environment,
where hover capability is required. There is increased
interest in the deployment of autonomous helicopters
for military and civilian applications. Some of these
include, reconnaissance of an urban area and search
and rescue missions. Autonomous helicopters must
have the capability of planning routes (perhaps optimal in some sense) and executing them. In order
to be truly useful, these routes would include high
speed dashes, tight turns around buildings, avoiding
dynamic obstacles and other aggressive maneuvers. In
planning1 these routes however, the tracking capability of the flight control system is a limiting factor as
current control systems are still unable to leverage the
full-flight-envelope of small helicopters.
Although stabilization and autonomous flight2 have
been achieved, their performance is modest compared
to a human pilot. This is largely due to assumptions made during control design. One such example
is the assumption of time-scale separation3 between
the innerloop attitude control and outerloop trajectory
control systems. Other problems arise when using a
model based robust control approach4 where the model
used is no longer valid during aggressive maneuvers,
effectively reducing the bandwidth of the system. Researchers have tackled this by introducing adaptation
in the innerloop.3 This adaptation however only addresses tracking performance of the attitude dynamics.
Another significant problem in controlling a small1 of 11
helicopter is the presence of the control rotor or stabilizer bar. At higher bandwidths, the innerloop begins to interact with the control rotor dynamics whose
states are not normally directly measurable. One approach has been to treat the problem in an output
feedback5 setting that allows high bandwidth control
of the attitude dynamics. Even if the innerloop provides high bandwidth attitude tracking performance,
an outerloop that can take advantage of this performance is necessary.
This paper is concerned with the development of a
combined inner-outer loop adaptive architecture. Neural Network (NN) based direct adaptive control has recently emerged as an enabling technology for practical
flight control systems. This technology has been successfully applied6 to the recent USAF Reconfigurable
Control for Tailless Fighter Aircraft (RESTORE) culminating in a successful flight demonstration7 of the
adaptive controller on the X-36. A combined innerouter loop architecture was also applied for guidance
and control of the X-338 and evaluated successfully in
simulation for various failure cases.
In synthesizing a controller (Figure 1), the conventional conceptual separation between inner and outer
loops is made. The inner loop controls the moments
acting on the aircraft by changing the longitudinal
stick, lateral stick and pedal inputs. The outer loop
controls the forces acting on the aircraft by varying
the magnitude of the rotor thrust using the collective
input. The thrust vector is oriented in the desired direction by commanding changes to the attitude of the
helicopter using the inner-loop.
The attitude and translational dynamics are inputstate feedback linearized separately using dynamic inversion and linear controllers designed for their linearized dynamics. The effect of parametric uncertainty
arising due to approximate inversion is minimized using an adaptive element. The adaptive element could
be something as simple as an integrator or a neural
network. In this paper, a nonlinearly parameterized
neural network will be used to provide on-line adaptation. In introducing an adaptive system however, a
new problem arises by way of unwanted adaptation to
plant input characteristics such as actuator dynamics.
For example, the innerloop sees actuator limits, rate
saturation and associated dynamics. In order to alleviate this problem, Pseudo-Control-Hedging8, 9 (PCH),
is used to modify the innerloop reference model dynamics in a way that allows continued adaption in the
presence of these system characteristics. This same
technique, PCH, is used to hedge the outerloop to
prevent adaptation to innerloop dynamics.
In this paper, the combined inner-outer loop architecture is first described followed by a description of
the Neural Network and selection of linear compensator gains. The controller is then applied to the
trajectory and attitude control of an unmanned he-
OuterLoop
Hedge
ah
InnerLoop
Hedge
ah
qc , w c
pc , vc
Outer
Loop
aad
qdes , w des
x
Adaptive
Element
Inner
Loop
dm
a ad
Plant
df
x,a , a
licopter. Practical discussions on the choice of parameters and reference model dynamics are provided.
Finally, simulation and flight test results are presented.
Controller Development
Consider an aerospace vehicle modeled as a nonlinear system of the form
p
v
q
=
=
=
=
v
a(p, v, q, , f , m )
q(q,
)
(p, v, q, , f , m )
(1)
(2)
(3)
(4)
a
a
(p, v, q, , qdes , m , fdes )
= des =
(5)
des
(p, v, q, , mdes , f )
where, is commonly referred to as the pseudocontrol. a
,
represent the best available approximation of a() and (). Additionally, fdes , mdes , qdes
are the control inputs and attitude that is expected
to achieve . This form assumes that translational
dynamics is coupled strongly with attitude. Hence,
qdes will be used to make corrections to the nominal
commanded attitude qc in order to achieve the desired
translational accelerations. Choosing a
and
such
2 of 11
American Institute of Aeronautics and Astronautics
that they are invertible, the desired control and attitude may be written as
fdes
=a
1 (p, v, q, , ades , m )
qdes
mdes =
1 (p, v, q, , f , des )
(6)
aa
PCH method is: move the reference model in the opposite direction (hedge) by an estimate of the amount
the plant did not move due to system characteristics
the control designer does not want the adaptive element to see.9 This will prevent the characteristic from
appearing in the model tracking error dynamics to be
developed in the sequel.
The reference model dynamics may be redesigned to
include hedging as follows
v rm
rm
acrm
crm
= des +
(8)
(9)
(11)
(12)
where ah and h are the difference between commanded pseudo-control and achieved pseudo-control.
ah = a
(x, qdes , fdes , m ) a
(x, f , m )
= ades a
(x, f , m )
h =
(x, f , mdes )
(x, f , m )
= des
(x, f , m )
The pseudo-controls ades and des may now be designed to satisfy closed-loop performance and stability
characteristics. Choosing,
ades = acrm + apd a
ad
des = crm + pd
ad
= acrm ah
= crm h
prm p
vrm v
e,
(14)
rm , q)
Q(q
rm
(10)
(13)
: R4 R4 7 R3 , is a function9 which,
where, Q
given two quaternions results in an error angle vector with three components. If error angles angles are
is given by
kept small, an expression for Q
q) = 2sgn(q1 p1 + q2 p2 + q3 p3 + q4 p4 )
Q(p,
q1 p2 + q2 p1 + q3 p4 q4 p3
q1 p3 q2 p4 + q3 p1 + q4 p2
(15)
q1 p4 + q2 p3 q3 p2 + q4 p1
The output of the PD compensators may be written
as
apd
Rp Rd 0
0
=
e
(16)
pd
0
0 Kp Kd
where, Rp , Rd R33 , Kp , Kd R33 are diagonal and positive definite matrices. The tracking error dynamics may be found by directly differentiating
3 of 11
American Institute of Aeronautics and Astronautics
Eq. (14).
vrm v
v rm v
e =
rm
rm
(17)
where, ad
is an ideal post adaptation output of the
adaptive element and tracking error is zero, i.e., q =
qrm and = rm . If adaptation is capable of exactly
cancelling for model error. Then Eq. (22) may be written as
Considering e 2 ,
rm = (p, v, qrm , rm , f , m )
mdes = 1 (p, v, qrm , rm , f , crm )
e 2 = v rm v
= acrm ah a(x, )
= acrm ades + a
(x, ) a(x, )
= acrm apd acrm + a
ad + a
(x, ) a(x, )
= apd (a(x, ) a
(x, ) a
ad )
Eq. (23) now becomes the non-adaptive design synthesis problem for selecting crm . In this paper, the
reference model dynamics are chosen as
c , qrm ) + Kd (c rm )
crm = Kp Q(q
= apd (a (x, ) a
ad )
(18)
e 4 may be found similarly. Then,
a
a(x, ) a
(x, )
(x, ) ,
=
(x, )
(x, )
(19)
(20)
where,
0
0
0
I
(21)
Now, ad remains to be designed in order to cancel
the effect of . In order to cancel using an adaptive
element, it should have the functional form ad (x, ).
0
Rp
A=
0
0
I
Rd
0
0
0
0
0
Kp
0
0
I
0
,B =
0
I
Kd
0
rm = ad
+
(p, v, qrm , rm , f , m )
mdes =
1 (p, v, qrm , rm , f , des )
=
1 (p, v, qrm , rm , f , crm ad
)
(23)
(24)
where Kp and Kd are the same as the PD compensator gains and will achieve the desirable responses for
permissible plant and actuator dynamics. If actuators
and adaptation are perfect, the closed loop attitude system will exhibit linear dynamics. A similar argument
may be made for the translational dynamics reference
model.
Adaptive Element
bw
bv
n ad1
xin1
s1
xinn1
Fig. 2
n ad 2
n ad n
s n2
n2
X
wjk j (zj )
(25)
j=1
n1
X
vij xini )
(26)
i=1
(22)
(z) =
4 of 11
American Institute of Aeronautics and Astronautics
1
1 + eaz
(27)
where, a is the so called activation potential. For convenience, define the following weight matrices
v,1 v,n2
v1,1 v1,n2
V = .
(28)
..
..
..
.
.
vn1 ,1
w,1
w1,1
W = .
..
Z=
wn2 ,1
V
0
0
W
vn1 ,n2
..
.
w,n3
w1,n3
..
.
wn2 ,n3
(29)
(30)
ad = W (V x
)
(33)
= sup W T (V T x
) (
x)
(34)
x
D
The weights, (V , W ) may be viewed as optimal values of (V, W ) in the sense that they minimize on D.
These values are not necessarily unique. The universal approximation property thus implies that if the NN
inputs xin are chosen to reflect the functional dependency of (), then may be made arbitrarily small
given a sufficient number of hidden layer neurons, n2 .
Associated with the tracking error dynamics given
in Eq. (20), is the Lyapunov function.
AT P + P A + Q = 0
(35)
Choosing9
Q1
Q=
0
0
Q2
1
1
2
n
4 2 + bw
Q2 =
Rd Rp2
0
Kd Kp2
0
0
>0
Rd Rp
0
>0
Kd Kp
(37)
(38)
1
P1 0
P =
(39)
0 P2 14 n2 + b2w
where,
Rp2 + 12 Rp Rd2
P1 =
1
Rp Rd
22 1
Kp + 2 Kp Kd2
P2 =
1
2 Kp Kd
(31)
where, bv > 0, is an input bias that allows for thresholds v to be included in the weight matrix V . The
input-output map of the SHL network may now be
written in concise form as
T
Q1 =
where bw > 0 allows for the threshold, w , to be included in the weight matrix W . Also, z = V T x
, where,
x
T = bv xTin
(32)
where,
1
2 Rp Rd
Rp
1
2 Kp Kd
Kp
>0
(40)
>0
(41)
(42)
(43)
ad =
ad
!
f
f f1
(44)
=
f f1
I < 1
=
For a SISO system, condition (44) is equivalent to
(36)
5 of 11
American Institute of Aeronautics and Astronautics
(45)
and,
Reference Model
(46)
r = (e P B)
ad = ad + r
(47)
(48)
ad = W T (V T x
)
r = Kr (kZkF + Z)r
(49)
(50)
= ( 0 V T x
W
)rT + kekW W
(51)
T T 0
V = V x
(r W ) + kekV
(52)
with, W , V > 0 and > 0, guarantees that reference
model tracking error (e) and NN weights (W, V ) are
uniformly ultimately bounded.
Proof. See appendix.
Corollary 1. All plant states [p, v, q, ] are uniformly
ultimately bounded.
Proof. If the ultimate boundedness e, W, V from Theorem 1 is taken together with Assumption 3, the
uniform ultimate boundedness of the plant states is immediate following the definition of the reference model
tracking error in Eq. (14).
Application to an Autonomous
Helicopter
(54)
has been
where the functional dependence of Q
dropped for clarity and is the same as in Eq. (54).
The function sat is the saturation function and vlim ,
lim are the translational and angular rate limits respectively.
Approximate Model
p
u
lat
lat
r
w
ped
ped
| {z } | {z }
des
trim
or,
T
lon lat ped .
(56)
where, A1 and A2 represent the attitude and translational dynamics respectively. B represents the angular velocity of the body with respect to the earth
expressed in the body frame. vB , is the body velocity vector with respect to the earth expressed in the
body frame. mtrim is the trim control vector that is
consistent with the linear model.
Choosing the control matrix B such that it is invertible, the moment controls may be evaluated as
mdes = B 1 (des A1 B A2 vB ) + mtrim
(57)
0
ades = 0 (colldes colltrim ) + Lbv g
(58)
Zcoll
6 of 11
American Institute of Aeronautics and Astronautics
f sf
Df
ades2
y B initial
y B final
g B3
z B final
z B initial
Fig. 3
x
= ades = x
c + Kd (x c x)
+ Kp (xc x)
+ Kp (g )
= des = g + Kd (g )
(59)
fsf
+ colltrim
Zcoll
(60)
(s) =
(s)
Kp
g (s) = 2
g (s)
g (s)
s + Kd s + Kp
Choice of Gains Rp , Rd , Kp , Kd
(65)
If the outerloop linearizing transformation used to arrive at Eq. (63) has the form x
= f , where f = g
and g is gravity, it may be written as,
s2 x(s) = f (s)
(66)
10
(64)
(62)
where, q(.) is a function that expresses an euler angles based orientation as a quaternion. The overall
detailed controller architecture is shown in Figure 4.
(63)
x
des
ades
=
f
f
(67)
1
[
xc + Rd (x c x)
+ Rp (xc x)]
f
(68)
Kp s2 xc + Rd s(xc x) + Rp (xc x)
2
s x(s) =
s2 + Kd s + Kp
(69)
Rearranging the above equation results in the following transfer function
When implementing the combined adaptive innerouterloop controller for position and attitude control,
Kp s2 + Kp Rd s + Kp Rp
x(s)
= 4
xc (s)
s + Kd s3 + Kp s2 + Kp Rd s + Kp Rp
7 of 11
American Institute of Aeronautics and Astronautics
(70)
ah
Outer-Loop
Hedge
ah
p , v , q, w
Inner-Loop
Hedge
qc , w c
xc , vc
Outer Loop
Reference Model
acrm
Inner Loop
Reference Model
Outer Loop
Approx
Inversion
+
Outer-Loop
PD
Inner-Loop
PD
- aad
d colldes
Inner Loop
Plant
Approx
Inversion [d lon , d lat , d ped ]des
qdes , w des
p , v , q, w
v, p, vrm , prm
p , v , q, w
a crm
p , v , q, w
p , v , q, w
- a ad
q, w , qrm , w rm
OUTER LOOP
INNER LOOP
NN
p, v, q, w , a , a
Fig. 4
Detailed inner and outer loop controller architecture for an autonomous helicopter
(i2
+ 4o o i i +
pc =
o2 )s2
+ (2o o i2 + 2o2 i i )s + o2 i2
o2 i2
+ 4o o i i + o2
o i (o i + o i )
Rd = 2 2
i + 4o o i i + o2
Rp =
i2
Kp = i2 + 4o o i i + o2
Kd = 2i i + 2o o
cos(t)
sin(t) ,
h
c = tf
(71)
where, the subscripts i, o, represent the inner and outerloop values respectively.
Comparing the coefficients of the poles of Eq. (70)
and Eq. (71) allows the gains to be expressed as a
function of the desired pole locations
V sin(t)
vc = V cos(t)
0
(73)
(72)
Numerical Results
The proposed guidance and control architecture was
applied to a nonlinear simulation of a Yamaha R - Max
helicopter, using a simulation tool called ESim. The
R - Max helicopter weighs about 128 lbs (empty) and
has a main rotor radius of 5.05 f t. Nominal rotor speed
is 700 revolutions per minute. Its practical payload
capability is about 66 lbs with a flight endurance of
greater than 60 minutes. It is also equipped with a
control rotor.
The helicopter was commanded to perform a circular maneuver in the North-East plane with constant
altitude. Constant speed was commanded around
8 of 11
American Institute of Aeronautics and Astronautics
50
30
command
response
command
response
40
20
30
20
10
North /ft
North /ft
10
10
10
20
30
20
40
50
20
40
60
80
100
120
30
140
20
40
60
time /s
time /s
Fig. 5
only
North /ft
20
20
20
100
50
0
East /ft
50
40
100
100
50
0
East /ft
50
100
40
40
command
response
command
response
20
20
North /ft
North /ft
120
40
command
response
20
40
100
40
40
80
20
100
50
0
East /ft
50
40
100
Fig. 6 x-y plane trajectory plot of helicopter position with innerloop adaptation only
100
50
0
East /ft
50
100
Fig. 8 x-y plane trajectory plot of helicopter position with both inner and outerloop adaptation
Simulation
100
50
/deg
Maneuvers with the above parameters were simulated with and without outerloop adaptation. Innerloop adaptation was enabled in all cases. Figure 5
shows the position tracking in the x-axis of the local
frame (North). Figure 6 illustrates the position plot
of the helicopter in the x-y plane during the first 30
seconds of simulation and the latter 80-100 seconds
of simulation at which point the innerloop may be
assumed to be fully trained. Tracking without adaptation in the outerloop is quite poor due to the simplistic
point-mass model used for outerloop inversion.
Figure 7 and Figure 8 shows similar plots but with
adaptation in both the inner and outer loops. The network is able to compensate for approximations in both
the innerloop dynamics and the outerloop dynamics.
50
100
150
200
20
40
60
time /s
80
100
120
9 of 11
American Institute of Aeronautics and Astronautics
Fig. 10
loops can now use the same adaptive element to cancel model errors. Additionally PCH was also used to
prevent unwanted adaptation to actuator limits and
dynamics in the innerloop. Using this architecture,
a consolidated reference command xc that includes
position, velocity, attitude and angular rate may be
provided to the control system. This reference signal
is automatically augmented with any attitude corrections required to follow a trajectory. Using PCH along
with expressions for the poles of the combined innerouter loop error dynamics alleviates bandwidth separation requirements. This allows increased bandwidth
in the outerloop leading to better overall tracking performance.
280
North /ft
raw command
reference model
response
260
240
= ad
= W T (V T x
)
220
200
180
160
1530
1540
1550
1560
Time /s
1570
1580
1590
e = Ae + B W T (V T x
) W T (V T x
) + + r
(74)
For clarity, hereafter, = (V T x
), = (V T x
) and
0 = 0 (V T x
). Using a Taylor-series expansion for
with respect to W and V , Eq. (74) may be rewritten
as
h
i
T ( 0 V T x
e = Ae + B W
) + W T 0 V T x
+ w + r
, W W , V , V V ,
where, after defining, W
i
h
T 0 V T x
+W
w = W T + 0 V T x
Flight Test
w +n2 )+2Z
a(bw +n2 )(1+bw +n2 )kZkk
xk
kwk +2Z(b
where Z = Z Z , a
is the maximum activation potential of Eq. (27). A bound on the norm of the NN
inputs x
may be expressed as
Conclusions
This paper presents results where the inner loop attitude control and outer loop trajectory control loops
have been combined using Pseudo Control Hedging
(PCH) in a way that does not affect adaptation. Both
k
x| bv + x
c + Z + kek + (1 + bw + n2 )kZk
Hence, the upper bound on the norm of w may finally
be expressed as
+ c2 kekkZk
+ c3 kZk
2
kwk c0 + c1 kZk
where, c0 , c1 , c2 , c3 are known constants. Consider the
Lyapunov candidate function,
h
i
1
1
, V ) = 1 eT P e + tr(W
L(e, W
w W ) + tr(V v V )
2
1
L = eT Qe + rT (w + r ) kektr(Z T Z)
2
10 of 11
American Institute of Aeronautics and Astronautics
F kZ kF kZk
2 and using
Using tr(Z T Z) kZk
F
Eq. (50) for the robustifying term r , results in
1
L eT Qe + krkkwk rT Kr r(kZkF + Z)
2
2 + kekkZk
F Z
kekkZk
F
Using the bound on w and requiring that
min (Kr )
c2
kP Bk
and
> kP Bkc3
(bv + x
c + x
rm + Z)kP
Bk + Z
Now, L 0 when,
F Zm =
kZk
a1 +
or
kek
a0 + a1 Zm
1
2 min (Q)
Acknowledgements
This work was supported in part by DARPAs
Software Enabled Control Program under Contracts #33615-98-C-1341 and #33615-99-C-1500 with
William Koenig of the Air Force Research Laboratory
(AFRL) as contract monitor. We also acknowledge
the contributions of Eric Corban, Jeong Hur, Wayne
Pickell, Joerg Dietrich and Henrik Christophersen who
made the flight tests possible.
References
1 Frazzoli,