As we have said before, while the rotation mattresses are easy to implement and manipulate, they contain
nine elements that only three of them are independent.
This is quite initiative as a rigid body possesses at most three rotational degrees of freedom in 3D.
This means that we can describe the orientation of a body in 3D using only three independent quantities.
So in this lesson, we will try to observe such kind of representations of rotations that uses only
three independent quantities.
Let's start with a little angled representation of rotation.
This is one of the most common method of representing a rotation.
Let's assume that we have a fixed frame of zero and the rotated frame of one.
We can describe the orientation of frame or one with respect to frame, or zero using three successive
rotations about current frame.
First, we rotate all zero above the z axis by the angle C.
Then we rotate the newly obtained frame by angle theta around the current y axis.
Find the larvae, rotate the frame B around the current that axis by angle of C and get our desired
frame of four one.
As you can see, we can specify in the relative orientation by only three subsequent rotations.
The angles of Feed, Peter and C are called Aler angles.
Now we will try to describe these subsequent rotations using rotation mattresses, which will help us
to deduce Aler angles.
Before doing that, I would like to mention that the subsequent rotations are about the current frame,
so the rotation mattresses will be just multiplied.
Let's multiply subsequent rotation mattresses in order to get the resultant rotation.
This is the resultant rotation matrix that we have got from multiplication.
This matrix is called that.
Was it a lower angle transformation.
The key problem is how we can get your angles from this rotation matrix.
Let's copy the metrics here again in order to find a solution to our problem.
We will analyze two cases for the first case.
We will suppose that not both of R1 three and R2 three are zero.
By this assumption, we can deduce that since that is not zero.
And so both of our three one or three two are also not zero, as since data is not zero, we can deduce
that R3 three is not plus or minus one because it can happen only when it goes to zero or PI.
So we can read that customers to equals two or three three.
And since data equals the plus minus square root of one minus R3 three squared after we obtain cosine
data and since Theta, we can easily get it up by using a to function.
If you don't know what is attached to function, then don't worry for now, except accept it as an inverse
of tangent or act tangent.
In order to get theta on the next lesson, I will briefly touched on this function.
So let's continue.
As you can see, we have two solutions for the Theta.
If we take the first solution for Theta, then sign Theta is greater than zero and we can get fit and
see using below formula.
It's not for you to find the given values in the formula inside the Matrix in order to understand how
we get these formulas for five feet and see if it will take on the second from you.
But it is important for you to grasp the concept anyway.
However, if we take the second solution for the T to, then sine teeter will be less than zero and
we will find below solutions for fee and see angles.
So we have two solutions to our problem because of the sine difference of Peter in terms of the second
case, if both are ones three and R2 three are zero, then sine teeter must be zero, which means that
it can be zero or point.
This also means that R3 three is plus minus one because our three three is cosine of theta.
Also, our three one and our three two are also zero because they contain contains sine of TITA.
Then our rotation matters becomes like that if we accept our three three as plus one.
Then the TITA is zero and sine theta is also zero.
So we get below solution four feet and see, as you can see, we can only have a solution for the sum
of these angles.
This means that we can have infinitely many solutions for feet and see how or by convention we can take
a zero.
If we accept our three three as minus one, then Peter is PI and Sun is also zero.
Then we get solution for the subtraction of B and C.
This also means that we can have infinitely many solutions for feet and C.
Let's go to another way of representation of rotation.
This representation is called roll pitch your angles.
And if you have done even a bit of robotics or mechanics, I am sure that you have heard these terms.
This method is similar to the earlier angles representation, except the rotation on rotations are not
about the current frame, but fixed frame.
So we will use pre multiplication of rotation mattresses to describe the final rotation after doing
some matrix algebra.
We can get the final result.
You can get the roll pitch and your angles from this mattress by following the same methodology as we
have done for or angles.
Before finishing this lesson, I would like to note that in general, we don't do all these calculations.
These are just the theoretical concept which will help you to grasp the other concepts more easily and
deeply instead of just writing a code without knowing anything.
These procedures have been applied by libraries and given as readily when we called our robots.
Don't worry, we will apply these concepts during our practical lessons and you will see what I mean.
See you on the next lesson.