The step distances are already set by the external grid, which is one of the things that makes this difficult. I'm trying to model a surfing reef on an ocean floor, right now it's a basic theoretical plane, but the program should be general enough to deal with any layout.
>Next, to find where the hypotenuse is, to count along the X axis. Since tangent is opposite/adjacent, and my X axis is adjacent to the angle I know, I'm trying to find Z by doing 1/[tan(theta)*j (the opposite)] That should get me 1/1/adjacent, which should come out to adjacent.
No, that won't give you 1/1/adjacent. What that gives you is 1/[(opposite/adjacent)*opposite]... that doesn't come out to 1/1/adjacent; it comes out to adjacent/opposite^2, which isn't what you want. What you want is j/tan(theta).
That doesn't explain the divide by zero error, though. Not sure what's going on with that... (Unless j1 is zero?)
Hmm, I think you're right. It's always the stupid tiny things that cause the trip-ups. I'd gotten in to work by changing it to sin, but I knew the angles were wrong. That does seem to have fixed it. Thanks!
Comments 3
(The comment has been removed)
Reply
No, that won't give you 1/1/adjacent. What that gives you is 1/[(opposite/adjacent)*opposite]... that doesn't come out to 1/1/adjacent; it comes out to adjacent/opposite^2, which isn't what you want. What you want is j/tan(theta).
That doesn't explain the divide by zero error, though. Not sure what's going on with that... (Unless j1 is zero?)
Reply
Reply
Leave a comment