Go to the documentation of this file.
50 static void print_info
52 const TRANSFORMATION *trans
75 static int common_init
99 const GCTP_PROJECTION *proj = &trans->proj;
101 int spheroid = proj->spheroid;
110 "from DMS to degrees: %f", proj->parameters[2]);
118 "from DMS to degrees: %f", proj->parameters[3]);
126 "from DMS to degrees: %f", proj->parameters[4]);
134 "from DMS to degrees: %f", proj->parameters[5]);
155 trans->cache =
cache;
182 cache->ns = log(ms1/ms2)/ log(ts1/ts2);
188 trans->print_info = print_info;
202 static int inverse_transform
204 const TRANSFORMATION *trans,
219 if (cache_ptr->
ns > 0)
221 rh1 = sqrt (
x *
x +
y *
y);
226 rh1 = -sqrt (
x *
x +
y *
y);
231 theta = atan2((con *
x),(con *
y));
233 if ((rh1 != 0) || (cache_ptr->
ns > 0.0))
235 con = 1.0/cache_ptr->
ns;
236 ts = pow((rh1/(cache_ptr->
r_major * cache_ptr->
f0)),con);
257 static int forward_transform
259 const TRANSFORMATION *trans,
278 rh1 = cache_ptr->
r_major * cache_ptr->
f0 * pow(ts, cache_ptr->
ns);
282 con =
lat * cache_ptr->
ns;
308 TRANSFORMATION *trans
315 "Error initializing lambert conformal conic inverse projection");
319 trans->transform = inverse_transform;
335 TRANSFORMATION *trans
342 "Error initializing lambert conformal conic forward projection");
346 trans->transform = forward_transform;
void gctp_print_origin(double A)
void gctp_print_title(const char *proj_name)
#define GCTP_PRINT_ERROR(format,...)
double adjust_lon(double x)
def cache(filename, recache=False)
void gctp_print_stanparl(double A, double B)
int gctp_calc_phi2(double eccent, double ts, double *phi2)
double gctp_calc_small_t(double eccent, double phi, double sinphi)
void gctp_print_offsetp(double A, double B)
int gctp_dms2degrees(double angle, double *degrees)
#define gctp_get_spheroid
void gctp_print_radius2(double radius1, double radius2)
void gctp_print_cenlonmer(double A)
double gctp_calc_small_radius(double eccent, double sinphi, double cosphi)