-
Notifications
You must be signed in to change notification settings - Fork 164
/
from_T.mo
35 lines (33 loc) · 1.51 KB
/
from_T.mo
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
within Modelica.Mechanics.MultiBody.Frames;
function from_T "Return orientation object R from transformation matrix T"
extends Modelica.Icons.Function;
input Real T[3, 3]
"Transformation matrix to transform vector from frame 1 to frame 2 (v2=T*v1)";
input SI.AngularVelocity w[3]
"Angular velocity from frame 2 with respect to frame 1, resolved in frame 2 (skew(w)=T*der(transpose(T)))";
output Orientation R "Orientation object to rotate frame 1 into frame 2";
algorithm
R := Orientation(T=T,w= w);
annotation(Inline=true, Documentation(info="<html>
<h4>Syntax</h4>
<blockquote><pre>
R = Frames.<strong>from_T</strong>(T, w);
</pre></blockquote>
<h4>Description</h4>
<p>
This function returns an
<a href=\"modelica://Modelica.Mechanics.MultiBody.Frames.Orientation\">orientation object</a> R
assembled from a transformation matrix T and an angular velocity vector w.
Generally, the transformation matrix T can be gained using a function from the
<a href=\"modelica://Modelica.Mechanics.MultiBody.Frames.TransformationMatrices\">TransformationMatrices</a>
package.
</p>
<h4>See also</h4>
<p>
<a href=\"modelica://Modelica.Mechanics.MultiBody.Frames.to_T\">to_T</a>.
<a href=\"modelica://Modelica.Mechanics.MultiBody.Frames.from_T_inv\">from_T_inv</a>,
<a href=\"modelica://Modelica.Mechanics.MultiBody.Frames.TransformationMatrices.from_T\">TransformationMatrices.from_T</a>,
<a href=\"modelica://Modelica.Mechanics.MultiBody.Frames.Quaternions.from_T\">Quaternions.from_T</a>.
</p>
</html>"));
end from_T;