Computer Graphics Lecture 36 CURVES II Taqdees A. Siddiqi

Slides:



Advertisements
Similar presentations
5.1 Real Vector Spaces.
Advertisements

ESSENTIAL CALCULUS CH11 Partial derivatives
Integrals 5.
Autar Kaw Humberto Isaza
08/30/00 Dinesh Manocha, COMP258 Hermite Curves A mathematical representation as a link between the algebraic & geometric form Defined by specifying the.
Modeling with Polynomial Functions
Here is a preview of one type of problem we are going to solve using matrices. Solve this system of equations:
Introduction to Robotics Lecture II Alfred Bruckstein Yaniv Altshuler.
Linear Equations in Linear Algebra
5  Systems of Linear Equations: ✦ An Introduction ✦ Unique Solutions ✦ Underdetermined and Overdetermined Systems  Matrices  Multiplication of Matrices.
LIAL HORNSBY SCHNEIDER
Section 9.5: Equations of Lines and Planes
Math Dept, Faculty of Applied Science, HCM University of Technology
Systems and Matrices (Chapter5)
1 Preliminaries Precalculus Review I Precalculus Review II
Presentation by: H. Sarper
ME 1202: Linear Algebra & Ordinary Differential Equations (ODEs)
4.5 Solving Systems using Matrix Equations and Inverses.
Chapter 4.1 Solving Systems of Linear Equations in two variables.
LIAL HORNSBY SCHNEIDER
1 1.5 © 2016 Pearson Education, Inc. Linear Equations in Linear Algebra SOLUTION SETS OF LINEAR SYSTEMS.
1 1.3 © 2012 Pearson Education, Inc. Linear Equations in Linear Algebra VECTOR EQUATIONS.
4-5 Matrix Inverses and Solving Systems Warm Up Lesson Presentation
Objectives Determine whether a matrix has an inverse.
Sheng-Fang Huang. 4.0 Basics of Matrices and Vectors Most of our linear systems will consist of two ODEs in two unknown functions y 1 (t), y 2 (t),
Linear Systems and Matrices
Chapter 5 Eigenvalues and Eigenvectors 大葉大學 資訊工程系 黃鈴玲 Linear Algebra.
Vectors Addition is commutative (vi) If vector u is multiplied by a scalar k, then the product ku is a vector in the same direction as u but k times the.
Chapter 8 Integration Techniques. 8.1 Integration by Parts.
College Algebra Sixth Edition James Stewart Lothar Redlin Saleem Watson.
11/6/ :55 Graphics II Introduction to Parametric Curves and Surfaces Session 2.
Arab Open University Faculty of Computer Studies M132: Linear Algebra
PreCalculus Section 2.6 Solve polynomial equations by factoring and the Rational Roots Theorem. Solve by factoring: x 3 + 5x 2 – 4x – 20 = 0 x 6 – x 3.
TH EDITION LIAL HORNSBY SCHNEIDER COLLEGE ALGEBRA.
Gateway Quiz Reminders: The next Gateway will be given in class next week (check your course calendar.) Before then, each student who did not score 8/8.
Aims: To understand what a polynomial is To be able to add and subtract polynomials To be able to multiply polynomials Polynomials/Factorisation Lesson.
Section 6.2 Solving Linear Equations Math in Our World.
Algebra 2cc Section 2.10 Identify and evaluate polynomials A polynomial function is an expression in the form: f(x) = ax n + bx n-1 + cx n-2 + … dx + e.
SAT/ACT MATH UNIT 10 Equation with More Than One Variable.
College Algebra Chapter 6 Matrices and Determinants and Applications
7.3 Linear Systems of Equations. Gauss Elimination
ISHIK UNIVERSITY FACULTY OF EDUCATION Mathematics Education Department
Linear homogeneous ODEn with constant coefficients
Computer Graphics Lecture 38
Copyright © Cengage Learning. All rights reserved.
5 Systems of Linear Equations and Matrices
Linear Differential Equations
We will be looking for a solution to the system of linear differential equations with constant coefficients.
Computer Graphics Lecture 37
Gateway Quiz Reminders:
Systems of Linear Equations
Administrivia Syllabus and other course information posted on the internet: links on blackboard & at Check assignment sheet for reading.
COMP 175: Computer Graphics February 9, 2016
Matrix Algebra.
Matrix Algebra.
Computer Graphics Lecture 20
Use Inverse Matrices to Solve Linear Systems
Linear Equations in Linear Algebra
Systems of Equations and Inequalities
Systems of Linear Equations
Copyright © Cengage Learning. All rights reserved.
6 Systems of Linear Equations and Matrices
Linear Equations in Linear Algebra
Matrix Algebra.
Systems of Linear Equations
Eigenvalues and Eigenvectors
Linear Equations in Linear Algebra
Matrix Algebra THE INVERSE OF A MATRIX © 2012 Pearson Education, Inc.
Solving Linear Systems of Equations - Inverse Matrix
Presentation transcript:

Computer Graphics Lecture 36 CURVES II Taqdees A. Siddiqi cs602@vu.edu.pk

CURVES II Taqdees A. Siddiqi cs602@vu.edu.pk

RECAP of last lecture: Parametric Equations of a Curve

A parametric curve is one whose defining equations are given in terms of a single, common, independent variable called the parametric variable.

for example, x(u) = au2 + bu + c, and similarly for y(u) and z(u). It is important to understand that each of these is an independent expression

Each point on a curve is defined by a vector p (figure 1). The components of this vector are x(u), y(u), and z(u). we express this as

which says that the vector p is a function of the parametric variable u.

There is a lot of information in equation 2 There is a lot of information in equation 2. when we expand it into component form, it becomes

define each component by a single, common parametric variable, and make sure that each point on the curve corresponds to a unique value of the parametric variable.

Plane Curves

To define plane curves, we use parametric functions that are second-degree polynomials:

where the a, b, and c terms are constant coefficients. We can combine x(u), y(u), z(u), and their respective coefficients into an equivalent, more concise, vector equation:

We allow the parametric variable to take on values only in the interval

To one of the end points we assign u = 0, and to the other u = 1 To one of the end points we assign u = 0, and to the other u = 1. To the intermediate point, we arbitrarily assign u = 0.5. We can write these points as

P0 = [x0 y0 z0] P0.5 = [x0.5 y0.5 z0.5] …(6) P1 = [x1 y1 z1]

x0 = cx x0.5 = 0.25ax + 0.5bx + cx …(7) x1 = ax + bx + cx with similar equations for y, and z.

Figure 2: A plane curve defined by three points

Next we solve these three equations in three unknowns for ax, bx, and cx, finding ax = 2x0 - 4x0.5 + 2x1 bx = -3x0 + 4x0.5 + x1 …(8) cx = x0

Substituting this result in to equation 4 yields x(u) = (2x0 - 4x0.5 + 2x1 ) u2 + (-3x0 + 4x0.5 - x1) u + x0 …(9)

Again, there are equivalent expressions for y(u) and z(u). We rewrite equation 9 as follows:

x(u) = (2u2 – 3u + 1) x0 + (-4u2 + 4u)x0.5 + (2u2 – u) x1 …(10)

P(u) = (2u2 – 3u + 1) P0 + (-4u2 + 4u)P0.5 + (2u2 – u) P1 …(11)

Equation 5 is the algebraic form and equation 11 is the geometric form Equation 5 is the algebraic form and equation 11 is the geometric form. Each of these equations can be written more compactly with matrices

So now we rewrite equation 5 using the following substitutions:

And finally we obtain

Remember that A is actually a matrix of vectors, so that

The nine terms on the right are called the algebraic coefficients. Next, we convert equation 11 into matrix form. The right-hand side looks like the product of two matrices

and This means that

Using the following substitutions

and

This is the matrix version of the geometric form. Because it is the same curve in algebraic form, p(u)=UA, or geometric form, p(u)=FP, we can write

The F matrix is itself the product of two other matrices

The matrix on the left we recognize as U, and we can denote the other matrix as

This means that

Using this we substitute appropriately to find

Pre-multiplying each side of this equation by 1/U yields

Or

Space Curves

A space curve is not confined to a plane A space curve is not confined to a plane. It is free to twist through space.

To define a space curve we must use parametric functions that are cubic polynomials. For x(u) we write: Equation (1)

we combine the x(u), y(u) and z(u) expressions into a single vector equation :

If a = 0, then his equation is identical to Equation discussed in plane curves

To define a specific curve in space, we use the same approach as we did for a plane curve. This time, though, there are 12 coefficients to be determined

We specify four points through which we want the curve to pass, which provides all the information we need to determine a, b, c, and d. Which four points?

we can have the four points we need: Points at

it turns out to be advantageous to use two intermediate points that we assign parametric values of

So we now have the four points we need. x y z P1 P1/3 P0 P2/3

which we can rewrite as the more convenient p1, p2, p3, and p4 (Figure 1).

Substituting each of the values of the parametric variable into Equation 1, we obtain the following four equations in four unknowns:

Equation (3)

Now we can express ax, bx, cx and dx in terms of x1, x2, x3 and x4 Now we can express ax, bx, cx and dx in terms of x1, x2, x3 and x4. After doing the necessary algebra, we obtain

Equation (4)

We substitute these results into Equation 1, producing

Equation (5)

Rewriting Equation 5 as follows:

Using equivalent expressions for y(u) and z(u), we can summarize them with a single vector equation:

Equation (7)

This means that, given four point assigned successive values of u (in this case at u=0, 1/3, 2/3 & 1), equation 7 produces a curve that starts at p1, passes through p2 and p3, and ends at p4.

Now let’s take one more step towards a more compact notation Now let’s take one more step towards a more compact notation. Using the four parametric functions appearing in Equation 7, we define a new matrix, where

Equation (8)

And then define a matrix P containing the control points, so that Equation (9)

The matrix G is the product of two other matrices, U and N: Equation (10)

Where And Equation (11)

(Note that N is another example of a basis transformation matrix.) Now we let

Equation (12)

Using matrices, Equation 2 becomes

To convert the information in the A matrix into that required for the P matrix, we do some simple matrix algebra, using Equations 9, 10 and 13. First we have

And then Equation (14) And then Equation (15)

Or more simply Equation (16)

Computer Graphics Lecture 36