in reply to Re^2: Subroutine not correct (I think)
in thread Subroutine not correct (I think)

The 3D-Pythagorean formula is fundamentally correct ... http://freespace.virgin.net/hugo.elias/routines/r_dist.htm ... but you appear to be subtracting a coordinate from itself, hence always zeros.

Replies are listed 'Best First'.
Re^4: Subroutine not correct (I think)
by jcklasseter (Sexton) on Jun 17, 2015 at 13:25 UTC
    I get the 'Subract X from itself and get 0' part. But what I don't get is how to fix the code to have it do what I want; I.E x2-x1 iteratively.