 Using the Pythagorean equation, we actually get the distance formula between any two points in the plane. So if we have two points A and B, and these are points in the plane, let's draw them right here. So let's have one point A, have some point B. We can draw the line segment that connects these two together, right? And so the length of this line segment is gonna be AB. If I draw AB with a line over it, I'm talking about the line segment. If I draw just AB with no line segment above it, that means I'm computing the length of the line. So it turns out that the length of this line segment can be computed using the Pythagorean equation because if these points A and B are in the plane, they have coordinates. Let's say that the coordinate for point A is X1, Y1. So there's some X coordinate, some Y coordinate. The coordinate for B, let's call it X2, Y2. So again, some X coordinate, some Y coordinate. And so then using these points A and B, I wanna form a right triangle so that the one leg of the triangle is completely horizontal and the other leg of the triangle is completely vertical. So we form this right triangle and consider this point right here. This would be the point which this point is on the same horizontal line as X1, Y1. So it's gonna have the same Y coordinate, which is Y1. And then this point is on the same vertical line as B. So we'd have the same X coordinate. So the X coordinate here would be X2 then. So if we measure the distance between here and here because it's completely horizontal, the distance there is just gonna be X2 minus X1. Then if we measure the distance from this red point up, the vertical line to the yellow point, since the X coordinate is the same, we'll just take the difference of the Y coordinates. We get Y2 minus Y1. And so now we see we have the measure of one side of the right triangle. We have the measure of another side of the right triangle and we wanna know the measure of AB right here. So by the Pythagorean equation, we get that the hypotenuse squared is gonna equal the sum of the leg squares. So we're gonna take X2 minus X1 squared plus Y2 minus Y1 squared. Then if you wanna solve for AB, you're gonna take the positive square root of both sides and that leads to the distance formula right here. So the distance formula is just a rewriting of the Pythagorean equation. When you see it that way, the distance formula doesn't seem as anything fundamentally different to just the Pythagorean equation, which we already know. So for example, let's find the distance between two points. Let's take the point A, which has coordinates one, three in the plane and let's take the point B, which has the coordinates five, six in the plane. So you'll notice right here, my point A and my point B. And so let's compute the distance between them by the distance formula AB, it's gonna equal the square root of, take the difference of the X coordinates, five minus one squared. And then you're gonna add to that the difference of the Y coordinates squared. And honestly, it doesn't matter who comes first. It doesn't matter who's on first, who's on second. A could be the first point, B could be the second point because if you swapped it around, right? If you take five minus, one minus five squared, excuse me, well, notice that the five minus one is gonna be four. On the other hand, if you take one minus five, that's gonna give you negative four. Since you're squaring them, four squared is 16. Negative four squared is still 16 by order of operations. And so it doesn't matter who's the first point, who's the second point. In the end, when you square things, you'll end up with a positive quantity when you're doing this. So four minus one squared is four squared, which is 16. If you take six minus three squared, it's gonna give you a three squared, which is a nine. 16 plus nine is 25. And the square root of 25 is a five. And so we see that the length, that is the distance between the point A and the point B is gonna be five units. And basically what we saw here is that this distance right here is four, this distance right here is three. And since the distance between these points turned out to be a whole number five, this actually coincides with a Pythagorean triple, a so-called three, four, five triangle. Now, we shouldn't expect that to happen in generality. Let's look at another example of this. Let's find the distance between the points P and Q right here. Well, the distance formula tells us we're gonna take the square root of, take a difference of their X coordinates. Again, it doesn't matter who goes first and who goes second. So we're gonna take three minus and negative four. Do pay attention to signs here. We have to square that. We have to also take the difference of the Y coordinates and square that. So you get two minus five squared. Now, sometimes because these square roots get really long, if you wanna extend the line or the so-called vinculum, you can do that. I often like to put a little tick at the back so you know where does the square root end in this. It's just a little bit of notational help there. Now, notice that you have three minus a negative four. So this is a double negative actually becomes a positive. What we're doing here is we're taking three plus four. And so three plus four is a seven. Two minus five is a negative three. But again, the signs don't matter because when you subtract them, that is if you end up with a positive three versus a minus three, that doesn't matter. Because when you square them, you're gonna get a positive 49 and a positive nine. And so adding those together, you end up with the square root of 58, excuse me, 58. In which case that gives us the exact value of the distance. Now, if you want an approximation, that's perfectly fine. Yet be careful. Do I want an exact answer or do I want an approximate answer? Typically this comes from the instructions of a problem you're working on or the context of the problem. And so if once an exact answer, you'd say the distance is gonna be the square root of 58. Which 58 is larger than 49, but it's smaller than 64. So this is gonna be a number somewhere between seven and eight. If you consult your scientific calculator, you'll get the distance is approximately 7.61577. Go to however many decimal places you're instructed to do so. And so we see that this gives us the approximate distance between the two points. And this is typically what happens. If you just pick two random points in the plane, the distance between them will probably be some irrational square root.