Pl ü cker Coordinate of a Line in 3-Space

Preview:

DESCRIPTION

Pl ü cker Coordinate of a Line in 3-Space. L. Q. P. O. Motivation. The other way of representing lines in 3-space is parametric equation We are interested in learning the aspects/features of Plucker coordinates that make life easier !. References. - PowerPoint PPT Presentation

Citation preview

Plücker Coordinate of a Line in 3-Space

Lines in 3-Space

• You know how to represent a 3-space line in parametric equations

Fall 2015 2

Q

P

L

O

RttQPt ,1

Motivation

• We are interested in learning the aspects/features of Plucker coordinates that make life easier!

3Fall 2015

4

References

• Plucker coordinate tutorial, K. Shoemake [rtnews]

• Plucker coordinates for the rest of us, L. Brits [flipcode]

• Plucker line coordinate, J. Erickson [cgafaq]

Fall 2015

5

Introduction

• A line in 3-space has four degree-of-freedom• Plucker coordinates are concise and efficient for

numerous chores• One special case of Grassmann coordinates

– Uniformly manage points, lines, planes and flats in spaces of any dimension.

– Can generate, intersect, … with simple equations.

Fall 2015

For a similar reason, a line in 2-space has two DOF’s

6

Mason’s Version

tqptx )(

qpq 0

Line in parametric form

Define

Plucker coordinate of the line (q, q0)

Six coordinate 4 DOFs:

]by [scale ,,

0

00

0

kqqqkqq

qq

p q

q0

•(q, q0): q0, q00: general line

•(q, 0): q0, q0=0: line through origin

•(0, 0): q=0, (q0=0): [not allowed]

O

Fall 2015

The following are from Shoemake’s note…

8

Summary 1/3

Fall 2015

9

Summary 2/3

Fall 2015

10

Summary 3/3

Fall 2015

11

Notations

• Upper case letter: a 3-vector U = (ux,uy,uz) • Vector U; homogeneous version (U:0)• Point P; homo version (P:1), (P:w)• Cross and dot product: PQ, U.V• Plane equation: ax+by+cz+dw=0

– [a:b:c:d] or [D:d] with D=(a,b,c)– [D:0] origin plane: plane containing origin

• Plucker coordinate: {U:V}• Colon “:” proclaims homogeneity

Fall 2015

12

Determinant DefinitionQ

P

L

O

1z

y

x

p

p

p

1z

y

x

q

q

q … row x

… row y

… row z

… row w

Make all possible determinants of pairs of rows

11xx qp

11yy qp

11zz qp

yy

xx

qp

qp

zz

yy

qp

qp

xx

zz

qp

qp

P–Q PQ

L={P-Q:PQ}L={P-Q:PQ}

Fall 2015

13

ExampleQ

P

L

O

P=(2,3,7), Q=(2,1,0). L = {U:V} = {0:2:7:-7:14:-4}.

Order does not matter

Q=(2,3,7), P=(2,1,0). L = {U:V} = {0:-2:-7:7:-14:4}

Identical lines: two lines are distinct (不同 ) IFF their Plucker coordinates are linearly independent(獨

立 )

identical

Fall 2015

14

Tangent-Normal Definition

PQ: {U:V} U = P–Q V = P×Q = (U+Q)×Q = U×Q

(U:0) direction of line[V:0] origin plane through L

Question: any pair of points P,Q gives the same {U:V}? Yes

{p.16}

L={U:UQ}L={U:UQ}

PQ

U

L

O

U×Q

Fall 2015

15

Example

x

y

z y

U=(1,0,-1)Q=(0,0,1)UQ = (0,-1,0)L={1:0:-1:0:-1:0}

If we reverse the tangent:U=(-1,0,1)Q=(0,0,1)UQ = (0,1,0)L={-1:0:1:0:1:0}… still get the same line(but different orientation)Fall 2015

16

Remark

P’=Q+kU

U’ = P’– Q = kUV’ = P’×Q = (Q+kU) ×Q = kU×Q

P’Q {kU:kV}

Q

P

P’

U

L

O

Moving P and/or Q scales U & V together!Similar to homogeneous coordinates

Moving P and/or Q scales U & V together!Similar to homogeneous coordinates

Fall 2015

17

Remarks• Six numbers in Plucker coordinate {U:V} are not

independent.– Line in R3 has 4 dof. : six variables, two equations: one from

homogeneity; one from U.V = 0

• Geometric interpretation {U:V}– U: line tangent (U0, by definition)– V: the normal of origin plane containing L (V=0 L

through origin)

• Identical lines: two lines are distinct IFF their Plucker coordinates are linearly independent

Ex: {0:-2:-7:7:-14:4} and {0:4:14:-14:28:-8} are the same (but different orientation); {2:1:0:0:0:0} is differentFall 2015

18

Exercise

x

y

zP

Q P=(1,0,0)Q=(0,1,0)

P=(0,1,0)Q=(1,0,0)

L={P-Q:PQ}L={U:UQ}

L={P-Q:PQ}L={U:UQ}

U=(1,-1,0)Q=(0,1,0)

U=(2,-2,0)Q=(0,1,0)

U=(-1,1,0)Q=(0,1,0)

Fall 2015

19

Distance to Origin

T: closest to origin (to be determined) Any Q on L: Q = T + sU

V = U×Q = U×(T+sU) =U×T||V|| = ||U|| ||T|| sin90 = ||U|| ||T||

T.T = (V.V) / (U.U)

V×U=(U×T)×U = (U.U)T

T=(V×U:U.U)

Q

T

U

L

O Squared distance:

Closest point:

Vector triple product

L={U:V}

Fall 2015

L={U:V}

20

Example

x

y

z y

U=(1,0,-1)Q=(0,0,1)UQ = (0,-1,0)L={1:0:-1:0:-1:0}

T=(V×U:U.U) = (1:0:1:2)= (1/2,0,1/2)Squared distance = (V.V)/(U.U) = 1/2

Fall 2015

Q (0,0,1)

z

x

21

Line as Intersection of Two Planes1

L

[E:e] [F:f]

P

Plane equation: ax + by + cz + d = 0 P = (x,y,z), point on L [E:e] E.P + e = 0 … (1) [F:f] F.P + f = 0 …. (2)

(1)f – (2)e = 0: f(E.P+e) – e(F.P+f) = 0 (fE – eF).P = 0fE-eF defines the normal of an origin plane through L

direction U = EF L = {EF: fE – eF}Fall 2015

O

22

Example

x

z

y

z = 0[0:0:1:0]

x = 1[1:0:0:-1]

E = [1:0:0:-1]F = [0:0:1:0]L = {EF:fE-eF} = {0:-1:0:0:0:1}

CheckP = (1,1,0), Q = (1,0,0)L = {P-Q:PQ} = {0:1:0:0:0:-1}

Q

P

Fall 2015

23

Line as Intersection of Two Planes2

• If both planes do not pass through origin, e0 and f0, we can normalize both planes to [E:1] and [F:1].

• The intersecting line then becomes {EF:E-F}

L

[E:1] [F:1]Q

P

L

O

{P-Q:PQ}

{EF:E-F}

Duality!Fall 2015

• [V:0] origin plane thru L

(V0)

• [UV:V.V] plane thru L [V:0]

24

Other Duality

• (U:0) direction of L• T=(VU:U.U)

point of L (U:0)

Q

T

U

L

O

O[V:0]

[UV:V.V]

Verify!(next page)P.18

L={U:V}

Fall 2015

25

Verify P.24R

O[V:0]

[UV:V.V]

L

Find intersection of [UV:V.V] & [V:0]

L={E F:fE-eF}= {(U V) V: -(V.V)V}

(U V) V = -U(V.V)+V(U.V) = -U(V.V)

L = {-U(V.V):-V(V.V)} = {U:V}

Fall 2015

26

Line-Plane Intersection1

• L{U:V} and plane [N:0]Points on {VN:0} = (VN:w)Intersection: the point on [UV:V.V]!

{U:V} [N:0] = (VN:U.N)

(U V).(V N)+w(V.V) = 0w(V.V) = (V U).(V N) = N.((V U) V)=N.(-(U.V)V+(V.V)U)=(V.V)(U.N)w = U.N

Triple product

Fall 2015

O[V:0]

[N:0]

L

[UV:V.V]

{VN:0} (p.24)

27

Line-Plane Intersection2

• L and plane [N:n]

O

[V:0]

[N:0]

L

{U:V} [N:n] = (VN–nU:U.N)

O

[V:0]

[N:0]

L

Derivation pending

[N:n]

Fall 2015

28

Example

x

y

z y

U=(1,0,-1)Q=(0,0,1)UQ = (0,-1,0)L={1:0:-1:0:-1:0}

Intersect with Z=2, [0:0:1:-2]VN–nU = (-1,0,0) – (-2)(1,0,-1) = (1,0,-2)U.N = (1,0,-1).(-1,0,0) = -1Intersection at (-1,0,2)!

Z = 2[0:0:1:-2]

Intersect with y = 0, [0:1:0:0](VN:U.N) = (0:0:0:0), overlapIntersect with y = 1, [0:1:0:-1](VN–nU:U.N) = (1:0:-1:0)Intersect at infinity

{U:V} [N:n] = (VN–nU:U.N)

Fall 2015

{U:V} and (P:w) [UP – wV:V.P]

29

Common Plane1

U = (0,0,1)V = UQ = (0,0,1) (0,1,0) = (-1,0,0)

(P:w) = (1:1:0:1)

[UP–wV:V.P] = [0:1:0:-1]

Derivation pending

x

y

z

Fall 2015

L={U

:V}

P

30

Common Plane2

{U:V} and (N:0) [UN:V.N]

U = (0,0,1)V = UQ = (-1,0,0)

N = (1,0,0) …(-1,0,0) get the same … (1,0,1) also get the same (N need not U)⊥

[UN:V.N] = [0:1:0:-1]

Derivation pending

x

y

z

Fall 2015

L={U

:V}

N

31

Generate Points on Line1

Useful for:

• Computing transformed Plucker coordinate (p.50)

• Line-in-plane testO

[V:0]

[N:0]

LUse {U:V} [N:0] = (VN:U.N)

U

NAny N will do, as long as U.N0{Take non-zero component of U}N

O

Also related: p. 18, 35L

Does not work for line with V=0(line through origin)Fall 2015

32

Example

As before: L = {U:V} = {0:0:1:-1:0:0}

Take N = (0,1,1)

{U:V} [N:0] = (VN:U.N) = (0:1:-1:1)x

y

z

Fall 2015

33

Line-in-Plane Test

Point-on-Plane Test [N:n] contain (P:w) IFF N.P+nw = 0

Is L in [1:1:0:0]? No

(1,1,0).(0,1,-1) + 0 0

Is L in [1:0:0:0]? Yes

(1,0,0).(0,1,-1) + 0 = 0

x

y

z

1. Generate two points on the line 2. Do the Point-on-Plane test

Fall 2015

34

Point-on-Line Test

x

y

z

N

N1

N2

N,N1,N2: three base vectorsChoose N according to nonzero component of UN1 and N2 are the other two axes

Check point-in-plane with [UN1:V.N1] and [UN2:V.N2](common plane, p.29)

U

1. Generate two independent planes

containing the line.

2. Perform point-on-plane tests twice

Fall 2015

35

Example

x

y

z

N

N1

N2

U

L = {0:0:1:-1:0:0}, P = (0:1:-2:1)N = (0,0,1), N1 = (0,1,0), N2 = (1,0,0)Plane1 [-1:0:0:0] (-1,0,0).(0,1,-2)+0 = 0Plane2 [0:1:0:-1] (0,1,0).(0,1,-2) - 1 = 0

P

Fall 2015

• Parametric equation of L• Weighted sum of (U:0)

and T=(VU:U.U)

Pnt(t) = (VU+tU:U.U)

36

Duality

• [Parametric form of planes through L]– Generate two planes as

page 33…

L = {0:0:1:-1:0:0}Pnt(t) = (0:-1:t:1)

x

y

z Fall 2015

37

Two Lines Can Be …

• Identical– Linearly dependent Plucker coordinates

• Coplanar: find the common plane– Intersecting: find intersection– Parallel: find distance

• Skewed: find distance, closest points

Fall 2015

Coplanarity Test(intersect)

• Two lines L1 {U1:V1}, L2 {U2:V2} are coplanar if

U1.V2+V1.U2 = 0

38

L1&U2: [U1U2:V1.U2]

L2 &U1: [U2U1:V2.U1]

Same plane!

L1

L2parallel lines

(U1U2=0) are automatically coplanar

Fall 2015

39

L1 & L2 Coplanar

• Intersecting point (non-parallel)– Find the common plane: [U1U2:V1.U2]

((V1.N)U2-(V2.N)U1-(V1.U2)N:(U1U2).N)

– Where N is unit basis vector, independent of U1 and U2, (U1U2).N ≠0)

• Parallel (distinct) lines (U1U2 = 0)Common plane:

– [(U1.N)V2-(U2.N)V1:(V1V2).N] with N.U10

L1: {U1:V1}L2: {U2:V2}

Fall 2015

Example

40

L1={1:1:0:0:0:1}L2={0:1:0:0:0:-1}Pick N = (0,0,1)((V1.N)U2-(V2.N)U1-(V1.U2)N:(U1U2).N)=(1:2:0:1)

L1={1:1:0:0:0:1}L2={2:2:0:0:0:-4}

Pick N = (1,0,0)[(U1.N)V2-(U2.N)V1:(V1V2).N]

=[0:0:-6:0]

Fall 2015

x

y

y

41

L1 & L2 Skewed

• Not coplanar IFF skewed

• Find distance

• Find pair of closet points

Fall 2015

42

Distance Computation in R3

221

221

221 zzyyxx 222

111

cba

dczbyax

222

21

cba

dd

  Point (x2:y2:z2:1)

Line {U:V} Plane [D:d]

Point (x1:y1:z1:1)

(1)

Line {U:V}  (2a): parallel

(2b): skewed

If no intersection,

generate a point on line & point-plane distance

Plane [D:d]   

Fall 2015

43

(1) Line-Point Distance

L

p

D

1. Generate 1 containing L & p as [D:d]2. Generate 2 containing L & D3. Compute distance from p to 2

1=[D:d]

2

Fall 2015

44

(2a) Parallel Line Distance

[D:d]

D U

1 2

L1 L2Find the common plane [D:d] Find 1 containing L1 and DFind 2 containing L2 and DFind distance between 1 & 2

D

Fall 2015

45

(2b) Skewed Line Distance

1

2

L1

L2

U1

U2

Generate 1 containing L1 and U2

Generate 2 containing L2 and U1

Find distance between 1 & 2

How to find the pair of points that are

closest?Fall 2015

46

Application

• Ray-polygon and ray-convex volume intersection

Fall 2015

47

Relative Position Between 2 Lines

Looking from tail of L1 …

Here, the lines are “oriented”!!{orientation defined by U}

Fall 2015

48

Example

x

y

zL1

L2L3

R

L1={1:0:0:0:0:0}L2={-1:1:0:0:0:-1}

L3={0:-1:0:0:0:0}

R={0:0:-1:1/3:-1/3:0} = {0:0:-3:1:-1:0}

R vs. L1: (0:0:-3).(0:0:0) + (1:-1:0).(1:0:0) = 1 > 0

R vs. L2: (0:0:-3).(0:0:-1) + (1:-1:0).(-1:1:0) = 1 > 0

P:(1/3,1/3,0)Q:(1/3,1/3,1)

R vs. L3: (0:0:-3).(0:0:0) + (1:-1:0).(0:-1:0) = 1 > 0

Note here the line is “oriented”; L and –L are not the same

Fall 2015

49

Example

x

y

zL1

L2L3

R

L1={1:0:0:0:0:0}L2={-1:1:0:0:0:-1}

L3={0:-1:0:0:0:0}

R={0:0:-1:1:-1:0}

R vs. L1: (0:0:-1).(0:0:0) + (1:-1:0).(1:0:0) = 1 > 0

R vs. L2: (0:0:-1).(0:0:-1) + (1:-1:0).(-1:1:0) = -1 < 0

P:(1,1,0)Q:(1,1,1)

R vs. L3: (0:0:-1).(0:0:0) + (1:-1:0).(0:-1:0) = 1 > 0Fall 2015

50

Discussion

• Plucker coordinate of transformed line– More efficient by computing the Plucker

coordinates of the transformed points (p.31)

Fall 2015

Extra

Vector Review

Fall 2015 52

kww

vvj

ww

vvi

ww

vv

www

vvv

kji

wv

21

21

31

31

32

32

321

321

sinwvwv

20cos

cos

vvvvv

wvwv

Vector triple product

Triple product

kwv :dependencylinear

53

Example

x

y

z

U=(1,0,-1)V=(0,-1,0)L={1:0:-1:0:-1:0}

Different normal gives different lineL’ = {1:0:-1: 0:-2:0}

Reverse normal gives different lineU=(1,0,-1)V=(0,1,0)L’={1:0:-1:0:1:0}

x

y

z Fall 2015

(because Q is different!)

IndexConstructors,

two points 11

tangent-normal 13

two planes 20

Distance (closest pt) to origin 18

Line-plane intersect25,26

Line-line intersect 38

Common plane

line, point 28

line, dir 29

Generate points on line 30, 35L

Parametric equation of line 35L

Parametric plane of line 35R

54

Line in plane30,32

Point in line 33

Point on plane 32

Line-line configuration37-40

Parallel (distance, common plane) 38

Intersect (point, common plane) 38

Skew 44

Distance (point-line-plane)41-44

Winding 45

Fall 2015

Recommended