what is the formula of the distance between a point and a line
d = sqrt((x1-x2)^2 + (y1-y2)^2 This is just pythagoras theorem, applied to a straight line.
hold on
you have a line, say \[y=2x+1\] and a point not on the line, say (3,8) and you want the distance right?
yes
or do you have as specific one you would like to do?
i have a calculus journal i have to do and it asks me the formula for a distance between a point and a line
because this is not that trivial
ooooooooooooooh you want to use calculus ok
so "distance" of course means "shortest distance" you can do it without calculus or you can use calculus. now if you want some sort of formula i guess we should call the line \[y=mx+b\] and the point \[(x_1,y_1)\] or something like that
ok and how to find the distance between those two?
ok first of all use the distance to find the point on the line closest to the point \[(x_1,y_1)\] the point is given and the line is given. the only variable is x and y
put \[d^2=(x-x_1)^2+(y-y_1)^2\]
you want to find x and y that make this a minimum. x and y being on the line y = mx +b
you mean like in vector?
so replace y by mx + b in the formula to get \[d^2(x)=(x-x_1)^2+(mx+b-y_1)^2\]
now you have a function of x, it is smallest where the derivative is 0, so take the derivative, set it = 0 and solve
remember that the variable is x, \[x_1,y_1,b\] are constants
@imranmeah if there is a snap way let me know. i would make the slopes perpendicular, but we are supposed to use calculus
\[\frac{\left|P_x\times n\right|}{|n|}\] this one?
thanks is there a specific formula. i googled it and i got a bunch of different formulas
not that one but it does have an absolute value in it
my understanding of the question was we have a line \[y=mx+b\] and a point \[(x_1,y_1)\] and we want to use calculus to find the distance between the point and the line
the derivative is \[2(x-x_1)+2(mx+b-y_1)\] by the chain rule. set this equal to zero, solve for x. you answer will have an \[x_1,y_1,m, b\] in it which is to be expected because you want a formula which will obviously depend on those 4 numbers
a quick bit of algebra tells me \[x=\frac{x_1+y_1-b}{m+1}\]
now that is not the formula for the distance, that is the x - value of the point on the line that gives the distance. the y value is what you get if you replace x by this mess and the distnance is what you get from the distance formula
ok thanks
Join our real-time social learning platform and learn together with your friends!