Error consideration
본문 바로가기
ComputerGraphics

Error consideration

by Midfall 2022. 10. 24.
320x100

2.1.8 Error consideration

Accumulated round-off error

Once the object space to world space transformation matrix has been formed, the object is transformed into world space by multiplying all of the object's object space points by the transformation matrix. When an object's position and orientation are animated, its point will be repeatedly transformed over time. One way to do this is to repeatedly modify the object's world space points. However this can lead to the accumulation of round-off errors. It is better to modify the transformation from object to world space and reapply the transformation to the object space points. To further transform an object that already has a transformation matrix, one simply has to form a transformation matrix and premultiply it by the xisting transformation matrix. However, round-off errors can also accumulate when one repeatedly modifies a transformation matrix. The best way is to build the transformation matrix each time it is to be applied.

 

An affine transformation can be viewed as a 3x3 rotation/submatrix. Most of error occurs because of the operations resulting from multiplying the x-,y- and z- coordinates of the point by the 3x3 submatrix. Consider the case of moon orbiting the earth. The assumption is that the center of the earth is at the origin, and the moon data are defined with the moon's center at (r,0,0). There are three approaches to animate the rotation of the moon. 

 

The first approach is to apply a delta z-axis transformation matrix to the moon's points, in which each delta represents the angle it moves in one frame time. Round-off errors will accumulate in the world space object points. Points that began as coplanar will no longer be coplanar. This is the problem especially in lineary interpolating values to render a surface. 

 

The second approach is to incrementally modify the transformation matrix that takes the object space points into the world space positions. In the example of moon, the transformation matrix is initialized with the z-axis transformation matrix. For each frame, a delta z-axis transformation matrix multiplies the current transformation matrix and then that resultant matrix is applied to the moon's object space points. Round-off error will accumulate in the transformation to the transformation matrix. Shearing effects will begin and angles will cease to preserved. While a square may begin to look like something other than a square, coplanarity will be preserved(a linear transformation that preserves planarity), so that rendering results will not be compromised.

 

The third approach is to add the delta value to an accumulating angle variable and then build the z-axis rotation matrix from that angle parameter. This would then be multiplied with the x-axis transformation matrix. In this case, any round-off error will accumulate in the angle variable so that, it may begin to deviate from what is desired. This may have unwanted effects, but the transformation matrix will not accumulate any errors itself. The transformation will always represent a valid transformation.

 

Orthonormalization

The rows of a matrix that represents a rigid transformation(Rotation, Translation and Reflection) are perpendicular to each other and are of unit length(orthonormal). If values in a rigid transformation matrix have accumulated errors, then the rows cease to be orthonormal and the matrix ceases(stops) to represent a rigid transformation. A rigid transformation matrix has an upper 3x3 submatrix with specific properties: the rows(columns) are unit vectors orthogonal to each other. A simple procedure to reformulate the transformation matrix is to take first row and normalize it. Take the second row, compute the cross-product of this row and the first row, normalize it and place it in the third row. Take the cross-product of the third row and first row, and put it in the second row. The errors has just been shifted around so that the error mayf be less noticeable.

 

If the transformation might contain a uniform scale, then take the length of one of the rows, or the average length of the three rows, make them equal to this length. If the transformation might include nonuniform scale, then the difference between shear and error accumulation cannot be determined. If it is known that nonuniform scale was applied before any rotation, then Gram-Schmidt Orthonormalization can be performed without the normalization step, to force orthogonality among the vectors. When all vectors have been processed, they are orthogonal to each other.

 

Consideration of scale

When constructing a large database, there may be such variations in the magnitude of various measures as to create precision problems. For example, you may require detail on the order of a fraction of an inch. The scale of values would range from 10^-1inches to 3.168*10^8inches. This exceeds the precision of 32-bit single-precision representation. Using double precision may increase storage space requirements and decrease the speed of the computation. Alternatively, subdividing the database into local data, and switching between these localized databases might provide an acceptable solution.

 

 

 

300x250

'ComputerGraphics' 카테고리의 다른 글

Quaternion representation  (0) 2022.10.27
Orientation representation  (0) 2022.10.26
Homogeneous coordinates and the transformation matrix  (0) 2022.10.23
Spaces and transformations  (0) 2022.10.18
Spaces and transformations  (0) 2022.10.18

댓글