If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

# Writing equations of perpendicular lines

Given line A and point P, Sal finds the equation of the line perpendicular to A that passes through P. Created by Sal Khan and Monterey Institute for Technology and Education.

## Want to join the conversation?

• My question is, how do you find the intersecting point of the perpendicular lines if they do not intercept on the y axis? WITHOUT USING A GRAPH. I know this was touched on already but I think I am asking a slightly different question.

For example, Find the distance between the point (2,6) and the line y=−2x.

This tells me that the slope of the perpendicular line is 1/2. The equation for my second line would then be, (6) = 1/2*(2) + b. Solving this gives me the y-intercept of 5.

My two points for my second line are now (2,6) (0,5). By using the graph(which is what I am trying to avoid), I can find that the intersecting point of both lines is (-2,4)

Then, using the "distance formula" cough(pythagorean theorem)cough for the two points (2,6) and (-2,4) ==> (2-(-2))squared + (6-4)squared ==> 16+4 ==> square root of 20 being 2 root 5. So, I have the answer BY USING A GRAPH.

My question is, how do you find the intersecting point of the perpendicular lines if they do not intercept on the y axis? WITHOUT USING A GRAPH

What formula would be used? What if I end up not having graph paper? What if my line is screwy? I feel that having an equation to figure this out would let me know that I understand fully and NOT have to rely on NEEDING a graph to solve. Thanks for any help!
• Instead of finding the y-intercept of the point (2,6), find the complete equation of the line. Do this by doing what you did before--find your m and b values.

You know that the line of (2,6) is perpendicular to y=-2x, so m=1/2. You already solved for b after substituting in the values of m, x and y:

y=mx+b
(6)=(1/2)(2)+b
6-1=b, b=5

But instead of finding your y intercept, write down the general equation of the line! Since you know m and b, the equation of this line is y=1/2x+5.

Now what? To find where y=1/2x+5 and the original line y=-2x intersect, set them equal to each other. Let y in both of the equations equal the same value. You are doing this because at the two lines' point of intersection, both lines will share the same x and y value.

So, let y=1/2x+5 equal y=-2x. That means

-2x = 1/2x+5
0= 5/2x +5
-5 = 5/2x
-2 =x

Now you now that at the point where the two lines intersect, x=-2. You can substitute this x value into either of the two original equations to obtain the corresponding y value. Eg.

Sub x=-2 into y=-2x

y=-2(-2)
y=4

OR sub x=-2 into y=1/2x+5

y=(1/2)(-2)+5
=-1 + 5
y=4

Note that in both equations, you get the same y value.

So now you know that the point of intersection is (-2,4), without graphing. I'm sure there's a video on this on the site; try looking up "substitution" or "elimination".
• how would you solve this?

Determine the equation of the line that is perpendicular to y= 3x+1 and has the same y-intercept.
• 𝑦 = 3𝑥 + 1
All perpendicular lines have negative reciprocal slopes of each other. Therefore, the slope of our perpendicular line would be -1/3. So our equation for our perpendicular line so far is:
𝑦 = (-1/3)𝑥 + 𝑏
𝑏 in this equation is simply the 𝑦-intercept. We are told that the perpendicular line has the same 𝑦-intercept as the original line so that means we have 𝑏 = 1. Therefore, our finally equation for our perpendicular line is:
𝑦 = (-1/3)𝑥 + 1
Comment if you have questions.
• Why the slope of a line B perpendicular to another line A is the negative inverse of Line A ?
• because two lines perpendicular to each other must always have gradients which are negative reciprocals of each other- its how you tell two lines are perpendicular
• Why is 1/2 the inverse of 2? How do you figure out the inverse of a number?
• how do you find the equivalence in slopes
• when you have the slope for let's say line A
- then a line parallel to line A will have a slope equal to the slope of line A
- a line perpendicular to line A will have a slope equal to the negative inverse of the slope of line A

for example, if slope = 2
then the negative inverse is -1/2
• How do I find the negative inverse of 1?
• Write your number as a fraction then flip the fraction and flip the sign. Hence, 1 could be written as 1/1. Flipping the fraction keeps it the same as 1/1. Change the positive sign to a negative sign, so it's -1/1 or -1. Here's another example. If you have a slope of -1/4, flip it to -4/1 then change the sign, making the perpendicular slope 4/1 or 4.
• I've been working out the follow up problems to this video and I'm stuck at finding the distance between (0,-8) and x = 5. What do I do when I get an equation that is not clearly y = mx + b?
(1 vote)
• Hi Alicia,
x=5 means that for all values of y, x = 5. So on the graph, there will be a vertical line at x=5. To figure out the distance, then, from (0,-8) to x=5, draw a perpendicular line towards x=5. In this case, that line will be horizontal and the lines will meet at (5,-8). Since your x value at (0,-8) is 0, and your x value at the intersection (5,-8) is 5, and your y value remains the same, the distance between (0,-8) and x=5 is 5.
Hope that helps.
• my question is how to add them up.