Distance calculation

If you have problems installing or running Algodoo, have found a bug or need in-game help - this is it!

Distance calculation

Postby FuzzyLogicBrain » Sun Jul 17, 2011 2:39 pm

How do i calculate the distance between to objects, and i dont want a negative number, i just want the distance.
Image
these guys are awesome. <- full stop
User avatar
FuzzyLogicBrain
 
Posts: 315
Joined: Mon Jan 31, 2011 7:48 pm
Location: when online, on the computer. when not, probably on it anyways. ;D lulz

Re: Distance calculation

Postby TC42 » Sun Jul 17, 2011 4:47 pm

You can learn to use the world's most famous search engine ;)

Anyway, D = ((x1 - x2)^2 + (y1 - y2)^2)^0.5 or something like that...

The order of the points doesn't matter as long as it is consistent.
Image
Spambot wrote:Nowadays, memes usually are studied less in the field of biology, but more with the arena of psychology along with sociology. But, the major area of a meme, getting embraced and imitated all the time is what’s at any core connected with any meme.
User avatar
TC42
 
Posts: 984
Joined: Sun Jan 09, 2011 1:53 pm
Location: $ sudo apt get-install sandwich_

Re: Distance calculation

Postby FuzzyLogicBrain » Sun Jul 17, 2011 5:38 pm

but you need the square root, dont you? that is the hypotenuse inst it?
Image
these guys are awesome. <- full stop
User avatar
FuzzyLogicBrain
 
Posts: 315
Joined: Mon Jan 31, 2011 7:48 pm
Location: when online, on the computer. when not, probably on it anyways. ;D lulz

Re: Distance calculation

Postby TC42 » Sun Jul 17, 2011 8:04 pm

A number to the power of one half is the square root of that number.
Image
Spambot wrote:Nowadays, memes usually are studied less in the field of biology, but more with the arena of psychology along with sociology. But, the major area of a meme, getting embraced and imitated all the time is what’s at any core connected with any meme.
User avatar
TC42
 
Posts: 984
Joined: Sun Jan 09, 2011 1:53 pm
Location: $ sudo apt get-install sandwich_


Return to Help / Bug reports

Who is online

Users browsing this forum: No registered users and 4 guests