# Measuring distances: why the Pythagoras formula

1. Dec 29, 2009

### krishna mohan

hi...

We generally use the Pythagoras formula for distance between two points in 2D, when the Cartesian co-ordinates are given....

One directly extends it to 3D..having the distance going as $$\sqrt{x^{2}+y^{2}+z^{2}}$$....

For a curved co-ordinate system, we have distances measured by something like

$$ds^{2}=g^{\mu\nu}dx_{\mu}dx_{\nu}$$...

I was wondering why it is all about squares and square roots..and not, say cubes and cube roots or fourth roots or something.....

2. Dec 29, 2009

### kakaz

There is general theory: theory of metric spaces, where You may assume that metric, that is the mathematical form used for measuring distances is general, function of Your choice.
Function may be treated as metric if has following properties:

$$\rho(A,B)>0$$

$$\rho(A,B) = 0 \iff A =B$$

$$\rho(A,B) = \rho(B,A)$$

$$\rho(A,B) \leq \rho(A,C) + \rho(C,B)$$

$$A,B,C$$ are points of space. Points may mean whatever You like! For example it may be points in Euclidean space, functions, vectors, or even geometrical shapes, or colors, as long as You provide valid $$\rho$$ You will end with space with metric measuring some kind of distances.
For typical, Euclidean space, there are non standard examples of metric ( You provided us with standard one):

$$\sum \left|x_i -y_i\right|$$

where this sum is over space dimension indexes. This is so called taxi metric. Other examples You may find in wikipedia http://en.wikipedia.org/wiki/Metric_(mathematics)

Important types of metric are defined in spaces of functions ( general in vector spaces) where this structure provides us an ability to perform for example analysis in general functional operators etc. This are Banach and Hilbert spaces with metric which is given by the so called norm.

So in fact there are norms for which You use squares etc in physical and mathematical practice in functional spaces. For example norm ($$\left\| f \right\| = \rho(0,f)$$) for function $$f$$ may be given by:

$$\left\| f \right\|_p = ( \int \left| f(x) \right| ^p dx) ^\frac{1}{p}$$

It is called $$L^p$$ norm and space of functions for which it is well defined is called $$L^p$$ space. For $$p =2$$ You will find important case 2-norm, which is used in Quantum mechanic Hilbert spaces called $$L^2$$ .

3. Dec 30, 2009

### krishna mohan

Thank you....that was very illuminating...

But I still wonder...why the general distance formula is the one with the squares and square roots? Why did nature not choose, say, the taxicab metric? Is there something that tells me it has to be this way?

4. Dec 30, 2009

### kakaz

Ha! This is the Question! If You think about curved spacetime in GR Theory, Then You will see that Euclidean metric is flat. It is not by taking other spaces/metrics relative to Euclidean, but it is somehow real thing: differential of $$x^2$$ is linear function with constant coefficients ( independent od x-coordinates). This is important thong in my opinion which is not true for other metrics.

5. Dec 30, 2009

### Truth_Seeker

to understand why it's all about squares and square roots , you need to think about the space as a vector space , i will illustrate on a 2D Euclidean Space with Cartesian coordinates for simplification but you can generalize it after ...
suppose that we need to measure the distance between two points $$P_1,P_2$$ , by thinking about the space as a vector space , we know that we can define the two points by two position vectors $$\vec{r_1},\vec{r_2}$$ ... using these two position vectors we can construct a new vector $$d\vec{r}$$ which is :
$$d\vec{r}=\vec{r_2}-\vec{r_1}$$
this new vector is a vector that connects both $$P_1$$ and $$P_2$$ and its length (norm) is the distance between the two points .
we are working on a 2D vector space , so each vector can be represented by two coordinates and two unit vectors , so :
$$\vec{r_1}=x_1\bold{i}+y_1\bold{j}$$
$$\vec{r_2}=x_2\bold{i}+y_2\bold{j}$$
therefore , we can state the vector $$d\vec{r}$$ as :
$$d\vec{r}=(x_2 - x_1)\bold{i}+(y_2 - y_1)\bold{j}$$
$$\therefore d\vec{r}=dx\bold{i}+dy\bold{j}$$
$$where : dx=x_2-x_1 , dy = y_2-y_1$$
the length (norm) a vector is the square root of the dot product of the vector by it self , means that :
$$\abs{d\vec{r}}=ds=\sqrt{d\vec{r}.d\vec{r}}$$
or : $$ds^2=d\vec{r}.d\vec{r}$$
$$\therefore ds^2=(dx\bold{i}+dy\bold{j})^2 = dx^2 + dxdy\bold{ij} + dy^2$$
and the second term will be canceled because of the orthogonality of the coordinate system leaving us with :
$$ds^2 = dx^2 + dy^2$$
and that's why it's all about squares and square roots .. !!

6. Dec 30, 2009

### tiny-tim

hi krishna!
I think it's basically because you need an inner product, and that involves two vectors, or two copies of the same vector.

One vector is in the original space, and the other is in the dual space (the space of functionals, or scalar-valued functions).

It's difficult to see how you could define a third space (or fourth etc).

7. Dec 30, 2009

### HallsofIvy

Nature didn't "choose" anything. Distance is purely a human invention. As kakaz said, you could as easily define distance to be the sum of the absolute values of the coordinate distances or the largest of those absolute values. The "standard distance formula" happens to be easy to use. Without at least an even power, you have to have absolute values to avoid "negative" distances. And, absolute value, not being 'smooth', is awkward to work with. And, while any even power would do, "2" is the smallest and so the simplest.

I still remember the shock I felt when, while reading Eddington's "The Mathematical Theory of Relativity", where he was calculating the gravitational "pull" between two bodies, he remarked that we have to decide, arbitrarily, which of several values to use as the "distance" between them.

8. Dec 30, 2009

### kakaz

I will not agree. Nature choose some kind of space-time as flat. When there is no matter, no energy, no other disturbances, then there is an Euclidean metric - and obviously that is the choice. Why? I do not know: but I assume that answer would be interesting...

In mathematics Euclidean metric is limiting case for hyperbolic or elliptic geometries which are curved, whilst Euclidean one is flat.

It is interesting coincidence that locally our space is Euclidean...

9. Dec 30, 2009

### Tac-Tics

Think about how the pythagorean theorem combines with the coordinates of a point on a circle of radius r, centered at the origin: (r * cos t, r * sin t).

$$\sqrt{ (r * \cos t)^2 + (r * \sin t)^2} = \sqrt {r^2 \cos^2 t + r^2 \sin^2 t} =\sqrt {r^2 (\cos^2 t + \sin^2 t)} = \sqrt {r^2 (1)} = r$$

10. Dec 30, 2009

### Hurkyl

Staff Emeritus

It's sort of tautologous -- if nature had "chosen" the taxicab metric, you would be here asking why that metric was chosen rather than one based on squares and square roots!

11. Dec 30, 2009

### krishna mohan

I believe the concept of a norm of a vector is an abstraction from our usual distance formula for the distance between two points... thus it does not seem appropriate to use it here..

12. Dec 30, 2009

### krishna mohan

Yep..that was something I also thought about..but I do not see what prevents me from defining a dot product between, say, three vectors..and then use it to define my distance or the norm of a vector...

13. Dec 30, 2009

### krishna mohan

Hey..thats more like what I was looking for..do you have any more references?

14. Dec 31, 2009

### mnb96

This is a very interesting issue but at the same time it confuses me.
Is it actually so safe to say that our Universe in its very essence is Euclidean?

15. Dec 31, 2009

### tiny-tim

yes, but you'd need a 3-dot product of a vector with itself

you'd need three copies of the vector in three different spaces

(like, for the standard dot product, you have two copies, one in the original space, one in the dual space).

You still need 3 spaces.

16. Dec 31, 2009

### kakaz

That is good point!
At least locally: YES. So for small distances and not very large mases and energies, our universe is Euclidean.

But there is other one point of view we may say the same: at cosmological scales, there is doubt if our universe is expanding ( hyperbolic geometry) or collapsing ( elliptic one), so we may say, that up do our measurements Universe as a whole is very near Euclidean solutions of gravitational equations. And this is even more difficult to explain!

17. Dec 31, 2009

### krishna mohan

Yes...but is there any difficulty in defining three spaces?

18. Dec 31, 2009

### krishna mohan

In fact, I was attending a talk yesterday...and the cosmologists showed some graphs and some equations and stated that the known universe has intrinsic curvature very near zero....I guess that is the same as saying the space is Euclidean....

19. Dec 31, 2009

### tiny-tim

One will be the original space, one can be the dual space, what can the third one be?

20. Jan 1, 2010

### kakaz

Yes exactly - it is the same. So it is vary strange, because such situation, requires some very precise relation for mater and energy of Universe to follow. It is amazing coincidence to be seen in reality. So it is very strange...