Lecture 6 – Outer Loop

advertisement
Lecture 6 – Outer Loop
•
•
•
•
•
Setpoint profile generation
Gain scheduling
Feedforward and 2DOF design
System inversion problem
Feedforward for simple models
– Zero order, first order, second order, oscillatory (input shaping)
• Iterative update of feedforward
– Run-to-run, cascade loop
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-1
Setpoint profile generation
• Setpoint profile generation = path/trajectory planning
• Changing setpoint acts as a disturbance for the feedback loop.
• The closed-loop output follows the command accurately
within the loop bandwidth
• A practical approach: choose the setpoint command (path) as
a smooth function that has no/little high-frequency
components.
• The smooth function can be a spline function etc
yd(t)
EE392m - Spring 2005
Gorinevsky
Commanded
output or
setpoint
Control Engineering
Plant
-
Feedback
controller
cascasde loop
6-2
Setpoint profile
• Real-time replay of a pre-computed reference trajectory
yd(t) or feedforward v(t)
• Reproduce a nonlinear function yd(t) in a control system
⎡ Y1 = yd (θ1 ) ⎤
⎡θ1 ⎤
⎢Y = y (θ ) ⎥
⎢θ ⎥
Computed profile
d
2 ⎥
⎢ 2⎥
t
yd(t) Y = ⎢ 2
Θ
=
,
data arrays Y ,Θ
M
⎢
⎥
⎢M⎥
⎢
⎥
⎢ ⎥
=
(
)
⎣Yn yd θ n ⎦
⎣θ n ⎦
On-line computations:
1. Find j, such that θ j ≤ t ≤ θ j +1
2. Compute linear interpolation
θ j +1 − t
t −θ j
+ Y j +1
yd (t ) = Y j
θ j +1 − θ j
θ j +1 − θ j
EE392m - Spring 2005
Gorinevsky
Control Engineering
y
Yj
t
θj
6-3
Linear interpolation vs. table look-up
• Linear interpolation is more accurate than a table look-up
• Requires less data storage
• At the expense of simple computation
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-4
Approximation
• Interpolation:
– compute function that will provide given values Y j in the nodes θ j
• Approximation
– compute function that closely corresponds to given data, possibly
with some error
– might provide better accuracy throughout
y
Yj
t
EE392m - Spring 2005
Gorinevsky
θj
Control Engineering
6-5
B-spline interpolation
• 1st-order
– look-up table, nearest neighbor
• 2nd-order
– linear interpolation
yd (t ) = ∑ Y j B j (t )
j
• n-th order:
– Piece-wise n-th order polynomials, continuous n-2 derivatives
– Is zero outside a local support interval
– The support interval extends to n nearest neighbors
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-6
B-splines
• Accurate interpolation of smooth
functions with relatively few nodes
• For 1-D function the gain from using
high-order B-splines is often not worth
the added complexity
• Introduced and developed in CAD for
2-D and 3-D curve and surface data
• Are used for defining
multidimensional nonlinear maps
• All you need to know that B-splines
are useful. Actually using them would
require learning available software.
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-7
Gain Scheduling
Gain Schedule
• Simple example
y = f ( x ) + g ( x )u
u
u = − k ( x )( y − y d )
Controller
Plant
y
yd
• Control design requires
k ( x)
• The gain k is scheduled
on x
EE392m - Spring 2005
Gorinevsky
Example:
varying
process
gain
Control Engineering
6-8
Gain scheduling
Nonlinear
• Single out several
system
regimes - model
vec( A) ⎤
⎡
linearization or
⎢ vec( B ) ⎥
experiments
⎥
Y =⎢
⎢ vec(C ) ⎥
• Design linear controllers
⎢
⎥
for these regimes
vec(
D
)
⎣
⎦
• Approximate controller
dependence on the
regime parameters
Linear interpolation:
Y ( Θ) = ∑ Y jϕ j ( Θ)
j
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-9
Gain scheduling for aircraft
• Flight control
• Main trim condition
parameters are used
for scheduling
• Shown
– Approximation nodes
– Evaluation points
• Key assumption
– Altitude and Mach are
changing much slower
than time constant of
the flight control loop
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-10
Feedforward
Feedforward
controller
Plant
Plant
Feedback
controller
– this Lecture 6
• Main premise of the feedforward control: a
– Lectures 3-5
model of the plant is known
– Lectures 7-8
• Model-based design of feedback control - the
same premise
• The difference: feedback control is less
sensitive to modeling error
Plant
• Common use of the feedforward: cascade
with feedback
Feedforward
Feedback
controller
EE392m - Spring 2005
Gorinevsky
Control Engineering
controller
6-11
Why Feedforward?
• Model-based design means we know the system in advance
• The performance can be often greatly improved by adding
open-loop control based on our system knowledge (models)
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-12
Disturbance feedforward
• Disturbance acting on the
plant is measured
• Feedforward controller can
react before the effect of
the disturbance shows up
in the plant output
Example: Temperature control
• Measure ambient temperature
and adjust heating/cooling
• homes and buildings
• district heating
• industrial processes
– growing crystals
• electronic or optical components
Disturbance
Plant
Feedforward
controller
EE392m - Spring 2005
Gorinevsky
Feedback
controller
Control Engineering
6-13
Command/setpoint feedforward
• The setpoint change acts as
Examples:
disturbance on the feedback loop. • Servosystems
– Robotics
• This disturbance can be measured
– Aerospace
• 2-DOF controller architecture
• Process control
– Feedback controller
– Feedforward controller
– Joint design
– RTP
• Propulsion (aero + auto)
– Engine power demand
Commanded
output or setpoint
Plant
Feedforward
controller
-
Feedback
controller
Cascade loop
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-14
Feedforward as system inversion
yd(t)
Feedforward
controller
Plant
u(t)
y(t)
y = P ( s )u
• To get the output y = y d need to apply control u FF = [P ( s )] y d
• Simple example – feedthrough system with known gain
P( s ) = g
y = gu + w
−1
• System inverse and feedforward
1
1
−1
u FF = y d
[P( s )] =
g
g
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-15
Feedforward for 0th order model
• Constant gain model (approximate)
Step response for
the design model:
y = gu + w
y(t)=gu(t)
• There is a modeling error
• It might be desirable to introduce
low pass filtering such that high
frequencies are not excited by the
feedforward
1
1
u FF =
⋅ yd
1 + τs g
EE392m - Spring 2005
Gorinevsky
Control Engineering
Actual step response
0
6-16
Setpoint Feedforward
• Example: processor thermal control –
Lecture 4, Slide 6
H (s) =
FEEDFORW ARD ONLY
0.4
(5s + 1)(50 s + 1)
1
g = 0.4
u = u FF =
0.5
Feedforward:
1
yd
g
0
0
20
40
60
80
100
120
140
P-CONTROL, NO FEEDFORW ARD
1
kP = 8
0.5
P-feedback:
u = −k P ( y − y d )
0
0
20
40
60
80
100
120
140
P-CONTROL AND FEEDFORWARD
1
Feedforward
+ P-feedback:
u = − k P ( y − y d ) + u FF
0.5
EE392m - Spring 2005
Gorinevsky
0
0
20
40
Control Engineering
60
80
100
120
6-17
140
Feedforward for 1st order model
• Simple 1st order model – integrator
1
y= u+w
s
• Inverse system = differentiator
u FF ≈ sy d
• Differentiating estimator (with low pass filtering)
u FF
EE392m - Spring 2005
Gorinevsky
s
=
yd
1 + τs
Control Engineering
6-18
Feedforward as system inversion
y = P ( s )u
~
y (iω )
u~(iω ) = d
P(iω )
y = yd ⇒ u = [P( s )] yd
−1
• Issue
– High-frequency roll-off of the frequency response
– Attempting inversion would result at growing high-frequency gain
0
-5
-10
-15
-20
0.01
0.1
1
10
1
P( s ) =
1+ s
[P( s)]−1 = 1 + s
proper
transfer function
not proper
• Approximate inverse solution:
– ignore high frequency in some way
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-19
Proper transfer functions
• Proper means deg(Denominator) ≥ deg(Numerator)
• Strictly proper ÅÆ high-frequency roll-off, all physical
dynamical systems are like that
• State space models are always proper
• Exact differentiation is noncausal, non-proper
Acceleration measurement example
Attempted perfect control
m&x& = u
u = ma − k ( x − xd )
⇒ x = xd
EE392m - Spring 2005
Gorinevsky
accelerometer
a = &x&
this is
wrong!
Control Engineering
6-20
Approximate Differentiation
• Add low pass filtering:
1
1
⋅
P ( s) =
n
(1 + τs ) P( s )
†
Computed feedforward
1
τ = 0 .2
0.8
0.6
0.4
0.2
1
P( s ) =
1+ s
1
†
⋅ (1 + s )
P ( s) =
1 + τs
0
2
4
6
8
10
12
10
12
Desired and produced output
1
0.8
0.6
0.4
0.2
0
EE392m - Spring 2005
Gorinevsky
2
Control Engineering
4
6
8
6-21
Differentiation
• Setpoint profile = path/trajectory planning
• The derivative can be computed if yd(t) is known ahead of
time (no need to be causal then).
n
1
1
d
y
-1
[n]
[n]
P ( s ) yd =
⋅ n yd ,
yd (t ) = n (t )
P( s) s
dt
• This could be done by computing the profile yd(t) as an
output of an integrator chain
1
1
k
[k ]
y d (t ) = n a (t )
y d (t ) = s y d (t ) = n −k a (t )
s
s
Example
1
Compute the setpoint
P -1 ( s ) y d = s 2 y d = a (t )
P( s ) = 2
profile as a(t)
s
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-22
Double integrator example
-3
1
• Double
0.5
integrator
0
-0.5
model
-1
1
0
y= 2u
s
0.02
0.015
• Setpoint
0.01
profile
0.005
1
0
yd = 2 a
0
s
• Feedforward 1
u FF = a (t )
Example:
Disk drive long seek.
Move the R/W head a
target track
ACCELERATION
x 10
20
40
60
80
100
80
100
VELOCITY
20
40
60
POSITION
0.5
Hara et at. IEEE Tr. on Mechatronics, March 2000
0
0
EE392m - Spring 2005
Gorinevsky
20
40
60
80
100
Control Engineering
6-23
Input Shaping: point-to-point control
• Given initial and final conditions
find control input
• No intermediate trajectory
constraints
• Lightly damped, imaginary axis
poles
yd(t)
– inversion methods do not work well
Feedforward
controller
u(t)
Plant
Examples:
• Disk drive long seek with
flexible modes
• Flexible space structures
• Overhead gantry crane
• FIR notch fliter
– Seering and Singer, MIT
– Convolve Inc.
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-24
y(t)
Pulse Inputs
• Compute pulse inputs
such that there is no
vibration.
• Works for a pulse
sequence input
• Can be generalized to
any input
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-25
Input Shaping as signal convolution
• Convolution:
EE392m - Spring 2005
Gorinevsky
f (t ) * (∑ Aiδ (t − ti ) ) = ∑ Ai f (t − ti )
Control Engineering
6-26
Iterative update of feedforward
Feedforward
controller
• Repetition of control tasks
Plant
Step-to-step
feedback update
• Robotics
– Trajectory control tasks:
Iterative Learning Control
– Locomotion: steps
• Batch process control
– Run-to-run control in
semiconductor manufacturing
– Iterative Learning Control
(IEEE Control System Magazine,
Dec. 2002)
EE392m - Spring 2005
Gorinevsky
step
Example:
One-legged
hopping machine
(M.Raibert)
Height control:
yd = yd(t-Tn;a)
h(n+1)=h(n)+Ga
Control Engineering
6-27
More on Feedforward…
• Iterative update
– Iterative Learning Control, run-to-run update
– Repetitive dynamics (repeating robotics mechanism motion)
• Replay pre-computed sequences
– Look-up tables, maps
• Also used in practice
– Servomechanism, disturbance model
– Adaptive feedforward
• LMS update
• Sinusoidal disturbance tracking, e.g. in disk drives (related to PLL)
EE392m - Spring 2005
Gorinevsky
Control Engineering
6-28
Download