View Single Post
  #2   Spotlight this post!  
Unread 30-10-2001, 06:16
Happy Birthday! Leo M Leo M is offline
Registered User
#0384 (Tucker Tigers)
 
Join Date: Jun 2001
Location: Richmond, VA
Posts: 70
Leo M is just really niceLeo M is just really niceLeo M is just really niceLeo M is just really niceLeo M is just really nice
After looking up some information on 'two's complement' arithmetic, I think the arcsin algorithm should work just fine in Pbasic. You run into problems doing 'two's complement' calculations with very large numbers, and get strange results like adding two large positive numbers and getting a negative result. However, all of the functions in the arcsin calculation are bounded. The sine and cosine range between -1 and 1, the arcsin result will be between -pi/2 and pi/2, the epsilon constant will be a small positive number, and the 'first guess' will also fall between -1 and 1. So, this algorithm should rapidly converge to the angle you are looking for and not head off into deep space.

By the way, does anyone find any of this useful, or even interesting? I love this kind of stuff, but then, I have gotten strange looks all my life and am used to them. Actually, I like them. But, have I gone too deep into the Nerdly Woods to interest even confirmed FIRST-ers?
__________________
Leo M.