H = homogeneous(R,P);
Returns the homogenous matrix [4,4] of a rotation matrix R[3,3] and position vector P[3]:
The homogeneous matrix gives a full coordinate transformation from one reference frame to another. It can be used for 3D dynamics.
R = [cos(alpha),-sin(alpha),0 ; sin(alpha),cos(alpha),0 ; ; 0,0,0];
P = [p1 ; p2 ; p3];
H = homogeneous(R,P);
R must always be of size[3,3] , P must have the size [3,1] and H must have size [4,4].