Presentation is loading. Please wait.

Presentation is loading. Please wait.

Class 20 Curves and Surfaces

Similar presentations


Presentation on theme: "Class 20 Curves and Surfaces"— Presentation transcript:

1 Class 20 Curves and Surfaces
planar curves curves in 3 space meshes surfaces in 3 space swept surfaces

2 Chapter 10 curves in 2-space
plane curve: x = f(t) y = g(t) t∈[a,b] or (-∞, b], [a, ∞), (-∞, ∞)

3 curveDrawerMJB.cpp run endpoints number of intervals and interval size
y = x*x

4 curveDrawerMJB.cpp modifications
y=sin(x) x=t y=sin(t) pick good a and b pick good MAX and MIN

5 curveDrawerMJB.cpp modifications
circle x=cos(t) y=sin(t) pick good a and b pick good MAX and MIN

6 curveDrawerMJB.cpp modifications
astroid x=cos3(t) y=sin3(t) 0≤t≤2*PI pick good a and b pick good MAX and MIN Also superellipses, ...

7 Other parametrizations
Circle: x = r * (1 - t2) / (1 + t2) y = r * 2*t / (1 + t2) on (-∞, ∞) singularity: (-r,0) at t = ± ∞ Some benefits - computation. Book discusses handling this and other examples

8 Curves in 3 space 3DcurveDrawerMJB.cpp run discuss third parameter
x=f(t) y=g(t) z=h(t)

9 Surfaces polygon issues

10 Meshes good polygons meet at common edge, common vertex, or not at all
"sheet-like" near vertex

11 meshes and non-meshes

12 TRIANGLE_STRIP V0V1V2 V1V3V2 V2V3V4

13 Cylinder from a grid got to here

14 surfaceMJB.cpp run look at code fillVertexArray
//Make the approximating triangular mesh

15 computing a normal at a vertex https://www. khanacademy

16 cylinder.cpp run look at code note repeating vertices

17 Swept Surfaces the curve that sweeps is the profile curve
the path followed is the trajectory

18 Swept Surfaces What are the profile and trajectory?

19 torusSweepModMJB.cpp run look at different views
How do you get the equations?

20 P a point on the torus

21 P P' P'' O O' ϴ ϕ O is center of trajectory circle R is radius of trajectory circle

22 P P' P'' O O' ϴ ϕ P is point on torus O' is center of red profile circle ( on the xy-plane ) r is radius of profile circle

23 P P' P'' O O' ϴ ϕ ϴ is angle between x-axis and OO' ϕ is angle from OO' to O'P

24 P P' P'' O O' ϴ ϕ P' is the perpendicular projection of P onto OO' (so P' is on the xy plane)

25 P P' P'' O O' ϴ ϕ x coordinate of P is OP'' = OP' cos(ϴ)= (OO' + O'P') cos(ϴ)=

26 x coordinate of P is OP'' = OP' cos(ϴ)= (OO' + O'P') cos(ϴ)= (OO' + O'Pcos(ϕ)) cos(ϴ)= (R r cos(ϕ)) cos(ϴ)

27 Similarly for y : y coordinate of P: P'P" = OP'sin(ϴ)=
(OO'+O'P')sin(ϴ)= (OO' + O'Pcos(ϕ))sin(ϴ)= (R+rcos(ϕ))sin(ϴ)

28 and z: z coordinate of P: P'P = OP'sin(ϕ)=r sin(ϕ)


Download ppt "Class 20 Curves and Surfaces"

Similar presentations


Ads by Google