0:04

What we're doing now is,

Â let's talk about rigid bodies.

Â We're going to go through some sections.

Â We're going to talk then also about attitude.

Â There are some typical prototypical stuff.

Â You actually derive some of these then in your next homework.

Â No, actually, this one. This one does it too.

Â It's pretty straightforward algebra.

Â Definitely do it in matrix vector form, like this.

Â Don't do it component by component.

Â It will take pages.

Â Here, this is our dynamical system.

Â We only care about rates.

Â This kinetic sequative differential equation has a Q, a control torque Q.

Â No other external torque,

Â just our control torque.

Â That's a very simplified system, but this works.

Â Now we want to go ahead.

Â Our goal here is just to drive omega to zero.

Â That's what we're going to be doing.

Â So this is a regulation problem.

Â Were write our Lyapunov function in terms of the states we care about.

Â Do our rates go to zero?

Â I'm actually using true kinetic energy over rigid body. It's a great one.

Â Right? The inertia tensor has positive eigenvalues called principle inertias,

Â and it's symmetric posit definite, so this works.

Â Good.

Â Now with this as kinetic energy,

Â we can go ahead and take a derivative.

Â If you take the derivative of this function,

Â you end up with this result.

Â Let me show you that step by hand,

Â just to kind of go through.

Â This is the part that sometimes people skip again.

Â You've done this before in kinematics.

Â If V is equal to one half omega,

Â transpose I omega, the left hand side is a scalar.

Â Now we're taking a derivative,

Â as seen by what frame are we taking this time derivative.

Â Scalar.

Â It's a scalar What does that mean?

Â Doesn't matter.

Â Doesn't matter.

Â You see this is inertial derivative, definite marking points off in exam.

Â Right? It's a scalar.

Â There is no frame dependent.

Â Another trick question for them today.

Â It's not a frame-dependent derivative.

Â It's just a derivative of a scalar.

Â However, the right hand side is the result of a bunch of vector and tensor math,

Â where you do care about,

Â as seen by what frame?

Â So the right hand side, as seen by what frame,

Â would you wish to take the time derivative?

Â What would make your life the easiest?

Â Y.

Â Why?

Â Y doesn't change.

Â Yeah. The inertia tensor for a rigid body is going to be

Â fixed as seen by itself, the body.

Â Let's do this explicitly.

Â I'm going to use the shorthand.

Â That this is equal to just the prime.

Â Prime is a body frame derivative that is our typical inertial.

Â This saves you lots of time.

Â If you do this you're going to have---.

Â Let's just be really explicit.

Â I'm going to have omega prime,

Â transposed I omega, plus one half omega,

Â transposed I, omega prime.

Â There's no I-prime, right?

Â The inertia tensor, as seen by the body,

Â is there. That's good.

Â How can we manipulate this to simplify it?

Â What's the trick we use it?

Â Scalar, so you can transpose one of them, if you can.

Â Right.

Â The answer is scalar.

Â All this matrix math,

Â you can always just transpose it or flip it.

Â A times B, if the whole thing becomes transposed,

Â you flip the order, it's B transposed times A transposed.

Â This puts an omega here transposed.

Â The I transposed is still I, it's symmetric.

Â Then the I-prime transposed on the right hand side becomes transposed of a transposed,

Â it's just the same as here.

Â One half and one half just gives you the same omega,

Â transposed I, omega prime.

Â Now, in the equations I showed you,

Â this was one half omega,

Â transposed I, will make a dot.

Â Why can I make this substitution?

Â CK?

Â Because it's angular velocity. So when you--

Â Because any angular velocity has no frame dependency?

Â Be more specific.

Â Because you're taking the body frame derivatives.

Â Because what? What's this omega?

Â This omega between which two frames?

Â The body and the inertial.

Â Exactly.

Â This is a shorthand.

Â This is confusing. Don't use a shorthand.

Â Make it omega B relative to N. Very quickly we'll do tracking,

Â where it's B relative to R. Then this derivative looks very different.

Â --an extra one half in there.

Â I do.

Â Thank you. Okay.

Â These two things combine.

Â You don't have to do this every single time.

Â In an exam, this step in particular, I think,

Â once you know how to manipulate symmetric scalar matrices like this,

Â it's like what is derivative of three times x squared?

Â It's going to be three times two times x times derivative of x.

Â Right? It's the same thing here.

Â You can do that.

Â You should be able to argue in an exam that

Â this derivative is equal to the inertial derivative,

Â because for tracking, it's different.

Â I'm looking for subtleties there to do that.

Â This kind of math, once it makes sense,

Â you're from here to here very quickly.

Â This can be done in one step,

Â once you believe this math.

Â So good.

Â Let's go back.

Â We were here.

Â Taking the derivative kinetic energy gives us this stuff.

Â Now, we plug in the actual equations of motion.

Â That's what you were asking earlier, right?

Â These are the true.

Â Right now, it's just some expression,

Â has caused definite, taken a derivative.

Â Has nothing to do with my dynamical system.

Â Here, I apply my specific dynamical system and plug it in.

Â What happens then is you get this equation,

Â with this, Q is going to be our control torque.

Â What's going to happen to make omega transpose to omega tilde?

Â We've seen that first part, zero.

Â Right? We love zero. That's good. Simplifies stuff.

Â You end up with this equation. No big surprise.

Â We've seen this just before.

Â The same structure with a generalized mechanical system.

Â You end up with the same form for this rigid body.

Â Here instead of Q-dots, I have a little omega,

Â and the big Q is my,

Â in this case, control variable.

Â This is where I need to come up, now,

Â with a good control to drive it to zero.

Â As what we did with the general system,

Â I'm going to use Q is equal to minus P times omega.

Â P being symmetric posit definite.

Â It's basically a positive gain matrix.

Â This gives me some knobs to tune.

Â Last time somebody said, 'Well,

Â could you just put it in minus Q-dot, which should be minus omega.

Â Yes, it would be stable,

Â but you may not like the closing performance.

Â It may be way too sluggish,

Â it may be way too stiff.

Â You know, having control gains is good,

Â because now you can tune the performance.

Â And you've given it a whole bunch,

Â not just one scalar, but you given it a whole matrix, so you could do cross coupling,

Â and all kinds of things to place those poles but that's it.

Â Now, this control that we have,

Â what information do we need in this control?

Â What do you have to sense?

Â What do you have to know of the dynamical system?

Â Looking at this. Maurice?

Â Do I need to know my attitude?

Â Need to know your angular velocity?

Â Okay. You do need to know angular velocity.

Â What else do we need?

Â Do I need to know anything about the inertia?

Â In the stability analysis, yes.

Â We assume it's rigid.

Â But in the control,

Â there's no inertia that appears.

Â That's going be different on the controls very quickly.

Â That's a really good thing.

Â That means your control is infinitely robust to inertia errors.

Â You don't need the inertia.

Â All you need is to know what the rates are.

Â In fact, with a little math later on,

Â when you go Lyapunov optimal and saturated stuff,

Â we'll show you don't even to know omega perfectly.

Â As long as you have to sign right.

Â It's plus points in radians per second,

Â not minus points to radians per second.

Â If it's 0.3 or 0.5, it doesn't care.

Â The performance will be different but it will still be stable.

Â We can actually guarantee stability.

Â I'm not showing that here, that robustness.

Â But I can show here, immediately,

Â that this doesn't need the inertia tensor,

Â and that's a good thing in these controls.

Â Because you can think of a robotic docking system,

Â they've got Asteroid retrieval.

Â They want to grab boulders.

Â You don't know exactly what that mass is going to be.

Â You pick it up, and you're tumbling.

Â If you want to control that's just gonna go to stop it all tumbling,

Â and it's really robust,

Â this is a fantastic control.

Â It's a linear control,

Â but it will stabilize globally,

Â asymptotically the full nonlinear system.

Â So long as you don't run out of fuel.

Â Then you're just --you're in trouble.

Â Was there a question?

Â No? Okay. So if you plug this in,

Â this is where you get this.

Â And this is now--you know,

Â before we had stuff where we had to go to

Â second and third derivatives for asymptotic stability.

Â This is only a first order system.

Â My V is in terms of omega.

Â My V-dot is in terms of Omega,

Â and negative definite now in terms of omega.

Â Right? If you also cared about attitude,

Â if V-dot was in terms of sigma and omega,

Â and only omega appears,

Â that was the argument we had before,

Â when it's only a negative semi-definite.

Â My omega has to go to zero for V-dot to be zero,

Â but my sigma could be anything, because it doesn't appear.

Â Here, there's no attitude,

Â so therefore this is a negative definite function,

Â and you have global asymptotic stability.

Â For global stability, what did we have to argue as well?

Â That was an actual slide I threw in there.

Â Andrew, do you remember? What were the arguments to make something not local,

Â as Tony was talking about, but global?

Â Do we need to look at a higher derivative?

Â You're thinking convergence.

Â Oh, yeah.

Â That was-- if this were only negative semi-definite,

Â we could look at higher derivatives to

Â investigate if it is going to be asymptotically stable or not.

Â Right? These are if statements not if and only if.

Â If you can show this is negative definite, it is stable.

Â If you can't show that it's not negative definite,

Â it doesn't mean it's not stable.

Â We just don't know. Right?

Â What do we have to argue for global stability?

Â Why can I add this word in there?

Â Kaylee?

Â Radium unbounded.

Â These arguments we're doing have to be true for all states.

Â Otherwise, it's a dead giveaway.

Â Forget radium unbounded, this is only true for a small neighborhood,

Â then it's a local argument.

Â Right? This is true,

Â this is posit definite for any omega which is cool,

Â V-dot is negative definite for any omega, that's good.

Â These arguments are good for infinite vols, basically infinite neighborhoods.

Â Then on top of that,

Â we need this on to be radially unbounded, which it is.

Â Which means, as Omega goes to infinity along any direction,

Â this function will go to infinity as well.

Â Monotonically increases and goes up.

Â We don't have functions that go up but and then

Â asymptotically approach zero but never hit zero, that kind of stuff.

Â That's what causes issues with global stability arguments. Okay?

Â Here, clearly the case,

Â this is readily unbounded.

Â It goes to infinity as omega goes to infinity.

Â It's good for any initial conditions.

Â It's good for any initial conditions.

Â This is a globally asymptotically stabilizing control with

Â infinite insensitivity to inertial tensor,

Â because it doesn't appear.

Â That's regulation.

Â Now, let's do tracking. Tracking, as before, we had a QR-dot and Q-dot.

Â Here we're going to have omega-R, that's our reference.

Â I want this spacecraft to be spinning about

Â this axis and do this particular scanning motion of the sky.

Â Right? This is a time varying reference that we have to track now.

Â Now the state we care about is del omega.

Â When you writing it up on a function,

Â our del omega is, omega,

Â this is B relative to N,

Â this is R relative to N. Just like

Â what we did in the first few weeks with the kinematics.

Â This is the exact equation I was torturing you guys with: take

Â the inertial derivative of this and the body of the derivative in matrix form, right?

Â That's where you've practice already.

Â You can notice now,

Â our V function is only in terms of delta omega.

Â That's what we care about.

Â It's not what my omega B relative to N. This delta omega really

Â is omega B relative to R. We don't typically write it that way in control problems.

Â People like these deltas,

Â because deltas are supposed to go small, and so forth.

Â If you prefer, you could rewrite on

Â del omega as: this is omega B relative to N, R relative to N,

Â so del omega is B relative to R. Right?

Â That's the reference.

Â And we use the same mathematical structure.

Â This is no longer a kinetic energy,

Â but it has a kinetic energy like algebra,

Â because it worked out so well earlier.

Â For a control, there's never just one Lyapunov function that will prove stability.

Â I have a factor of one half in here.

Â The reason I have one half,

Â is because when I differentiate this,

Â that one half drops out.

Â If I didn't have the one half,

Â you have a factor of two floating around,

Â then there'd be a factor of two here.

Â It doesn't impact the stability.

Â Once you have one good Lyapunov function,

Â that function times 10 is still a good Lyapunov function, right?

Â You may even come up with different functional forms and prove stability.

Â This is just one of them that we're showing here,

Â because these are very convenient.

Â We do these derivatives and take-sorry,

Â the derivative of this,

Â as you were arguing before, differentiating this term,

Â this scalar product of tensors and vectors.

Â We like to do body frame derivatives,

Â because then there's no I-dot,

Â the inertial derivative of the inertial tensor.

Â But now, I need the body frame derivative of this one.

Â The same arguments we had earlier.

Â You can do chain rule,

Â and then add these two halves to give you this.

Â I've just stepped right into it.

Â But now I need the body frame derivative of

Â del omega and that's what I'm giving you here.

Â It's very simple.

Â I encourage you to do this by hand.

Â I'm just giving you the answer.

Â Once you recognize the pattern,

Â you should be done in 30 seconds or less.

Â Definitely something I could ask on an exam.

Â With this definition, you have the body frame derivative.

Â The body frame derivative, omega B,

Â and it's the same thing as the inertial,

Â as CK was saying just earlier, right?

Â But the body frame derivative of omega RN is not the same thing as the inertial.

Â You could do now our transport theorem again.

Â It's going to be the inertial derivative-- the R frame derivative of omega RN,

Â which is the same as the inertial plus-to-cross product you need,

Â and it ends up simplifying to this.

Â This is nothing but transport theorem.

Â If I show it to you it doesn't sink in.

Â I just want you to do that,

Â you see what the answer should be.

Â We've computed that now.

Â Immediately, you can see things get a little bit more complicated.

Â Now, I am plugging this into here that we have.

Â At some point, you have inertia times omega-dot,

Â which is nothing but our equations of motion.

Â This is where I'm substituting in our specific dynamical system as well.

Â Then you get this result;

Â a bunch of terms.

Â Now we have to come up with a control

Â Q that guarantees this V-dot is going to be negative definite.

Â A simple trick people do here is,

Â we basically set this V-dot equal to a negative definite term.

Â Again, we care about delta omega here,

Â so minus delta omega,

Â transpose P, delta omega.

Â Then I can set this equation equal to this equation,

Â and you solve for the Q. Del omega is factored out,

Â so this bracketed term has to be equal to minus P del omega.

Â From that, you can solve for Q.

Â That's typically how we develop them.

Â And that's it.

Â This control, compared to here,

Â now this requires inertia.

Â If you are doing a study,

Â you definitely want to look at sensitivities.

Â What if the inertia is off by 5%?

Â 10%? Turns out they're quite robust.

Â You can be off by many tens of percent,

Â and it still works reasonably well,

Â but your performance will be different.

Â It does depend on knowledge of inertia.

Â You have to feed forward the reference motion,

Â the reference acceleration of the angular velocities,

Â and put this all together.

Â Now, keep in mind too,

Â there's no coordinate frames defined here.

Â Your omega R is typically given in reference frame components.

Â Your omega is actually omega B,

Â and that's measured in a rate gyro in body frame components.

Â This is written in a frame agnostic way.

Â If you actually implement this,

Â make sure everything is in the same frame.

Â It's back to day one, right?

Â You don't have a vector --matrix representation of the vector in A frame,

Â plus a matrix representation of a vector in the B frame,

Â you're adding up wrong directions.

Â Here, if you implement this,

Â make sure that omega R in the R frame gets mapped to omega R in the B frame,

Â and the same thing with this vector.

Â Everything has to be in the B frame.

Â That will always be implied in my math.

Â I'm giving it to in a kind of a coordinate frame agnostic way.

Â Whichever frame you're picking,

Â make sure it's all consistent. All right?

Â So that's cool, because you can see in this control,

Â if you plug in this Q up here,

Â this term cancels this term,

Â this term cancels this term,

Â this term cancels this term,

Â and then it adds the desired V-dot behavior to it.

Â But there's a subtlety here.

Â This feedback control quadratically depends on omega.

Â This is inertia times omega times omega, essentially.

Â That's going to mean units of omega squared.

Â If we have really fast tip-off rates,

Â fast squared gets really, really fast.

Â Right? If you have a quantity like that, and you're squaring it,

Â and you control depends on that,

Â that means with fast-tip off rates,

Â you might be saturating.

Â Your stability assumes, right now, unlimited control authority.

Â There's no saturations we're including to guarantee stability.

Â That could be an issue.

Â I want to show you one little trick we can do

Â with these right functions to get rid of that.

Â This is how I derived it.

Â I took the system, I got this V-dot,

Â I set it equal to this V-dot, and then solved for the Q.

Â That's what I have here.

Â This is what it ended up being.

Â There's another thing I can do.

Â Instead of having omega tilde I omega,

Â if I put a control in here that says,

Â omega R tilde I omega,

Â I'm changing my control subtly.

Â It won't cancel with this term,

Â but let's look at the math there.

Â We had omega tilde I omega.

Â Then with the other control, there's a plus.

Â I'm making this now omega R tilde I omega.

Â If this was just omega tilde, the other two would cancel,

Â and life is easy.

Â If you do this, though,

Â you can say, okay, that's going to be minus omega,

Â minus omega R, and the whole thing tilded, times I omega.

Â It's A cross B plus C cross A.

Â You can add the two vectors up and then cross-product.

Â If you go look at the cross-product operators you can combine those.

Â This becomes nothing but del omega tilde I del Omega.

Â Now, why is that nice?

Â If you take a look at this other term,

Â all of this stuff is being pre-multiplied times del omega.

Â If we moved an R here,

Â this term and this term combines to be del omega tilde times something,

Â and whatever that product is,

Â it gets dotted or transposed with del omega,

Â and that's our wonderful identities: del omega dot,

Â transpose del omega tilde is always going to be zero.

Â Both of the controls, actually,

Â you can guarantee global asymptotic stability.

Â One of them then only linearly depends on the rates,

Â whereas the other one depends quadratically.

Â Now, what's better depends on performance.

Â Maybe you like the quadratic part.

Â Maybe it's doing good things for you,

Â and you have enough control authority,

Â it gives you a better closed loop response right.

Â That's where stability is one level of arguments and performance is a whole another one.

Â Different controls, as you saw with the multilink systems,

Â they're all stable, but they give you different performances.

Â Depending on your application, you can play with either.

Â Okay?

Â Good. We've done rate-based control, right?

Â We use kinetic energy for regulation.

Â We also use kinetic energy like things for tracking.

Â Tracking gets a little more complicated and sometimes there's tweaks you can do.

Â But we can prove global asymptotic stability.

Â