Trace is not connected with the rotation axis, we all have:tr(R)=1+2cos(θ)
All rotation matrices are orthogonal, multiplication of several rotation matrices are stll orthogonal:R−1=RT
1.6.Transformations Concatenation
Transformations can be treated as a series of matrix multiplications:
P′=M1M2M3...MnP
M=M1M2M3...Mn
⇒P′=MP
P′T=(M1M2M3...MnP)T
MT=MnTMn−1T...M1T
P′T=PTMT
1.7.Rigid body transformation
1.Only the position(translate transformation ) and direction(rotation transformation) change, it remains the geometry unchanged, that transformation is called rigid body transformation.
1.If a matrix is composed of one or several simple transformation, and the parameters are known, the inverse matrix can be multipled in order through the inverse parameters:
A example is :M=T(t)R(θ)⇒M−1R(−θ)T(−t)
2.If the matrix is orthogonal, then M−1=MT
3.If nothing is known: Accompanying matrix method, Cramer’s method, LU decomposition method, Gauss elimination method
Cramer’s method and Accompanying method have less “if”, we should consider at first.
II. 3D Rotation representations
1.Rotation Matrix
Rows/columns of matrix must be orthogonal: Unit length and orthogonal
Numerical errors cause a nonorthogonal matrix when a series of rotations apply
How to interpolate between matrices?
Interpolating the components of two matrices doesn’t maintain the orthonomality.
The generated matrix is not a rotation matrix.
See the Problem:
⎣⎡010−100001⎦⎤→⎣⎡0−10100001⎦⎤
The halfway matrix you get by linearly interpolating each entry is:
⎣⎡000000001⎦⎤
It is obviously that it is not a rotation matrix any more!
2.Fixed Angle
Ordered triple of rotations about fixed axes
Any triple can be used that doesn’t repeat an axis:
immediately, e.g., x-y-z is fine, so is x-y-x. But x-x-z is not.
Gimbal:
A gimbal is a mechanical device allowing the rotation of an object in multiple dimensions.
Gimbal Lock:
Gimbal lock occurs when two of the rotation aces align; e.g., x and y axes in the figure: Lost a degree of freedom; cannot rotate about x-axis.
For an orientation (0,90,0),
A slight change in the first value (+/−ϵ,90,0)
A slight change in the third value (0,90,+/−ϵ)
90-degree y-axis rotation essentially makes x-axis align with z-axis -> gimbal lock: From (0,90,0), the object can no longer be rotated about x-axis by a small change since orientation actually performed is (90,90+ϵ,90)
Interpolation Problem in Fixed Angle:
The rotation from (0,90,0) to (90,45,90) is a 45-degree x-axis rotation: Impossible because the first 90-degree y-axis rotation
Directly interpolating between (0,90,0) and (90,45,90) produces a halfway orientation (45,67.5,45): Desired halfway orientation is (90,22.5,90)
Conclusion for Fixed Angle Representation:
Compact
Fairly intuitive
Easy to work
But not the most desirable representation to use because gimal lock problem.
3.Euler Angle
Euler Amgle is an efficient way to make the camera or object rotate toward an given direction.
Ordered triple of rotations about local axes.
As with fixed angles, any triple can be used that doesn’t immediately repeat an axis, e.g., x-y-z is fine, so is x-y-x. But x-x-z is not.
Euler angle ordering is equivalent to reverse ordering in fixed angles: The Euler anghle representation has exactly the same advantages and disadvantages as those of the fixed angle representation.
Calculation:
Euler angle ordering is equivalent to reverse ordering in fixed angles.
For a Euler angle representation in x-y-z ordering:
Y-axis rotation: around the y-axis of the local, rotated coordinate system:Ry′(β)Rx(α)=Rx(α)Ry(β)Rx(−α)Rx(α)=Rx(α)Ry(β)
Trace is not connected with the rotation axis, we all have:tr(R)=1+2cos(θ)
All rotation matrices are orthogonal, multiplication of several rotation matrices are stll orthogonal:R−1=RT
1.6.Transformations Concatenation
Transformations can be treated as a series of matrix multiplications:
P′=M1M2M3...MnP
M=M1M2M3...Mn
⇒P′=MP
P′T=(M1M2M3...MnP)T
MT=MnTMn−1T...M1T
P′T=PTMT
1.7.Rigid body transformation
1.Only the position(translate transformation ) and direction(rotation transformation) change, it remains the geometry unchanged, that transformation is called rigid body transformation.
1.If a matrix is composed of one or several simple transformation, and the parameters are known, the inverse matrix can be multipled in order through the inverse parameters:
A example is :M=T(t)R(θ)⇒M−1R(−θ)T(−t)
2.If the matrix is orthogonal, then M−1=MT
3.If nothing is known: Accompanying matrix method, Cramer’s method, LU decomposition method, Gauss elimination method
Cramer’s method and Accompanying method have less “if”, we should consider at first.
II. 3D Rotation representations
1.Rotation Matrix
Rows/columns of matrix must be orthogonal: Unit length and orthogonal
Numerical errors cause a nonorthogonal matrix when a series of rotations apply
How to interpolate between matrices?
Interpolating the components of two matrices doesn’t maintain the orthonomality.
The generated matrix is not a rotation matrix.
See the Problem:
⎣⎡010−100001⎦⎤→⎣⎡0−10100001⎦⎤
The halfway matrix you get by linearly interpolating each entry is:
⎣⎡000000001⎦⎤
It is obviously that it is not a rotation matrix any more!
2.Fixed Angle
Ordered triple of rotations about fixed axes
Any triple can be used that doesn’t repeat an axis:
immediately, e.g., x-y-z is fine, so is x-y-x. But x-x-z is not.
Gimbal:
A gimbal is a mechanical device allowing the rotation of an object in multiple dimensions.
Gimbal Lock:
Gimbal lock occurs when two of the rotation aces align; e.g., x and y axes in the figure: Lost a degree of freedom; cannot rotate about x-axis.
For an orientation (0,90,0),
A slight change in the first value (+/−ϵ,90,0)
A slight change in the third value (0,90,+/−ϵ)
90-degree y-axis rotation essentially makes x-axis align with z-axis -> gimbal lock: From (0,90,0), the object can no longer be rotated about x-axis by a small change since orientation actually performed is (90,90+ϵ,90)
Interpolation Problem in Fixed Angle:
The rotation from (0,90,0) to (90,45,90) is a 45-degree x-axis rotation: Impossible because the first 90-degree y-axis rotation
Directly interpolating between (0,90,0) and (90,45,90) produces a halfway orientation (45,67.5,45): Desired halfway orientation is (90,22.5,90)
Conclusion for Fixed Angle Representation:
Compact
Fairly intuitive
Easy to work
But not the most desirable representation to use because gimal lock problem.
3.Euler Angle
Euler Amgle is an efficient way to make the camera or object rotate toward an given direction.
Ordered triple of rotations about local axes.
As with fixed angles, any triple can be used that doesn’t immediately repeat an axis, e.g., x-y-z is fine, so is x-y-x. But x-x-z is not.
Euler angle ordering is equivalent to reverse ordering in fixed angles: The Euler anghle representation has exactly the same advantages and disadvantages as those of the fixed angle representation.
Calculation:
Euler angle ordering is equivalent to reverse ordering in fixed angles.
For a Euler angle representation in x-y-z ordering:
Y-axis rotation: around the y-axis of the local, rotated coordinate system:Ry′(β)Rx(α)=Rx(α)Ry(β)Rx(−α)Rx(α)=Rx(α)Ry(β)
Welcome file If a function y = f ( x ) y=f(x) y = f ( x ) is too complicated for calculation or is even unknown, one way to approximate it is to first obtain its values y 0 = f ( x 0 ) , . . . , x n = f ( x n ) y_0=f(x_0),...,x_n=f(x_n) y 0 = f ( x 0 ) , ... , x n = f ( x n ) at a sequence of points x 0 , . . . , x n x_0,...,x_n x 0 , ... , x n , and then construct a relatively simple approximating function g ( x ) ≈ f ( x ) g(x)\approx f(x) g ( x ) ≈ f ( x ) . If g ( x ) g(x) g ( x ) satisfies that g ( x i ) = f ( x i ) g(x_i)=f(x_i) g ( x i ) = f ( x i ) for all i = 0 , . . . , n i=0,...,n i = 0 , ... , n , it is called the interpolating function of f ( x ) f(x) f ( x ) . The most commonly used interpolating functions are algebraic polynomials. Interpolation and the Lagrange Polynomial Find a polynomial of degree n n n , P n ( x ) = a 0 + a 1 x + . . . + a n x n P_n(x)=a_0+a_1x+...+a_nx^n P n ( x ) = a 0 + a 1 x + ... + a n x...
Welcome file Lecture 4: Keyframe interpolation and velocity control 动画中的运动感控制 : 运动的表示: 用数学方法来表示各类物体的运动 运动的控制和编辑: 给动画师提供能够表达他意图的方便、直观的控制工具 运动的生成: 计算每一帧所需的各种运动参数 Goal:再现物理世界的运动,超越物理世界的运行。 I.Interpolation between key frames 1. Parameters to be interpolated : Position of an object Scale of an object Orientation of an object Joint angle between two joints Color attribute of an object 2. Interpolation between frames is not trivial : Appropriate interpolation function Parameterization of the function Maintain the desired control of the interpolated values over time 3. Solution : Generate a space curve Distribute points evenly along curve Speed control: vary points 4. Interpolation v.s. Approximation : An interpolating spline in which the spline passes through the interior control points. An approximating spline in which only the endpoints are interpolated; the interior control points are used only to design th...