Open loop vs Closed Loop Steady State vs Transient Response

advertisement
Open loop vs Closed Loop
Advanced Control II
Motor
Command
Desired
Behavior
Movement
System
Outcome
Overview
•
Open Loop vs Closed Loop
•
Useful Open Loop Controllers
•
Some examples
Advanced Control I
Dynamical systems
• CPG (biologically inspired ), Force Fields
•
•
Feedback control
•
•
•
PID design
2nd order systems
Advanced Control II
Feedforward control
•
•
Transfer functions
Dynamics estimation
1
IAR - Dr. Sethu Vijayakumar
2
IAR - Dr. Sethu Vijayakumar
Steady State vs Transient Response
Transfer Function
Frequency Response: Response to a Smooth Change of Input
Room Heating
Q = Lθ + C
temp = θ
Q
Q2
L
Q
θ1 = 1
L
θ2 =
Q
θ3 = 3
L
θ0
∂θ
Process Dynamics
∂t
Steady State : θ ∞ =
Q = Lθ + C
Transient Response
Q
∂ Q
Q = L( + ∆θ ) + C ( + ∆θ )
L
∂t L
∂
⇒ 0 = L(∆θ ) + C ∆θ
∂t
Lt
Q
Q −
⇒ θ = + (θ 0 − )e C
L
L
IAR - Dr. Sethu Vijayakumar
temp = θ
∆Q(t ) = Iekt
θ0
Q
Q
L
Case 1: Exponentially Changing Inputs
Room Heating
∆θ =
∂
(θ + ∆θ )
∂t
∂
⇒ ∆Q = L(∆θ ) + C ∆θ
∂t
• Output same form as Input
1
Iekt
L + kC
• Scaled by 1/(L+kC)
Transfer Function:
f (s) =
1
L + sC
Same form
since linear
3
∂
∆θ
∂t
Solution:
∂θ
∂t
Q + ∆Q = L(θ + ∆θ ) + C
Iekt = L(∆θ ) + C
IAR - Dr. Sethu Vijayakumar
• s +ve: temp explodes
• s –ve: temp decays
• s complex: temp oscillates
4
1
Transfer Function (cont’d)
Case 2: Exponentially Changing Inputs
∆Q(t ) = I cos ωt
Room Heating
temp = θ
I cos ωt = L(∆θ ) + C
Q
Q = Lθ + C
⇒ ∆Q = L(∆θ ) + C
Room Heating
Q = L(θ − θ 0 ) + C
temp = θ
∂
∆θ
∂t
θ0
Q
Control Law :
ωC
∆θ = 2
cos ωt + 2
sin ωt
L + ω 2C 2
L + ω 2C 2
L
∂
(θ + ∆θ )
∂t
∂
∆θ
∂t
or ∆θ =
Feedback control
changes dynamics
1
Ieiωt
L + iωC
Q = k ( θt − θ )
Steady State :θ ∞ =
Time Constant :
Transfer Function:
f (ω ) =
1
L + iωC
∂θ
∂t
k = gain constant
Solution:
∂θ
∂t
Q + ∆Q = L(θ + ∆θ ) + C
Feedback Control: Proportional Error
k θt
Lθ0
+
≠ θt
L+k L+k
τ=
C
(L+k)
• High Gain → Small Error, Fast Response, Instability
• Steady State Error
• Time Lag
IAR - Dr. Sethu Vijayakumar
5
IAR - Dr. Sethu Vijayakumar
Eliminating Steady State Error
Š Use Feedforward Scheme
PID control
Q = k (θ t − θ ) + L(θt − θ 0 )
Q = K p ⋅ e + K i ⋅ ∫ e ⋅ ∂t + K d ⋅
where e = (θ − θ t )
„
„
Needs Dynamics Model (L)
Error persists if L is inaccurate
e
Š Change Control Law
„
„
„
„
„
„
Q = k p (θt − θ ) + ki ∫ (θt − θ )dt
e
∂e
∂t
∂e
∂t
Without derivative action
e
∂e
∂t
Proportional Integral Controller
Integral controller eliminates steady-state error
No dynamic model needed
Don’t need high kp gains
Overshoot /ringing problems
Choice of kp and ki is tricky
IAR - Dr. Sethu Vijayakumar
6
t
• With derivative action, the controller output is proportional to the rate of
change of the measurement or error: braking effect.
• Adds damping Æ brakes the dynamics: reduces overshoot and tends to
reduce the settling time
• Problem: if too large, will slow down the dynamics, and increase the
rising and settling time
7
IAR - Dr. Sethu Vijayakumar
8
2
Second Order Process
Proportional Error Law
Š More complex behavior
Š Similar analysis tools
Control
Input
x
Motor
Dynamics
Car
Position
0 = k p + s + τs
⇒s=−
9
k p e + kd e&
x
x
feedback
x&
Transient Analysis Solution
• Choose k_d to set time constant
0 = k p + ( 1 + kd )s + τs
• Choose k_p for critical damping
⇒s=−
2
( 1 + kd )2 − 4k p τ
1 + kd
±
2τ
2τ
IAR - Dr. Sethu Vijayakumar
Under-damped
Over-damped
2
1 − 4k p τ
1
±
2τ
2τ
Critically
Damped
kp <
1
4τ
kp =
1
4τ
Ringing
kp >
1
4τ
10
Feedback: Pros and Cons
car
dx
d2x
+τ 2
dt
dt
Second Order Behavior
IAR - Dr. Sethu Vijayakumar
Proportional Derivative Error Law
xt
x
feedback
Transient Analysis Solution
dx
d 2x
+τ 2
dt
dt
IAR - Dr. Sethu Vijayakumar
controller
dx
d2x
+τ 2
dt
dt
k p ( xt − x )
x
β
car
controller
xt
11
+ Alters Process Dynamics
+ Insensitive (relatively) to model errors
+ Insensitive to disturbances
- (P) Steady State Error
(P-I) Overshoot
(P-D) Gain Limitations, Noise Amplification
- Assumes instant feedback
-
Limited by time constant in feedback path
Can and Do use Open loop with Feedforward
+ Fast response
+ Often Simple to do
- Need good process model (dynamics) …Learn It (details in MLSC course)
IAR - Dr. Sethu Vijayakumar
12
3
Download