degrees and radians.

Jim Richardson warlock at eskimo.com
Sat May 4 13:45:30 EDT 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sat, 04 May 2002 11:24:50 -0600,
 Robert George Mayer <mayer at acm.org> wrote:
> Jim Richardson wrote:
>> 
>> 
>> I am trying to get the math module to deal with degrees rather than
>> radians. (that it deals with radians for the angular functions like
>> sin() isn't mentioned in the docs, which was sort of an eyeopener :)  I
>> can't find any info on doing this. I can convert from-to degrees in the
>> code calling the function, but that's a bit clunky. Any pointers to an
>> FM to R? :)
>> 
> Jim -
> 
> All the math routines I have ever dealt with use radians.  In
> 30 years of dealing with this, in Fortran, C, C++ and Python, I
> have found what works best for me is to use exclusively radians
> internally and convert only where the user will see it - at the
> GUI and with any text (not binary) files.  (I think that this
> works well, but may not be as natural with a command line program,
> where the interface between the user and the program is so simple
> to begin with.)  In other words, I just consider the degrees/radians
> conversion to be part of the interface between the user and the
> program internals.
> 
> I find that it help to curse the Babylonian astronomers while
> putting all the conversions in place.
> 

*chuckle* ok, sounds like the route to take. I don't have a lot of
programming experience, and python is my first "real" language in the
last 20 years. Assembly doesn't count in this context. 


do you have any good curses in Babylonian to share? :P

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE81B46d90bcYOAWPYRAmXfAJ9z4tItLXq/zVIq3Ef+uRIGgwJInACgxAkE
mZnnk1NR8xJrrfN8dWsQX+k=
=tXKl
-----END PGP SIGNATURE-----

-- 
Jim Richardson
	Anarchist, pagan and proud of it
http://www.eskimo.com/~warlock
Linux, from watches to supercomputers, for grandmas and geeks. 



More information about the Python-list mailing list