Subject:
|
Re: Navigation & Encoders
|
Newsgroups:
|
lugnet.robotics.handyboard
|
Date:
|
Tue, 4 May 1999 16:25:00 GMT
|
Original-From:
|
Will Bain <WILLBAIN@CS.UMTnospam.EDU>
|
Viewed:
|
813 times
|
| |
| |
> Andrew wrote:
> I know this is not really handyboard specific but hey... Does anybody
> know the equation for finding a heading (theta) from a current
> position P(x,y) to a goal position G(x,y).
The angle relative to the x axis is given by:
theta = arctan((y2 - y1)/(x2 - x1))
Remember, the tangent of an angle is the length of the opposite side
divided by the length of the adjacent side of the corresponding unit
right triangle (i.e., hypotenuse has unit length).
-- Will
, ,
__@_/ \_@__ |/
| /__, o @_/
)\ ) ( \ (\/\\,
~~~~~~~~~ ' ` ~~~~~~~~~~~ ` ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Wendy Parson, America's one of the finest countries
Will Bain, anyone ever stole.
& Tatoosh --Bobcat Goldthwait
|
|
Message is in Reply To:
| | Navigation & Encoders
|
| I know this is not really handyboard specific but hey... Does anybody know the equation for finding a heading (theta) from a current position P(x,y) to a goal position G(x,y). I sure there's a tangent in there somewhere but I've already dredged up (...) (25 years ago, 4-May-99, to lugnet.robotics.handyboard)
|
3 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|