A) x, H = |x, B) y – ElmoMC Multi-Axis Motion Controller-Maestro Motion Control User Manual

Page 67: H= |y, C) x, X– x, Y – y, X = ( x – x, Y = (y, Dx + x∆y – x

Advertising
background image

Appendix A: Projection of a point on a
line defined by the end points

The line

L

is defined by its end points

P

1

(X

1

,Y

1

)

and

P

2

(X

2

,Y

2

).

Drop a perpendicular

from some point

(X

o

,Y

o

)

on the line

L

and find coordinates

(X

pr

, Y

pr

)

of the projection

point and the length of the perpendicular

h

.

a) X

1

= X

2

X

pr

= X

1

Y

pr

= Y

o

h = |X

o

– X

1

|

b) Y

2

= Y

1

X

pr

= X

o

Y

pr

= Y

1

h= |Y

o

– Y

1

|

c) X

1

≠ X

2

and

Y

2

≠ Y

1

Line equation

(X– X

1

)/(X

2

– X

1

) = (Y – Y

1

)/(Y

2

– Y

1

)

(a1.1)

That can be transformed into

(Y Y

1

)∆X = (XX

1

)∆Y

or

Y = (Y

1

dX + X∆Y – X

1

∆Y)/∆X = Y

1

+ k(X – X

1

)

(a1.2)

Where

k = ∆Y/∆X = (Y

2

– Y

1

)/(X

2

– X

1

)

An equation of the perpendicular dropped from

(Xo,Yo)

on

L

can be written in a form

(Y - Y

o

) = (-1/k)(X – X

o

) = q(X – X

o

)

(a1.3)

or

Y = Y

o

+ q(X – X

o

)

(a1.4)

Substituting (a1.4) into (a1.2) the results are

Yo + q(X – Xo) = Y

1

+ k(X – X

1

)

(a1.5)

That produces for

X

coordinate

X = (Y

o

– Y

1

+ kX

1

– qX

o

)/(k – q)

(a1.6)

Maestro

Software Manual

MAN-MLT(Ver. 2.0)

A-1

Advertising