Content deleted Content added
produce 6 sigfig, not 7 |
+intermediate variables |
||
Line 528:
local function find_M ( lat_rad )
local e = OSGBglobe.ecc
local e2 = e*e
local e3 = e*e*e
return OSGBglobe.semimajor * ( ( 1 - e/4 - 3 *
- 5 *
) * lat_rad
- ( 3 * e/8 + 3 *
+ 45 *
) * sin(2 * lat_rad)
+ ( 15 *
45 *
) * sin(4 * lat_rad)
- ( 35 *
) * sin(6 * lat_rad) )
end
Line 561 ⟶ 563:
local v = OSGBglobe.semimajor / sqrt(1 - e * sin(lat_rad)*sin(lat_rad))
local
local T = tank*tank
local T2 = T*T
local C = e_prime_sq * pow( cos(lat_rad), 2)
local A = deg2rad( longitude2 -OSGBglobe.lon0 ) * cos(lat_rad)
local A2 = A*A
local A3 = A2*A
local A4 = A2*A2
local A5 = A3*A2
local A6 = A3*A3
local M = find_M( lat_rad )
local M0 = 0.0
Line 572 ⟶ 581:
local northing = OSGBglobe.n0 + OSGBglobe.scale *
( (M - M0) + v*tan(lat_rad) *
(
+ (5 - T + 9*C + 4*C*C) *
+ (61 - 58*T +
+ 600*C - 330*e_prime_sq) *
local easting = OSGBglobe.e0 + OSGBglobe.scale * v *
( A
+ (1-T+C)*
+ (5 - 18*T +
- 58 * e_prime_sq)*
return {northing=northing,easting=easting}
|