Okay, so that means we need to introduce control, right?

But how do you introduce control?

We know this pretty equation here, x dot equal to Ax plus Bu.

But what does it really mean? What is B?

What is u; u of course, is our control signal.

Well, we need to first find out what it is that we can

control about the system, let's say through

putting motors or through putting actuators, etc.

So we're going to assume that we can control

the acceleration of my first joint angle, theta

1.

And if we do that, then we see that our B matrix turns out to be this guy here.

Why?

Because now, when you put B here in this equation of yours, you'll

see that the input u shows up next to theta 1 double dot.

That means you can influence the acceleration of

my theta 1 double of my theta 1, right?

That's where my input shows up.

So that's how you generate

your B matrix. Now that we have this, great.

But can we, with this particular choice of B, actually control this guy or not?

That is, do we see if it's controllable of not?

And for this we have a very simple test, which is you create this matrix.

This is the controllability matrix, right?

And then you simply check the rank of this matrix.

So here we

going to make this matrix first.

And you guys should be comfortable with finding matrix multiplications, etc.

Not for maybe such big systems, but for let's say a

two by two matrix, you should be able to do it.

If you want we can really fast go over one example.

For example, this is your A, right: 0000, 1000, 0000,

0010. And then you've got, I'm going to find AB.

So let's put B here, which is 0100. And now, because my A is a 4 cross 4, and

my B is a 4 cross 1, my resulting matrix is going to be a 4 cross 1, right?

And let's multiply quick: 0 times 01000.

So this guy, because there's a one that lines up at the same place.

We're going to get a 1 here, which is here too, right?

And then there are no 1s that line up, so you get a 0, 0, and 0.

So you see how we got this guy here,

which correlates to this vector in the controllability matrix.

So you should be able to do AB, A square

B, etc, quite easily, for at least 2 cross 2 matrices.

And now we're going to check the rank of this guy,

and it turns out that the rank here is 2.

But we have this condition

that the rank needs to be full rank, or the matrix

needs to have full rank in order for it to be controllable.

That means it should have all linearly independent vectors, right?

And what do you mean by full rank?

Basically, your rank should be equal to n, Where

n is the number of states that you have.

Here n is 4, right?

So clearly, this guy has rank 2, not equal to 4,

and that's why this guy is uncontrollable. And in case you don't want to sit and,

you know, compute rank, etc, of all these things, you can even do this in Matlab.

And this is the code for it.