Cary West wrote: > Hello all, having a small problem with a trig routine using python math > module. This code is designed to convert geodetic coordinates to lambert > conformal conic coordinates. It implements the formulas found at > http://mathworld.wolfram.com/LambertConformalConicProjection.html . The > problem is that, at least on my machine, the precision is off to the tune of > around 1 km, which is unacceptable. (using the calculator found at > http://www.deh.gov.au/erin/tools/geo2lam-gda.html ) Anyone have any ideas? > here is the offending code. >
I'd assume you are exceeding the precision available with standard 64-bit floating point. Here is a library for extended precision floating point, including trig functions. http://calcrpnpy.sourceforge.net/clnumManual.html casevh -- http://mail.python.org/mailman/listinfo/python-list