parametric line to equation

K.I.L.E.R

Retarded moron
Veteran
P = <2, 1>

m = 1 / 2

y = mx+c

y = 0.5 * 2 + 1 = 2

x = (y/m) - c = 2 / 0.5 - 1 = 3

x = 3
y = 2

Is this right?
 
I supposed that you are computing a line equation for slope = 1/2 and a point <2, 1>?

For y = mx + b (or c if you like), put in all we know (m = 1/2, x = 2, y = 1) we get 1 = 1/2 * 2 + b -> b = 0.
 
I see, you derived m from the vector.
Now you should use the c value to computer the correct x and y:

y = mx + c = 0.5x + 4

To get a parametric form, let x = 2t and put it into y = 0.5x + 4 to get y = t + 4. Therefore

x = 2t
y = 4 + t
 
The parametric form of a line means that for all real t, x and y lie on the line. It's the same as the equation form (y = mx + c) but the equation form is limited to non-vertical lines.

It's easy to derive a parametric form of a line: pick any point on the line p = (x0, y0), and take the line vector v = <a, b>, then the parametric form is

x = x0 + at
y = y0 + bt
 
Back
Top