# rigid3d

3-D rigid geometric transformation

## Description

A rigid3d object encapsulates a 3-D rigid transformation.

## Creation

### Description

example

tform = rigid3d creates a default rigid3d object that corresponds to an identity transformation.

tform = rigid3d(t) creates a rigid3d object based on a specified forward rigid transformation matrix, t. The t input sets the T property.

tform = rigid3d(rot,trans) creates a rigid3d object based on the rotation, rot, and translation, trans, components of the transformation. rot sets the Rotation property. trans sets the Translation property.

## Properties

expand all

Forward rigid transformation, specified as a 4-by-4 floating point matrix. This matrix must be a homogeneous transformation matrix that satisfies the post-multiply convention given by:

$\left[\begin{array}{cccc}x& y& z& 1\end{array}\right]=\left[\begin{array}{cccc}u& v& w& 1\end{array}\right]*T$

T has the form

$\begin{array}{ccccc}\left[{r}_{11}& {r}_{12}& {r}_{13}& 0;& ...\\ {r}_{21}& {r}_{22}& {r}_{23}& 0;& ...\\ {r}_{31}& {r}_{32}& {r}_{33}& 0;& ...\\ 0& 0& 0& 1\right];& \end{array}$

Dimensionality of the geometric transformation, specified as a positive integer.

Rotation component of the transformation, specified as a 3-by-3 floating-point matrix. This rotation matrix satisfies the post-multiply convention given by

$\left[\begin{array}{ccc}x& y& z\end{array}\right]=\left[\begin{array}{ccc}u& v& w\end{array}\right]*R$

Translation component of the transformation, specified as a three-element row vector of floating-point values. This translation vector satisfies the convention given by

$\left[\begin{array}{ccc}x& y& z\end{array}\right]=\left[\begin{array}{ccc}u& v& w\end{array}\right]+t$

## Object Functions

 invert Invert geometric transformation outputLimits Find output spatial limits given input spatial limits transformPointsForward Apply forward geometric transformation transformPointsInverse Apply inverse geometric transformation

## Examples

collapse all

Specify an angle in degrees. Set the rotation and translation components of the transformation.

theta = 30; % degrees
rot = [ cosd(theta) sind(theta) 0; ...
-sind(theta) cosd(theta) 0; ...
0           0  1];
trans = [2 3 4];
tform = rigid3d(rot,trans)
tform =
rigid3d with properties:

Rotation: [3x3 double]
Translation: [2 3 4]