Neat Stuff from Vector Calculus & Related Subjects Chris Hecker definition six, inc. & Maxis.

Slides:



Advertisements
Similar presentations
Chapter 6 Matrix Algebra.
Advertisements

Common Variable Types in Elasticity
Common Variable Types in Elasticity
8.2 Kernel And Range.
3D Geometry for Computer Graphics
Rigid Body Dynamics Jim Van Verth
1 A camera is modeled as a map from a space pt (X,Y,Z) to a pixel (u,v) by ‘homogeneous coordinates’ have been used to ‘treat’ translations ‘multiplicatively’
Linear Algebra.
Shivkumar Kalyanaraman Rensselaer Polytechnic Institute 1 : “shiv rpi” Linear Algebra A gentle introduction Linear Algebra has become as basic and as applicable.
3D Geometry for Computer Graphics. 2 The plan today Least squares approach  General / Polynomial fitting  Linear systems of equations  Local polynomial.
Chapter 4.1 Mathematical Concepts. 2 Applied Trigonometry Trigonometric functions Defined using right triangle  x y h.
Now Playing: My Mathematical Mind Spoon From Gimme Fiction Released May 10, 2005.
CSCE 590E Spring 2007 Basic Math By Jijun Tang. Applied Trigonometry Trigonometric functions  Defined using right triangle  x y h.
Ch 7.2: Review of Matrices For theoretical and computation reasons, we review results of matrix theory in this section and the next. A matrix A is an m.
3D Geometry for Computer Graphics
Chapter 1 Vector analysis
MOHAMMAD IMRAN DEPARTMENT OF APPLIED SCIENCES JAHANGIRABAD EDUCATIONAL GROUP OF INSTITUTES.
資訊科學數學11 : Linear Equation and Matrices
Last lecture summary Fundamental system in linear algebra : system of linear equations Ax = b. nice case – n equations, n unknowns matrix notation row.
Week 4 - Monday.  What did we talk about last time?  Vectors.
ME751 Advanced Computational Multibody Dynamics Introduction January 21, 2010 Dan Negrut University of Wisconsin, Madison © Dan Negrut, 2010 ME751, UW-Madison.
ME451 Kinematics and Dynamics of Machine Systems Review of Matrix Algebra – 2.2 Review of Elements of Calculus – 2.5 Vel. and Acc. of a point fixed in.
2IV60 Computer Graphics Basic Math for CG
Geometric Intuition Randy Gaul. Vectors, Points and Basis Matrices Rotation Matrices Dot product and how it’s useful Cross product and how it’s useful.
Mathematical Fundamentals
Eigenvectors and Eigenvalues
Chapter 10 Review: Matrix Algebra
Compiled By Raj G. Tiwari
Game Physics – Part IV Moving to 3D
Graphics CSE 581 – Interactive Computer Graphics Mathematics for Computer Graphics CSE 581 – Roger Crawfis (slides developed from Korea University slides)
Sundermeyer MAR 550 Spring Laboratory in Oceanography: Data and Methods MAR550, Spring 2013 Miles A. Sundermeyer Linear Algebra & Calculus Review.
6.837 Linear Algebra Review Patrick Nichols Thursday, September 18, 2003.
ECON 1150 Matrix Operations Special Matrices
Patrick Nichols Thursday, September 18, Linear Algebra Review.
Functions of Several Variables Local Linear Approximation.
Mathematics for Computer Graphics (Appendix A) Won-Ki Jeong.
Intro to 3D Models Angel Angel: Interactive Computer Graphics5E © Addison-Wesley
Review of Matrices Or A Fast Introduction.
6.837 Linear Algebra Review Patrick Nichols Thursday, September 18, 2003.
Shivkumar Kalyanaraman Rensselaer Polytechnic Institute 1 : “shiv rpi” Linear Algebra A gentle introduction Linear Algebra has become as basic and as applicable.
Mathematics for Graphics. 1 Objectives Introduce the elements of geometry  Scalars  Vectors  Points Develop mathematical operations among them in a.
Statistics and Linear Algebra (the real thing). Vector A vector is a rectangular arrangement of number in several rows and one column. A vector is denoted.
Linear Algebra 1.Basic concepts 2.Matrix operations.
Advanced Computer Graphics Rigid Body Simulation Spring 2002 Professor Brogan.
Background Mathematics Aaron Bloomfield CS 445: Introduction to Graphics Fall 2006.
Fundamentals of Engineering Analysis
Introduction to Linear Algebra Mark Goldman Emily Mackevicius.
UW EXTENSION CERTIFICATE PROGRAM IN GAME DEVELOPMENT 2 ND QUARTER: ADVANCED GRAPHICS Math Review.
Review of Linear Algebra Optimization 1/16/08 Recitation Joseph Bradley.
Algebra Matrix Operations. Definition Matrix-A rectangular arrangement of numbers in rows and columns Dimensions- number of rows then columns Entries-
Basic Theory (for curve 01). 1.1 Points and Vectors  Real life methods for constructing curves and surfaces often start with points and vectors, which.
Computer Graphics I, Fall 2010 Geometry.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
Computer Graphics Mathematical Fundamentals Lecture 10 Taqdees A. Siddiqi
Linear Algebra Review Tuesday, September 7, 2010.
3D Ojbects: Transformations and Modeling. Matrix Operations Matrices have dimensions: Vectors can be thought of as matrices: v=[2,3,4,1] is a 1x4 matrix.
Math Fundamentals Maths revisit.
Linear Algebra Lecture 2.
Linear independence and matrix rank
Systems of First Order Linear Equations
Lecture 03: Linear Algebra
Joshua Barczak CMSC 435 UMBC
COMP 175: Computer Graphics February 9, 2016
CSE 541 – Numerical Methods
Maths for Signals and Systems Linear Algebra in Engineering Lecture 6, Friday 21st October 2016 DR TANIA STATHAKI READER (ASSOCIATE PROFFESOR) IN SIGNAL.
Linear Algebra A gentle introduction
Game Programming Algorithms and Techniques
Physics 319 Classical Mechanics
Presentation transcript:

Neat Stuff from Vector Calculus & Related Subjects Chris Hecker definition six, inc. & Maxis

Related Subjects vector calculus scalar calculus linear algebra differential geometry classical mechanics, dynamics optimization & constraints differential & integral calculus

Intro & Prerequisites this is a total hodge-podge, not a gentle introduction –lack of rationale for caring about this stuff, trust me? :) stuff that I found non-intuitive or hard to figure out tour of fairly basic examples building on themselves to get firm grounding and intuition in calculus concepts for the kinds of math games do –touch on lots of different areas during tour, many sidestreets comfortable with algebra, linear algebra need to understand scalar calc, at least at the plugnchug level of differentiating functions –f(x) = ax 2 +bx+c f(x) = 2ax + b

a function maps values from the domain to the range uniquely –can be multivalued in range, but not domain What is a Function?

derivative is another function that maps changes in the domain to changes in the range, normalized What is a Derivative? y x

the key insight of calculus: the change is so small that you can ignore it anytime its multiplied by itself...so, you can treat any continuous function as linear if youre zoomed in far enough (to 1 st order) –continuity keeps us from dividing by zero –normalization makes the numbers finite Derivatives are Linear x0x0 x0x0 boom!

Random but Nifty Example of Ignoring Infinitessimals (nothing up my sleeve!) prove infinitessimal rotations in 3D are vectors (add, commute, etc.) –angular velocity is a vector, cross product differentiates rotating vectors infinitessimal rotations are vectors: 3x3 skew symmetric matrices are isomorphic to vectors angular velocity differentiates with cross product: finite rotation: infinitessimal rotation: infinitessimal rotations add and commute:

Scalar Derivatives: a line how does y (or f(x)) change for a change in x? –for lines, the change (derivative) is constant everywhere –drawn as red vector, but actually a scalar, slope a 1

Scalar Derivatives: a curve for curves, the derivative is position dependent –derivative is a function itself, mapping change in domain to change in range –both direction and magnitude, but still a scalar

vectors are columns of numbers in this talk, not rows we right-multiply matrices by column vectors: v = Mv matrix & vector ops fit together nicely keeping the shapes right is the key to sanity with vector calc m by n * n by p = m by p this is why v=vM makes no sense for column vectors –either youre using row vectors, or youre confused –either way, youre in for some pain when trying to do real math because all math books use columns for vectors and rows are special early computer graphics books got this backwards, and hosed everybody The Shape of Matrix Operations a·b = c = a T b = c Ab=c m n n p AB=C

Shape of Derivatives df needs to accept a domain linearly (ie. right-multiplied vector or scalar) to produce a range scalar valued function of scalar –y=f(x) dy =dfdx vector valued function of scalar –v=f(t) dv = dfdt scalar valued function of vector –z=f(x,y) vector valued function of vector –p=f(u,v) d d dd df

Shape of Derivatives (cont.) scalar valued function of vector: expands to row vector –the resulting range value depends on all the domain values –the differential needs a slot for a delta/change in each domain dimension...so it must be a row vector, theres no T or · –z=f(x,y) –dz=dfdx vector valued function of vector: expands to matrix –p=f(u,v) df = d dz = dfdx = d dp = dfdx = d

for a change in the parameter (domain), how does the function (range) change? –in this case, differential is a vector Derivatives: a parametric function a vector function of a scalar

Derivatives: a scalar function of a vector height field differential is not in range of function row vector column vector

Derivatives: a scalar function of a vector view height field as implicit surface in 3d –write g(x,y,z) > 0 above surface –differential is surface normal (not unit)

Derivatives: a scalar function of a vector example plane

Derivatives: a scalar function of a vector example sphere

A Surface Normal is Not a Vector! this is why you need to keep shapes distinct vector is a difference between two points normal is really a mapping from a vector to a scalar a b n v points &vectors transform like this:normals transform like this:

Normals and Vectors Example scaling an ellipse x values for y=0

Derivative of Vector Mappings barycentric coordinates in 2D triangle –vector function of a vector –if square, can invert Jacobian to find du,dv given dp –function is linear in this case, but works generally –determinant of Jacobian is how areas distort under function e1e1 e2e2 p0p0 p1p1 p2p2 p Jacobian matrix

Barycentric Coordinates in 3D Triangle now jacobian is 3x2 –can still find du,dv from dp with least squares e1e1 e2e2 p0p0 p1p1 p2p2 p same as projecting dp down into triangle

Implicit Functions equalities (constraints) subtract off DOFs explicit to implicit is easy: z = f(x,y) g(x,y,z) = z – f(x,y) =0 implicit to explicit is hard: f(x,y) = 0 y = f(x) solving nonlinear equations, sometimes multiple or no solutions but, inverting it differentially is easy because of linearization: shape/rank of jacobian will tell you how constrained you are as well f(x,y) = 0

Product Rule for Vector Derivatives for scalar multiplication: differential of a scalar function of a scalar is a scalar

Product Rule for Vector Derivatives for scalar multiplication: differential of a scalar function of a scalar is a scalar for dot product its a little wackier if vectors in dot are functions of scalars, its the same

Product Rule for Vector Derivatives for scalar multiplication: differential of a scalar function of a scalar is a scalar for dot product its a little wackier if vectors in dot are functions of scalars, its the same if vectors in dot are functions of vectors, need to watch shape! –we know result must be row: d

Product Rule for Vector Derivatives for scalar multiplication: differential of a scalar function of a scalar is a scalar for dot product its a little wackier if vectors in dot are functions of scalars, its the same if vectors in dot are functions of vectors, need to watch shape! –we know result must be row: d d d ??? use transpose picture to reason about it:

Product Rule for Vector Derivatives for scalar multiplication: differential of a scalar function of a scalar is a scalar for dot product its a little wackier if vectors in dot are functions of scalars, its the same if vectors in dot are functions of vectors, need to watch shape! –we know result must be row: d d d ??? dont want to use tensors, so we pull a fast one with the commutativity of dot (a·b=b·a) d d use transpose picture to reason about it:

Dot Product Derivative Example derivative of squared length of vector p q r dp makes intuitive sense: if dp is orthogonal, length doesnt change

Cross Product Works the Same Way if cross is a vector function of vectors... result must be a matrix use the skew symmetric picture of cross product d d ??? same problem with tensors, so we pull the same (skew-)commutativity trick

Cross Product Derivative Example differentiate a cross product of moving vector with constant vector n r dr c dc again, makes intuitive sense: dc changes orthogonally to dr changes

References Advanced Calculus of Several Variables –Edwards, Dover Calculus and Analytic Geometry –Thomas & Finney Classical Mechanics –Goldstein