Distributed Consensus and Cooperative...
Transcript of Distributed Consensus and Cooperative...
IPAM, 9 Jan 07 R. M. Murray, Caltech 1
Distributed Consensus andCooperative Estimation
Richard M. Murray
Control and Dynamical Systems
California Institute of Technology
Domitilla Del Vecchio (U Mich) Bill Dunbar (UCSC) Alex
Fax (NGC) Eric Klavins (U Wash)
Reza Olfati-Saber (Dartmouth)
Vijay Gupta Zhipu Jin Demetri Spanos
Abhishek Tiwari Yasi Mostofi
Cedric Langbort (CMI/UIUC)
IPAM, 9 Jan 07 R. M. Murray, Caltech 2
RoboFlag Subproblems
Goal: develop systematic techniques for solving subproblems
• Cooperative control and graph Laplacians
• Distributed receding horizon control
• Verifiable protocols for consensus and control
1. Formation control
• Maintain positions toguard defense zone
2. Distributed estimation
• Fuse sensor data todetermine opponentlocation
3. Distributed consensus
• Assign individuals totag incoming vehicles
Implement and testas part of annual RoboFlag competition
IPAM, 9 Jan 07 R. M. Murray, Caltech 3
Information Flow in Vehicle Formations
Example: satellite formation
• Blue links represent sensed
information
• Green links representcommunicated information
Sensed information
• Local sensors can see some subset of nearbyvehicles
• Assume small time delays, pos’n/vel info only
Communicated information
• Point to point communications (routing OK)
• Assume limited bandwidth, some time delay
• Advantage: can send more complexinformation
Topological features
• Information flow (sensed or communicated)represents a directed graph
• Cycles in graph ! information feedback loops
Question: How does topological structure of information flow affectstability of the overall formation?
IPAM, 9 Jan 07 R. M. Murray, Caltech 4
Sample Problem: Formation Stabilization
Goal: maintain position relative to neighbors
• “Neighbors” defined by graph
• Assume only sensed data for now
• Assume identical vehicle dynamics, identicalcontrollers?
Example: hexagon formation
• Maintain fixed relative spacing between left andright neighbors
Can extend to more sophisticated “formations”
• Include more complex spatia-temporal constraints
( )i
i j i j ij
j N
e w y y h!
= " "#
relativeposition
weightingfactor
offset
1 2
3
45
6
1 2
3
45
6
IPAM, 9 Jan 07 R. M. Murray, Caltech 5
Graph Laplacian
Construction of (weighted) Laplacian
A = adjacency matrix
D = diagonal matrix, weighted by outdegree
Properties of Laplacian
• Row sum equal 0 (stochastic matrix)
• All eigenvalues are non-negative, with atleast one zero eigenvalue (from row sum)
• Multiplicity of 0 as an eigenvalue is equalto the number of strongly connectedcompo-nents of the graph
• All eigenvalues lie in a circle of radius onecentered at 1 + 0i (Perron Frobenius)
• For bidirectional (eg, undirected) graphs,eigenvalues are all real, in [0,2]
1 11 0 0 0
2 2
0 1 0 0 1 0
1 1 10 0 1
3 3 3
0 0 0 1 1 0
1 1 10 0 1
3 3 3
1 10 0 0 1
2 2
L
! "# #$ %
$ %#$ %
$ %# # #$ %
$ %=#$ %
$ %$ %# # #$ %$ %
# #$ %$ %& '
1L I D A
!= !
IPAM, 9 Jan 07 R. M. Murray, Caltech 6
Mathematical Framework
Analyze stability of closed
loop
• Interconnection matrix, L, isthe Laplacian of the graph
• Stability of closed looprelated to eigenstructure ofthe Laplacian
ˆ ( )K s ˆ( )P s
yL I!
y
h
e u
IPAM, 9 Jan 07 R. M. Murray, Caltech 7
Stability Condition
Theorem The closed loop system is (neutrally) stable iff the Nyquist plot ofthe open loop system does not encircle -1/"i(L), where "i(L) are the nonzeroeigenvalues of L.
Example
ˆ ( )K s ˆ( )P s
yL I!
y
h
e u
2( )
se
P ss
!"
= ( ) d pK s K s K= +
Fax and Murray
IFAC 02, TAC 04
IPAM, 9 Jan 07 R. M. Murray, Caltech 8
Spectra of Laplacians
0,1! =
Unidirectional
tree
2 ( 1) /1 i j N
i e!" #
= #
Cycle
[0,2]! "
Undirected
graph
10, 2
N! != =
Periodic
graph
IPAM, 9 Jan 07 R. M. Murray, Caltech 9
Example Revisited
Example
• Adding link increases the number of three cycles (leads to “resonances”)
• Change in control law required to avoid instability
• Q: Increasing amount of information available decreases stability (??)
• A: Control law cannot ignore the information ! add’l feedback inserted
2( )
se
P ss
!"
= ( ) d pK s K s K= +
x
x
x
x
IPAM, 9 Jan 07 R. M. Murray, Caltech 10
Improving Performance through Communication
Baseline: stability only
• Poor performance due to interconnection
Method #1: tune information flow filter
• Low pass filter to damp response
• Improves performance somewhat
Method #2: consensus + feedforward
• Agree on center of formation, then move
• Compensate for motion of vehicles byadjusting information flow
Fax and Murray
IFAC 02
IPAM, 9 Jan 07 R. M. Murray, Caltech 11
Special Case: Consensus
Consensus: agreement between agents using information flow graph
• Can prove asymptotic convergence to single value if graph is connected
• If wij = 1/(in-degree) + graph is balanced (same in-degree for all nodes) ! all
agents converge to average of initial condition
Variations and extensions (Jadbabaie, Leonard, Moreau, Morse, Olfati-
Saber, Xiao, …)
• Switching (packet loss, dropped links, etc),time delays, plant uncertainty
• Nearest neighbor graphs, small world networks, optimal weights
• Nonlinear: potential fields, passive systems, gradient systems
• Distributed Kalman filtering, distributed optimization
-1
x
x
x
x
IPAM, 9 Jan 07 R. M. Murray, Caltech 12
Open Problems: Design of Information Flow (graph)
How does graph topology affect location of eigenvalues of L?
• Would like to separate effects of topology from agent dynamics
• Possible approach: exploit for of characteristic polynomial
-1
x
x
x
x
IPAM, 9 Jan 07 R. M. Murray, Caltech 13
Performance
Look at motion between selected vehicles
Jin and Murray
CDC 04
G1 - Control G2 - Performance
IPAM, 9 Jan 07 R. M. Murray, Caltech 14
Robustness
What happens if a single node “locks up”
Different types of robustness (Gupta, Langbort & M)
• Type I - node stops communicating (stopping failure)
• Type II - node communicates constant value
• Type III - node computes incorrect function (Byzantine failure)
Related ideas: delay margin for multi-hop models (Jin and M)
• Improve consensus rate through multi-hop, but create sensitivity tocommuncations delay
• Single node can change entirevalue of the consenus
• Desired effect for “robust”behavior: #xI = $/N
x1(0) = 4
x2(0) = 9
x3(0) = 6 x4(t) = 0
X5(t) = 6
x6(t) = 5
Gupta, Langbort and Murray
CDC 06
IPAM, 9 Jan 07 R. M. Murray, Caltech 15
Alice Overview
Team Caltech
• 50 students worked on Alice over 1 year
• Course credit through CS/EE/ME 75
• Summer team: 20 SURF students + 6graduated seniors + 4 work study + 4grads + 2 faculty + 6 volunteers (= ~40)
Computing
• 6 Dell 750 PowerEdge Servers (P4,3GHz)
• 1 IBM Quad Core AMD64 (fast!)
• 1 Gb/s switched ethernet
Software
• 15 individual programs with ~50 threadsof execution
• Sensor fusion: separate digital elevationmaps for each sensor; fuse @ 10 Hz
• Path planning: optimization-basedplanning over a 10-20 second horizon
Short rangestereo
Long rangestereo
LADAR (4)
Alice
IPAM, 9 Jan 07 R. M. Murray, Caltech 16
OnlineOptimization(RHC, MILP)
An Architecture for Networked Control Systems(following P. R. Kumar)
Sensing
External Environment
SystemActuation Fe
ed
er:R
elia
ble
StateServer
(KF -> MHE)
Inner Loop(PID, H!)
Co
mm
an
d:F
IFO
1-3 Gb/s
Sensing
OnlineOptimization(RHC, MILP)
Traj:Causal Mode andFault
Management
StateServer
(KF -> MHE)
Online ModelModel:Safe %
& State:Unreliable Mode:Agreed % & Model:Safe
ActuatorState:Unreliable
Map:CausalTraj:Causal
10 Mb/s
OnlineOptimization(RHC, MILP)
Goal Mgmt(MDS)
Attention &Awareness
Memory andLearning
State:Unreliable
StateServer
(KF, MHE)
100 Kb/s
!
!!
!
IPAM, 9 Jan 07 R. M. Murray, Caltech 17
2007 Urban Challenge - 3 November 2007
Autonomous Urban Driving
• 60 mile course, less than 6 hours
• City streets, obeying traffic rules
• Follow cars, maintain safe distance
• Pull around stopped, moving vehicles
• Stop and go through intersections
• Navigate in parking lots (w/ other cars)
• U turns, traffic merges, replanning
• Prizes: $2M, $500K, $250K
DARPA, 2006
IPAM, 9 Jan 07 R. M. Murray, Caltech 18
Summary: Networked Control Systems
1. Formation control
• Maintain positions toguard defense zone
2. Distributed estimation
• Fuse sensor data todetermine opponentlocation
3. Distributed consensus
• Assign individuals totag incoming vehicles
Integration of computer science, communications, and control
• Mixture of techniques from computer science, communications, control
• Increased need for reasoning at higher levels of abstraction (strategy)
IPAM, 9 Jan 07 R. M. Murray, Caltech 19
RoboFlag Subproblems
Goal: develop systematic techniques for solving subproblems
• Distributed receding horizon control
• Packet-based, distributed estimation
• Verifiable protocols for consensus and control
1. Formation control
• Maintain positions toguard defense zone
2. Distributed estimation
• Fuse sensor data todetermine opponentlocation
3. Distributed consensus
• Assign individuals totag incoming vehicles
Implement and testas part of annual RoboFlag competition
IPAM, 9 Jan 07 R. M. Murray, Caltech 20
Distributed Sensor Fusion
Simulation results
• Exchanging information, evenintermittently, decreases error
Optimal estimation
• Q: what should sensorscommunicate?
• How should packet loss be handled?
Two agents viewing single object
• Each sensor maintains its own estimate
• Sensors can communicate w/ packet loss
y
x
IPAM, 9 Jan 07 R. M. Murray, Caltech 21
Decentralized Estimation Algorithm
Two sensor case
• Optimal estimator can bedecoupled into twocontributions
• Sensor i can computecontribution to estimate jand transmit
• If information not received,use local info to propagateestimate
• In n sensor case, decom-position not as straight-forward; suboptimal
Gupta, M & Hassibi
CDC 2004 (s)
Calculate owncontribution
Communicatecontributions
Fusecontributions
Propagate ownestimate
Propagate fusedestimate
Measurement Update Time Update
IPAM, 9 Jan 07 R. M. Murray, Caltech 22
RoboFlag Subproblems
Goal: develop systematic techniques for solving subproblems
• Cooperative control and graph Laplacians
• Distributed receding horizon control
• Verifiable protocols for consensus and control
1. Formation control
• Maintain positions toguard defense zone
2. Distributed estimation
• Fuse sensor data todetermine opponentlocation
3. Distributed consensus
• Assign individuals totag incoming vehicles
Implement and testas part of annual RoboFlag competition
IPAM, 9 Jan 07 R. M. Murray, Caltech 23
Optimization-Based Control
Task:
• Maintain equalspacing of vehiclesaround circle
• Follow desiredtrajectory for centerof mass
Parameters:
• Horizon: 2 sec
• Update: 0.5 sec
Local MPC + CLF• Assume neighbors follow
straight lines
Global MPC + CLF
Dunbar and M
IFAC 02
IPAM, 9 Jan 07 R. M. Murray, Caltech 24
Individual optimization:
Theorem. Under suitableassumptions, vehiclesare stable and convergeto global optimal solution.
Pf Detailed Lyapunovcalculation (Dunbar thesis)
Main Idea: Assume Plan for Neighbors
sta
te
timet0 t0+d
z3(t0)
z3*(t;t0) z3
k(t)
What 2 assumes
What 3 does
Compatibility constraint:• each vehicle transmits
plan to neighbors• stay w/in bounded path
of what was transmitted
IPAM, 9 Jan 07 R. M. Murray, Caltech 25
Example: Multi-Vehicle Fingertip Formation
2
4
qref
d31
IPAM, 9 Jan 07 R. M. Murray, Caltech 26
Simulation Results
IPAM, 9 Jan 07 R. M. Murray, Caltech 27
RoboFlag Subproblems
Goal: develop systematic techniques for solving subproblems
• Distributed receding horizon control
• Packet-based, distributed estimation
• Verifiable protocols for consensus and control
1. Formation control
• Maintain positions toguard defense zone
2. Distributed estimation
• Fuse sensor data todetermine opponentlocation
3. Distributed consensus
• Assign individuals totag incoming vehicles
Implement and testas part of annual RoboFlag competition
IPAM, 9 Jan 07 R. M. Murray, Caltech 28
P(k1,k2) := {
initializers
guard1:rule1 guard2:rule2 ...
}
S(k1,k2):=P(k1,k2)+C(k1+1) sharing y,u
"soup" of guarded commands
composition = union
non-shared variablesremain local tocomponent programs
CCL: Computation and Control LanguageFormal Language for Provably Correct Control Protocols
CCL Interpreter
Formal programming lang-uage for control and comp-utation. Interfaces withlibraries in otherlanguages.
Automated Verification
CCL encoded in the Isabelle
theorem prover; basic specsverified semi-automatically.Investigating various modelchecking tools.
Formal Results
Formal semantics intransition systems andtemporal logic. RoboFlag drillformalized and basicalgorithms verified.
CCL Protocol for
Decentralized
Target Allocation
IPAM, 9 Jan 07 R. M. Murray, Caltech 29
Example #1: Situational Awareness
Communications complexity
• Maintain “situational awareness”
• Assume point-to-point commun-ications and that each robotknows its own position
• Q: how many messages arerequired for each robot to keeptrack of all other robots w/in "?
• A: O(n2) messages (worst case)
Method #1: Distance Modulated Communication - O(n log n)
• Maintain position estimates to within k'xi – xj'
• Communicate more often with robots that are closer
Method #2: Wandering Communication Scheme - O(n)
• Only moving robots need to keep track of position
• Robots transfer knowledge when they stop/start
Proof of
correctness
using CCL
Klavins
WAFR 02
IPAM, 9 Jan 07 R. M. Murray, Caltech 30
Example #2: RoboFlag Drill
Things that we can prove (so far)
• Semi-automated proofs (Isabelle)
• Avoidance: no two robots collide
• Self-stabilization: if attackers arefar enough away, defenders self-stabilize before attackers arrive
Next steps
• Implement CCL on MVWT
• Improved reasoning toolbox
Sample drill
• N on N attack, w/
replenishment
• Random initial
assignments
• Switching proto-
col to avoid
collisions
Klavins
CDC, 03
IPAM, 9 Jan 07 R. M. Murray, Caltech 31
Formal Specifications
Safety (Defenders do not collide)
Stability (switch stays false)
Robots are "far enough" apart.
Lyapunov Stability:
IPAM, 9 Jan 07 R. M. Murray, Caltech 32
Example #3: Observation of CCL Programs
Del Vecchio & Klavins, CDC'03
Problem: Determine state of communications
protocol used by a group of robots given their
physical movements.
Assumptions: Protocol and motion control are
described in CCL like language.
Results:
• Defns of observability, etc. for CCL programs
• Construction and analysis of observer that
converges when the system is "weakly"
observable
• Construction of an efficient observer for
Roboflag drill in particular
• Everything specified in CCL