29
Robotic Motion Planning: Probabilistic and Controls Primer Robotics Institute 16-735 http://voronoi.sbp.ri.cmu.edu/~motion Howie Choset http://voronoi.sbp.ri.cmu.edu/~choset 16-735, Howie Choset with slides from Vincent Lee-Shue Jr. Prasad Narendra Atkar, and Kevin Tantisevi

Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

  • Upload
    others

  • View
    2

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Robotic Motion Planning:Probabilistic and Controls Primer

Robotics Institute 16-735http://voronoi.sbp.ri.cmu.edu/~motion

Howie Chosethttp://voronoi.sbp.ri.cmu.edu/~choset

16-735, Howie Choset with slides from Vincent Lee-Shue Jr. Prasad Narendra Atkar, and Kevin Tantisevi

Page 2: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Experiments and outcomes

• Experiment: Flip a Coin• Outcome: Heads or Tails

• Experiment: Person’s temperature in class now• Outcome: a scalar

• Event Subset of possible outcomes SE ⊂

Page 3: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Probability

• Pr(E): Probability of an event E occurring when an experiment is conducted

• Pr maps S to unit interval

Page 4: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Dependence

• Independent:

• Conditional Probability:

– If are independent, then

– Bayes Rule

)Pr()Pr()Pr( 2121 EEEE =∩

Page 5: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

More Bayes Rule

)()()|()|(

bpapabpbap =

)|()|(),|(),|(

cbpcapcabpcbap =

Page 6: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Total Probability

∑ ∧=i

ibapap )()(

)()|( ii

i bpbap∑=Discrete

∫= dbbpbapap )()|()(Continuous

it follows that:

∫= dcbcpcbapbap )|(),|()|(

Page 7: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Random Variable

• A mapping from events to a real number

• Examples– Discrete: heads or tails, number of heads for repeated flips– Continuous: temperature

• Random Vector:

Page 8: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Distribution

• Any statement one can make about a random variable

• Cumulative Distribution Function (CDF):

• Probability ______ Function (P_F):

– Discrete: Mass (PMF)

– Continuous: Density (PDF)

Note that = 0

Page 9: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Uniform Distribution

CDF PDF

Page 10: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Expected Value

• PMF PDF

Page 11: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Variance and Co-variance

• Variance:

• Co-Variance

• Co-Variance Matrix

=

Or for

=

Diagonal terms Off-Diagonal Terms

Page 12: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Gaussians

Page 13: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Robotic Motion Planning:Controls Primer

Robotics Institute 16-735http://voronoi.sbp.ri.cmu.edu/~motion

Howie Chosethttp://voronoi.sbp.ri.cmu.edu/~choset

16-735, Howie Choset with slides from Vincent Lee-Shue Jr. Prasad Narendra Atkar, and Kevin Tantisevi

Page 14: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

State Space

Model of mass spring damper system

z(t) position, z(t) velocityt0 initial time, z(t0), z(t0) initial position & velocity

..

State space representation of mass spring damper system (1st order ODE)

Page 15: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Vector Field

Page 16: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Stability

.

for every ε > 0, there exists a δ for initial conditions

Stability:

Unstable: Neither

Asymptotic Stability:

Equilibrium x = 0 which occurs here at xe = 0

Page 17: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Stability and Eigenvalues

Negative damping….

Page 18: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Apply a force (a control input)

Page 19: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

ControlabilityFor any initial condition x(t0), there exists an input u(t) that drives the

solution x(t) to the origin*

*(assuming the origin is an equilibrium point for the unforced system)

The LTI is control system controllable if and only if W has rank n where

W = [ B AB A2B … An-1B]

Page 20: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Closed Loop Stability: Pole PlacementMake an unforced unstable system stable

State dependent control law

look at the eigenvalues

For a real valued matrix, if an eigenvalue a + ibhas b = 0, then a – ib is an eigenvalue

So,

Is allowable if for each λi that has an imaginary part, there is a λjthat is a complex conjugate

AssumeThis system is controllable, i.e., the pair is controllableB is full rank

is an allowable set of complex numbers

Then there exists an constant matrix so that

Page 21: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

What does this mean?

• To stabilize

• Find a K so that the Eigenvalues of A – BK have negative real values and are complex conjugates.

• The famous LQR does this by optimizing a user-defined cost function.

State dependent control law

Page 22: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Example

• Mass-spring-damper (negative damping - why)

• Eigenvalues

• Chose

• This is like adding positive damping

Page 23: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Observing LTI Systems

• Sadly, one cannot always sense all of the state variables

• Example: can only sense or measure velocity

• Can we recover the state from the observations??

state control output

May not be invertible (nor square)

Page 24: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Observable

The system

Is observable if has rank n

A system is observable if one can determine the initial state by observing the output and knowing the controls over some period of time

The pair (A,C) is considered observable.

(A,C) observable if and only if (AT, CT) is controllable

If (A,B) observable and (A,C) observable, then (A,B,C) is minimal

Page 25: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Observer

We know

Estimated output

+

-

K

u

y

State estimate

Copy of original system with a correcting term which is the difference between the output and estimated output

Page 26: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

How does this work

• Consider the error

• As• Chose K so that is asymp. Stable• Look at eigenvalues of A - KC (not quite right form)• Look at eigenvalues of At – CtKt (same eigenvalues)• Make sure such eigenvalues are allowable

– Make sure (At,Ct) is controllable– Ct is full rank

• Same as saying (A,C) is observable• So it is a matter of choosing K

Page 27: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Example

Chose

Chose

Page 28: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Discrete Time

Page 29: Robotic Motion Planning: Probabilistic and Controls Primermotionplanning/lecture/lec18_lastyear.pdf · Closed Loop Stability: Pole Placement Make an unforced unstable system stable

Properties

• Stability of x(k+1) = F(x) x(k)– Let denote the eigenvalues of F

• Controllability of (F,G)

• Observability of (F,H) – if Ft, Ht is controllable