350 likes | 703 Views
Mathematics for Computer Graphics (Appendix A). 2001. 1. 10 Won-Ki Jeong. x. y. y. x. A-1. Coordinate Reference Frame. 2D Cartesian reference frame. 2D Polar Coordinate reference frame. 3D Cartesian reference frame. Right-handed v.s left-handed. Right-handed. Left-handed.
E N D
Mathematics for Computer Graphics(Appendix A) 2001. 1. 10 Won-Ki Jeong
x y y x A-1. Coordinate Reference Frame • 2D Cartesian reference frame
3D Cartesian reference frame • Right-handed v.s left-handed Right-handed Left-handed
3D curvilinear coordinate systems • General curvilinear reference frame • Orthogonal coordinate system • Each coordinate surfaces intersects at right angles
z axis constant : vertical cylinder : vertical plane containing z-axis : horizontal plane parallel to xy-plane y axis x axis Cylindrical-coordinate Transform to Cartesian coordinator
Spherical-coordinate z axis constant : sphere : vertical plane containing z-axis : cone with the apex at the origin y axis Transform to Cartesian coordinator x axis
steradian Solid angle • 3D Angle defined on a sphere(steradian) Steradian : Total solid angle :
A-2. Points & Vectors • Point • Position in some reference frame • Distance from the origin depends on the reference frame P y Frame B Frame A x
Magnitude : Direction : • Vector • Difference between two point positions • Properties : Magnitude & direction • Same properties within a single coordinate system • Magnitude is independent from coordinate frames
3D vector • Magnitude • Directional angle
Vector addition &scalar multiplication • Addition • Scalar multiplication
Commutative : Distributive : Orthogonal : Vector multiplication • Scalar product(inner product)
Noncommutative : Nonassociative : Distributive : Vector product(Cross product) Right-handed rule!
A-3. Basis vectors and the metric tensor • Basis of vector space • Linearly independent axis vectors • Orthonormal basis • Orthogonal : • Normalized : • Orthonormal = Orthogonal + Normalized • Orthonormal basis of 3D Cartesian reference frame
Metric tensor • Tensor • Generalization of a vector with rank & dim. that satisfy certain transformation properties • n-th rank with dim m : m-dimensional space which has n indices • Rank 0: scalar, rank 1: dim m vectorrank 2 : vector which has m2 component • Metric tensor • Definition : • The tensor for • Distance metric • Used as transformation equation • Component of differential vector operators (gradient, divergence, and curl)
If j = k otherwise Pythagorean theorem : For 3D Cartesian coordinate system : Example of metric tensor • Cartesian coordinate system • Polar coordinates
Column row A-4. Matrices • Rows & columns • Matrix multiplication Properties
Transpose & Determinant • Matrix transpose • Determinant • Large matrix A
Inverse of a matrix • Inverse matrix • Determinant is not 0 : Non-singular matrix • Elements of
Imaginary axis Real axis A-5. Complex numbers • Real + Imaginary part
Imaginary axis Real axis Polar form & Euler’s formula • Polar form • Euler’s formula
A-6. Quaternions • Higher dimension complex number • Addition, multiplication, magnitude, & inverse
Implicit form Explicit form A-7. Nonparameteric representation • Direct description in terms of the reference frame • Surface : or • Curve : • Useful in the given reference frame • Example (circle)
A-8. Parameteric representation • Use parameter domain • Curve • Ex. Circle • Surface • Ex. Spherical surface r : radius of the sphereu: latitudev: longitude
: matrix A with the kth column replaced with B A-9. Numerical methods • Solving sets of linear equation • Matrix form • Cramer’s rule • Adequate for a few variables
Gauss elimination • Elementary Row Operation • Multiply a row through by a nonzero constant • Interchange two rows • Add a multiple of one row to another row • Make row-echelon form by e.r.o • Row-echelon form • First nonzero number of each row is 1(leading 1) • Entire-zero-rows are grouped together at the bottom of the matrix • In any successive non-entire-zero rows, the leading 1 in the lower row occurs farther to the right than the leading 1 in the higher row
Gauss-Seidel method • Start with initial guess and repeatedly calculate successive approximations until their difference is small • Convergence condition • Each diagonal element of a matrix A has a magnitude greater than the sum of the magnitudes of the other elements across that row
Initial guess Finding roots of nonlinear equation • Object • Finding the solution of • Newton-Raphson algorithm • Iterative approximation • Fast, but it may be fail to converge
Bisection method • Convergence guaranteed
Evaluating integrals • Rectangle approximation • Polynomial approximation • Simpson’s rule
Given two random number r1 and r2 : • Monte Carlo method • For high-frequency oscillation function or multiple integrals • Use random positions : uniformly distributed : # of random points between f(x) and x-axis
Fitting curves to data sets • Least-squares algorithm • Fitting a function to a set of data points • Ex. 2D linear case Solve linear equation!