#### Archived

This topic is now archived and is closed to further replies.

# Distance, Length, Magnitude ?!?

This topic is 5619 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi guys, Maybe I''m crazy but I always thought the magnitude of a vector is the same as it''s length and that the distance between two points is the length of the vector created by subtracting one point from the other. Take a look at the code in this tutorial on Gamasutra: http://www.gamasutra.com/features/20020118/vandenhuevel_02.htm First he finds the distance between two points, then a few code lines after that he finds the vector between those same two points, then a few lines after that he finds the length of that same vector. wtf is that ? Thanks.

##### Share on other sites
Give me your member name and password b/c I''m not a member and it takes a long time fill out forms.

##### Share on other sites
quote:
...wtf is that ?

Unoptimized code.

##### Share on other sites
From what you've told me, you're right. Distance, length, and magnitude are all equivalent. That code would need some optimisin'.

[edited by - doc on July 25, 2003 10:58:27 PM]

##### Share on other sites
Distance between two points: the magnitude of the vector formed by subtracting one point from the other.

Magnitude of a vector: the square root of the sum of the squares of the vector''s terms. In other words, sqrt(x2+y2+z2).

Length: basically the same thing as magnitude. not often used.

How appropriate. You fight like a cow.

##### Share on other sites
Thanks guys,

I thought I was losing it for a moment.

:o)

1. 1
2. 2
3. 3
4. 4
Rutin
13
5. 5

• 15
• 10
• 9
• 9
• 11
• ### Forum Statistics

• Total Topics
633693
• Total Posts
3013358
×