GeographicLib  1.37
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GeodesicLine.hpp
Go to the documentation of this file.
1 /**
2  * \file GeodesicLine.hpp
3  * \brief Header for GeographicLib::GeodesicLine class
4  *
5  * Copyright (c) Charles Karney (2009-2012) <charles@karney.com> and licensed
6  * under the MIT/X11 License. For more information, see
7  * http://geographiclib.sourceforge.net/
8  **********************************************************************/
9 
10 #if !defined(GEOGRAPHICLIB_GEODESICLINE_HPP)
11 #define GEOGRAPHICLIB_GEODESICLINE_HPP 1
12 
15 
16 namespace GeographicLib {
17 
18  /**
19  * \brief A geodesic line
20  *
21  * GeodesicLine facilitates the determination of a series of points on a
22  * single geodesic. The starting point (\e lat1, \e lon1) and the azimuth \e
23  * azi1 are specified in the constructor. GeodesicLine.Position returns the
24  * location of point 2 a distance \e s12 along the geodesic. Alternatively
25  * GeodesicLine.ArcPosition gives the position of point 2 an arc length \e
26  * a12 along the geodesic.
27  *
28  * The default copy constructor and assignment operators work with this
29  * class. Similarly, a vector can be used to hold GeodesicLine objects.
30  *
31  * The calculations are accurate to better than 15 nm (15 nanometers). See
32  * Sec. 9 of
33  * <a href="http://arxiv.org/abs/1102.1215v1">arXiv:1102.1215v1</a> for
34  * details. The algorithms used by this class are based on series expansions
35  * using the flattening \e f as a small parameter. These are only accurate
36  * for |<i>f</i>| &lt; 0.02; however reasonably accurate results will be
37  * obtained for |<i>f</i>| &lt; 0.2. For very eccentric ellipsoids, use
38  * GeodesicLineExact instead.
39  *
40  * The algorithms are described in
41  * - C. F. F. Karney,
42  * <a href="http://dx.doi.org/10.1007/s00190-012-0578-z">
43  * Algorithms for geodesics</a>,
44  * J. Geodesy <b>87</b>, 43--55 (2013);
45  * DOI: <a href="http://dx.doi.org/10.1007/s00190-012-0578-z">
46  * 10.1007/s00190-012-0578-z</a>;
47  * addenda: <a href="http://geographiclib.sf.net/geod-addenda.html">
48  * geod-addenda.html</a>.
49  * .
50  * For more information on geodesics see \ref geodesic.
51  *
52  * Example of use:
53  * \include example-GeodesicLine.cpp
54  *
55  * <a href="GeodSolve.1.html">GeodSolve</a> is a command-line utility
56  * providing access to the functionality of Geodesic and GeodesicLine.
57  **********************************************************************/
58 
60  private:
61  typedef Math::real real;
62  friend class Geodesic;
63  static const int nC1_ = Geodesic::nC1_;
64  static const int nC1p_ = Geodesic::nC1p_;
65  static const int nC2_ = Geodesic::nC2_;
66  static const int nC3_ = Geodesic::nC3_;
67  static const int nC4_ = Geodesic::nC4_;
68 
69  real tiny_;
70  real _lat1, _lon1, _azi1;
71  real _a, _f, _b, _c2, _f1, _salp0, _calp0, _k2,
72  _salp1, _calp1, _ssig1, _csig1, _dn1, _stau1, _ctau1, _somg1, _comg1,
73  _A1m1, _A2m1, _A3c, _B11, _B21, _B31, _A4, _B41;
74  // index zero elements of _C1a, _C1pa, _C2a, _C3a are unused
75  real _C1a[nC1_ + 1], _C1pa[nC1p_ + 1], _C2a[nC2_ + 1], _C3a[nC3_],
76  _C4a[nC4_]; // all the elements of _C4a are used
77  unsigned _caps;
78 
79  enum captype {
80  CAP_NONE = Geodesic::CAP_NONE,
81  CAP_C1 = Geodesic::CAP_C1,
82  CAP_C1p = Geodesic::CAP_C1p,
83  CAP_C2 = Geodesic::CAP_C2,
84  CAP_C3 = Geodesic::CAP_C3,
85  CAP_C4 = Geodesic::CAP_C4,
86  CAP_ALL = Geodesic::CAP_ALL,
87  OUT_ALL = Geodesic::OUT_ALL,
88  };
89  public:
90 
91  /**
92  * Bit masks for what calculations to do. They signify to the
93  * GeodesicLine::GeodesicLine constructor and to Geodesic::Line what
94  * capabilities should be included in the GeodesicLine object. This is
95  * merely a duplication of Geodesic::mask.
96  **********************************************************************/
97  enum mask {
98  /**
99  * No capabilities, no output.
100  * @hideinitializer
101  **********************************************************************/
103  /**
104  * Calculate latitude \e lat2. (It's not necessary to include this as a
105  * capability to GeodesicLine because this is included by default.)
106  * @hideinitializer
107  **********************************************************************/
108  LATITUDE = Geodesic::LATITUDE,
109  /**
110  * Calculate longitude \e lon2.
111  * @hideinitializer
112  **********************************************************************/
113  LONGITUDE = Geodesic::LONGITUDE,
114  /**
115  * Calculate azimuths \e azi1 and \e azi2. (It's not necessary to
116  * include this as a capability to GeodesicLine because this is included
117  * by default.)
118  * @hideinitializer
119  **********************************************************************/
120  AZIMUTH = Geodesic::AZIMUTH,
121  /**
122  * Calculate distance \e s12.
123  * @hideinitializer
124  **********************************************************************/
125  DISTANCE = Geodesic::DISTANCE,
126  /**
127  * Allow distance \e s12 to be used as input in the direct geodesic
128  * problem.
129  * @hideinitializer
130  **********************************************************************/
131  DISTANCE_IN = Geodesic::DISTANCE_IN,
132  /**
133  * Calculate reduced length \e m12.
134  * @hideinitializer
135  **********************************************************************/
136  REDUCEDLENGTH = Geodesic::REDUCEDLENGTH,
137  /**
138  * Calculate geodesic scales \e M12 and \e M21.
139  * @hideinitializer
140  **********************************************************************/
141  GEODESICSCALE = Geodesic::GEODESICSCALE,
142  /**
143  * Calculate area \e S12.
144  * @hideinitializer
145  **********************************************************************/
147  /**
148  * All capabilities, calculate everything.
149  * @hideinitializer
150  **********************************************************************/
152  };
153 
154  /** \name Constructors
155  **********************************************************************/
156  ///@{
157 
158  /**
159  * Constructor for a geodesic line staring at latitude \e lat1, longitude
160  * \e lon1, and azimuth \e azi1 (all in degrees).
161  *
162  * @param[in] g A Geodesic object used to compute the necessary information
163  * about the GeodesicLine.
164  * @param[in] lat1 latitude of point 1 (degrees).
165  * @param[in] lon1 longitude of point 1 (degrees).
166  * @param[in] azi1 azimuth at point 1 (degrees).
167  * @param[in] caps bitor'ed combination of GeodesicLine::mask values
168  * specifying the capabilities the GeodesicLine object should possess,
169  * i.e., which quantities can be returned in calls to
170  * GeodesicLine::Position.
171  *
172  * \e lat1 should be in the range [&minus;90&deg;, 90&deg;]; \e lon1 and \e
173  * azi1 should be in the range [&minus;540&deg;, 540&deg;).
174  *
175  * The GeodesicLine::mask values are
176  * - \e caps |= GeodesicLine::LATITUDE for the latitude \e lat2; this is
177  * added automatically;
178  * - \e caps |= GeodesicLine::LONGITUDE for the latitude \e lon2;
179  * - \e caps |= GeodesicLine::AZIMUTH for the latitude \e azi2; this is
180  * added automatically;
181  * - \e caps |= GeodesicLine::DISTANCE for the distance \e s12;
182  * - \e caps |= GeodesicLine::REDUCEDLENGTH for the reduced length \e m12;
183  * - \e caps |= GeodesicLine::GEODESICSCALE for the geodesic scales \e M12
184  * and \e M21;
185  * - \e caps |= GeodesicLine::AREA for the area \e S12;
186  * - \e caps |= GeodesicLine::DISTANCE_IN permits the length of the
187  * geodesic to be given in terms of \e s12; without this capability the
188  * length can only be specified in terms of arc length;
189  * - \e caps |= GeodesicLine::ALL for all of the above.
190  * .
191  * The default value of \e caps is GeodesicLine::ALL.
192  *
193  * If the point is at a pole, the azimuth is defined by keeping \e lon1
194  * fixed, writing \e lat1 = &plusmn;(90&deg; &minus; &epsilon;), and taking
195  * the limit &epsilon; &rarr; 0+.
196  **********************************************************************/
197  GeodesicLine(const Geodesic& g, real lat1, real lon1, real azi1,
198  unsigned caps = ALL);
199 
200  /**
201  * A default constructor. If GeodesicLine::Position is called on the
202  * resulting object, it returns immediately (without doing any
203  * calculations). The object can be set with a call to Geodesic::Line.
204  * Use Init() to test whether object is still in this uninitialized state.
205  **********************************************************************/
206  GeodesicLine() : _caps(0U) {}
207  ///@}
208 
209  /** \name Position in terms of distance
210  **********************************************************************/
211  ///@{
212 
213  /**
214  * Compute the position of point 2 which is a distance \e s12 (meters) from
215  * point 1.
216  *
217  * @param[in] s12 distance between point 1 and point 2 (meters); it can be
218  * negative.
219  * @param[out] lat2 latitude of point 2 (degrees).
220  * @param[out] lon2 longitude of point 2 (degrees); requires that the
221  * GeodesicLine object was constructed with \e caps |=
222  * GeodesicLine::LONGITUDE.
223  * @param[out] azi2 (forward) azimuth at point 2 (degrees).
224  * @param[out] m12 reduced length of geodesic (meters); requires that the
225  * GeodesicLine object was constructed with \e caps |=
226  * GeodesicLine::REDUCEDLENGTH.
227  * @param[out] M12 geodesic scale of point 2 relative to point 1
228  * (dimensionless); requires that the GeodesicLine object was constructed
229  * with \e caps |= GeodesicLine::GEODESICSCALE.
230  * @param[out] M21 geodesic scale of point 1 relative to point 2
231  * (dimensionless); requires that the GeodesicLine object was constructed
232  * with \e caps |= GeodesicLine::GEODESICSCALE.
233  * @param[out] S12 area under the geodesic (meters<sup>2</sup>); requires
234  * that the GeodesicLine object was constructed with \e caps |=
235  * GeodesicLine::AREA.
236  * @return \e a12 arc length of between point 1 and point 2 (degrees).
237  *
238  * The values of \e lon2 and \e azi2 returned are in the range
239  * [&minus;180&deg;, 180&deg;).
240  *
241  * The GeodesicLine object \e must have been constructed with \e caps |=
242  * GeodesicLine::DISTANCE_IN; otherwise Math::NaN() is returned and no
243  * parameters are set. Requesting a value which the GeodesicLine object is
244  * not capable of computing is not an error; the corresponding argument
245  * will not be altered.
246  *
247  * The following functions are overloaded versions of
248  * GeodesicLine::Position which omit some of the output parameters. Note,
249  * however, that the arc length is always computed and returned as the
250  * function value.
251  **********************************************************************/
253  real& lat2, real& lon2, real& azi2,
254  real& m12, real& M12, real& M21,
255  real& S12) const {
256  real t;
257  return GenPosition(false, s12,
258  LATITUDE | LONGITUDE | AZIMUTH |
259  REDUCEDLENGTH | GEODESICSCALE | AREA,
260  lat2, lon2, azi2, t, m12, M12, M21, S12);
261  }
262 
263  /**
264  * See the documentation for GeodesicLine::Position.
265  **********************************************************************/
266  Math::real Position(real s12, real& lat2, real& lon2) const {
267  real t;
268  return GenPosition(false, s12,
269  LATITUDE | LONGITUDE,
270  lat2, lon2, t, t, t, t, t, t);
271  }
272 
273  /**
274  * See the documentation for GeodesicLine::Position.
275  **********************************************************************/
276  Math::real Position(real s12, real& lat2, real& lon2,
277  real& azi2) const {
278  real t;
279  return GenPosition(false, s12,
280  LATITUDE | LONGITUDE | AZIMUTH,
281  lat2, lon2, azi2, t, t, t, t, t);
282  }
283 
284  /**
285  * See the documentation for GeodesicLine::Position.
286  **********************************************************************/
287  Math::real Position(real s12, real& lat2, real& lon2,
288  real& azi2, real& m12) const {
289  real t;
290  return GenPosition(false, s12,
291  LATITUDE | LONGITUDE |
292  AZIMUTH | REDUCEDLENGTH,
293  lat2, lon2, azi2, t, m12, t, t, t);
294  }
295 
296  /**
297  * See the documentation for GeodesicLine::Position.
298  **********************************************************************/
299  Math::real Position(real s12, real& lat2, real& lon2,
300  real& azi2, real& M12, real& M21)
301  const {
302  real t;
303  return GenPosition(false, s12,
304  LATITUDE | LONGITUDE |
305  AZIMUTH | GEODESICSCALE,
306  lat2, lon2, azi2, t, t, M12, M21, t);
307  }
308 
309  /**
310  * See the documentation for GeodesicLine::Position.
311  **********************************************************************/
313  real& lat2, real& lon2, real& azi2,
314  real& m12, real& M12, real& M21)
315  const {
316  real t;
317  return GenPosition(false, s12,
318  LATITUDE | LONGITUDE | AZIMUTH |
319  REDUCEDLENGTH | GEODESICSCALE,
320  lat2, lon2, azi2, t, m12, M12, M21, t);
321  }
322 
323  ///@}
324 
325  /** \name Position in terms of arc length
326  **********************************************************************/
327  ///@{
328 
329  /**
330  * Compute the position of point 2 which is an arc length \e a12 (degrees)
331  * from point 1.
332  *
333  * @param[in] a12 arc length between point 1 and point 2 (degrees); it can
334  * be negative.
335  * @param[out] lat2 latitude of point 2 (degrees).
336  * @param[out] lon2 longitude of point 2 (degrees); requires that the
337  * GeodesicLine object was constructed with \e caps |=
338  * GeodesicLine::LONGITUDE.
339  * @param[out] azi2 (forward) azimuth at point 2 (degrees).
340  * @param[out] s12 distance between point 1 and point 2 (meters); requires
341  * that the GeodesicLine object was constructed with \e caps |=
342  * GeodesicLine::DISTANCE.
343  * @param[out] m12 reduced length of geodesic (meters); requires that the
344  * GeodesicLine object was constructed with \e caps |=
345  * GeodesicLine::REDUCEDLENGTH.
346  * @param[out] M12 geodesic scale of point 2 relative to point 1
347  * (dimensionless); requires that the GeodesicLine object was constructed
348  * with \e caps |= GeodesicLine::GEODESICSCALE.
349  * @param[out] M21 geodesic scale of point 1 relative to point 2
350  * (dimensionless); requires that the GeodesicLine object was constructed
351  * with \e caps |= GeodesicLine::GEODESICSCALE.
352  * @param[out] S12 area under the geodesic (meters<sup>2</sup>); requires
353  * that the GeodesicLine object was constructed with \e caps |=
354  * GeodesicLine::AREA.
355  *
356  * The values of \e lon2 and \e azi2 returned are in the range
357  * [&minus;180&deg;, 180&deg;).
358  *
359  * Requesting a value which the GeodesicLine object is not capable of
360  * computing is not an error; the corresponding argument will not be
361  * altered.
362  *
363  * The following functions are overloaded versions of
364  * GeodesicLine::ArcPosition which omit some of the output parameters.
365  **********************************************************************/
366  void ArcPosition(real a12, real& lat2, real& lon2, real& azi2,
367  real& s12, real& m12, real& M12, real& M21,
368  real& S12) const {
369  GenPosition(true, a12,
370  LATITUDE | LONGITUDE | AZIMUTH | DISTANCE |
371  REDUCEDLENGTH | GEODESICSCALE | AREA,
372  lat2, lon2, azi2, s12, m12, M12, M21, S12);
373  }
374 
375  /**
376  * See the documentation for GeodesicLine::ArcPosition.
377  **********************************************************************/
378  void ArcPosition(real a12, real& lat2, real& lon2)
379  const {
380  real t;
381  GenPosition(true, a12,
382  LATITUDE | LONGITUDE,
383  lat2, lon2, t, t, t, t, t, t);
384  }
385 
386  /**
387  * See the documentation for GeodesicLine::ArcPosition.
388  **********************************************************************/
389  void ArcPosition(real a12,
390  real& lat2, real& lon2, real& azi2)
391  const {
392  real t;
393  GenPosition(true, a12,
394  LATITUDE | LONGITUDE | AZIMUTH,
395  lat2, lon2, azi2, t, t, t, t, t);
396  }
397 
398  /**
399  * See the documentation for GeodesicLine::ArcPosition.
400  **********************************************************************/
401  void ArcPosition(real a12, real& lat2, real& lon2, real& azi2,
402  real& s12) const {
403  real t;
404  GenPosition(true, a12,
405  LATITUDE | LONGITUDE | AZIMUTH | DISTANCE,
406  lat2, lon2, azi2, s12, t, t, t, t);
407  }
408 
409  /**
410  * See the documentation for GeodesicLine::ArcPosition.
411  **********************************************************************/
412  void ArcPosition(real a12, real& lat2, real& lon2, real& azi2,
413  real& s12, real& m12) const {
414  real t;
415  GenPosition(true, a12,
416  LATITUDE | LONGITUDE | AZIMUTH |
417  DISTANCE | REDUCEDLENGTH,
418  lat2, lon2, azi2, s12, m12, t, t, t);
419  }
420 
421  /**
422  * See the documentation for GeodesicLine::ArcPosition.
423  **********************************************************************/
424  void ArcPosition(real a12, real& lat2, real& lon2, real& azi2,
425  real& s12, real& M12, real& M21)
426  const {
427  real t;
428  GenPosition(true, a12,
429  LATITUDE | LONGITUDE | AZIMUTH |
430  DISTANCE | GEODESICSCALE,
431  lat2, lon2, azi2, s12, t, M12, M21, t);
432  }
433 
434  /**
435  * See the documentation for GeodesicLine::ArcPosition.
436  **********************************************************************/
437  void ArcPosition(real a12, real& lat2, real& lon2, real& azi2,
438  real& s12, real& m12, real& M12, real& M21)
439  const {
440  real t;
441  GenPosition(true, a12,
442  LATITUDE | LONGITUDE | AZIMUTH |
443  DISTANCE | REDUCEDLENGTH | GEODESICSCALE,
444  lat2, lon2, azi2, s12, m12, M12, M21, t);
445  }
446  ///@}
447 
448  /** \name The general position function.
449  **********************************************************************/
450  ///@{
451 
452  /**
453  * The general position function. GeodesicLine::Position and
454  * GeodesicLine::ArcPosition are defined in terms of this function.
455  *
456  * @param[in] arcmode boolean flag determining the meaning of the second
457  * parameter; if arcmode is false, then the GeodesicLine object must have
458  * been constructed with \e caps |= GeodesicLine::DISTANCE_IN.
459  * @param[in] s12_a12 if \e arcmode is false, this is the distance between
460  * point 1 and point 2 (meters); otherwise it is the arc length between
461  * point 1 and point 2 (degrees); it can be negative.
462  * @param[in] outmask a bitor'ed combination of GeodesicLine::mask values
463  * specifying which of the following parameters should be set.
464  * @param[out] lat2 latitude of point 2 (degrees).
465  * @param[out] lon2 longitude of point 2 (degrees); requires that the
466  * GeodesicLine object was constructed with \e caps |=
467  * GeodesicLine::LONGITUDE.
468  * @param[out] azi2 (forward) azimuth at point 2 (degrees).
469  * @param[out] s12 distance between point 1 and point 2 (meters); requires
470  * that the GeodesicLine object was constructed with \e caps |=
471  * GeodesicLine::DISTANCE.
472  * @param[out] m12 reduced length of geodesic (meters); requires that the
473  * GeodesicLine object was constructed with \e caps |=
474  * GeodesicLine::REDUCEDLENGTH.
475  * @param[out] M12 geodesic scale of point 2 relative to point 1
476  * (dimensionless); requires that the GeodesicLine object was constructed
477  * with \e caps |= GeodesicLine::GEODESICSCALE.
478  * @param[out] M21 geodesic scale of point 1 relative to point 2
479  * (dimensionless); requires that the GeodesicLine object was constructed
480  * with \e caps |= GeodesicLine::GEODESICSCALE.
481  * @param[out] S12 area under the geodesic (meters<sup>2</sup>); requires
482  * that the GeodesicLine object was constructed with \e caps |=
483  * GeodesicLine::AREA.
484  * @return \e a12 arc length of between point 1 and point 2 (degrees).
485  *
486  * The GeodesicLine::mask values possible for \e outmask are
487  * - \e outmask |= GeodesicLine::LATITUDE for the latitude \e lat2;
488  * - \e outmask |= GeodesicLine::LONGITUDE for the latitude \e lon2;
489  * - \e outmask |= GeodesicLine::AZIMUTH for the latitude \e azi2;
490  * - \e outmask |= GeodesicLine::DISTANCE for the distance \e s12;
491  * - \e outmask |= GeodesicLine::REDUCEDLENGTH for the reduced length \e
492  * m12;
493  * - \e outmask |= GeodesicLine::GEODESICSCALE for the geodesic scales \e
494  * M12 and \e M21;
495  * - \e outmask |= GeodesicLine::AREA for the area \e S12;
496  * - \e outmask |= GeodesicLine::ALL for all of the above.
497  * .
498  * Requesting a value which the GeodesicLine object is not capable of
499  * computing is not an error; the corresponding argument will not be
500  * altered. Note, however, that the arc length is always computed and
501  * returned as the function value.
502  **********************************************************************/
503  Math::real GenPosition(bool arcmode, real s12_a12, unsigned outmask,
504  real& lat2, real& lon2, real& azi2,
505  real& s12, real& m12, real& M12, real& M21,
506  real& S12) const;
507 
508  ///@}
509 
510  /** \name Inspector functions
511  **********************************************************************/
512  ///@{
513 
514  /**
515  * @return true if the object has been initialized.
516  **********************************************************************/
517  bool Init() const { return _caps != 0U; }
518 
519  /**
520  * @return \e lat1 the latitude of point 1 (degrees).
521  **********************************************************************/
523  { return Init() ? _lat1 : Math::NaN(); }
524 
525  /**
526  * @return \e lon1 the longitude of point 1 (degrees).
527  **********************************************************************/
529  { return Init() ? _lon1 : Math::NaN(); }
530 
531  /**
532  * @return \e azi1 the azimuth (degrees) of the geodesic line at point 1.
533  **********************************************************************/
535  { return Init() ? _azi1 : Math::NaN(); }
536 
537  /**
538  * @return \e azi0 the azimuth (degrees) of the geodesic line as it crosses
539  * the equator in a northward direction.
540  **********************************************************************/
542  using std::atan2;
543  return Init() ?
544  atan2(_salp0, _calp0) / Math::degree() : Math::NaN();
545  }
546 
547  /**
548  * @return \e a1 the arc length (degrees) between the northward equatorial
549  * crossing and point 1.
550  **********************************************************************/
552  using std::atan2;
553  return Init() ?
554  atan2(_ssig1, _csig1) / Math::degree() : Math::NaN();
555  }
556 
557  /**
558  * @return \e a the equatorial radius of the ellipsoid (meters). This is
559  * the value inherited from the Geodesic object used in the constructor.
560  **********************************************************************/
562  { return Init() ? _a : Math::NaN(); }
563 
564  /**
565  * @return \e f the flattening of the ellipsoid. This is the value
566  * inherited from the Geodesic object used in the constructor.
567  **********************************************************************/
569  { return Init() ? _f : Math::NaN(); }
570 
571  /// \cond SKIP
572  /**
573  * <b>DEPRECATED</b>
574  * @return \e r the inverse flattening of the ellipsoid.
575  **********************************************************************/
576  Math::real InverseFlattening() const
577  { return Init() ? 1/_f : Math::NaN(); }
578  /// \endcond
579 
580  /**
581  * @return \e caps the computational capabilities that this object was
582  * constructed with. LATITUDE and AZIMUTH are always included.
583  **********************************************************************/
584  unsigned Capabilities() const { return _caps; }
585 
586  /**
587  * @param[in] testcaps a set of bitor'ed GeodesicLine::mask values.
588  * @return true if the GeodesicLine object has all these capabilities.
589  **********************************************************************/
590  bool Capabilities(unsigned testcaps) const {
591  testcaps &= OUT_ALL;
592  return (_caps & testcaps) == testcaps;
593  }
594  ///@}
595 
596  };
597 
598 } // namespace GeographicLib
599 
600 #endif // GEOGRAPHICLIB_GEODESICLINE_HPP
Math::real Position(real s12, real &lat2, real &lon2, real &azi2) const
static T NaN()
Definition: Math.hpp:460
Math::real MajorRadius() const
#define GEOGRAPHICLIB_EXPORT
Definition: Constants.hpp:70
GeographicLib::Math::real real
Definition: GeodSolve.cpp:40
Math::real Position(real s12, real &lat2, real &lon2, real &azi2, real &m12, real &M12, real &M21, real &S12) const
void ArcPosition(real a12, real &lat2, real &lon2, real &azi2) const
void ArcPosition(real a12, real &lat2, real &lon2, real &azi2, real &s12) const
Math::real Flattening() const
Header for GeographicLib::Geodesic class.
Math::real Position(real s12, real &lat2, real &lon2, real &azi2, real &m12, real &M12, real &M21) const
void ArcPosition(real a12, real &lat2, real &lon2) const
Math::real Longitude() const
Math::real EquatorialArc() const
Math::real Latitude() const
void ArcPosition(real a12, real &lat2, real &lon2, real &azi2, real &s12, real &m12) const
static T degree()
Definition: Math.hpp:227
Math::real Position(real s12, real &lat2, real &lon2, real &azi2, real &m12) const
unsigned Capabilities() const
Math::real Azimuth() const
bool Capabilities(unsigned testcaps) const
Math::real Position(real s12, real &lat2, real &lon2, real &azi2, real &M12, real &M21) const
Header for GeographicLib::Constants class.
void ArcPosition(real a12, real &lat2, real &lon2, real &azi2, real &s12, real &m12, real &M12, real &M21) const
Math::real Position(real s12, real &lat2, real &lon2) const
Math::real EquatorialAzimuth() const
void ArcPosition(real a12, real &lat2, real &lon2, real &azi2, real &s12, real &m12, real &M12, real &M21, real &S12) const
Geodesic calculations
Definition: Geodesic.hpp:172
void ArcPosition(real a12, real &lat2, real &lon2, real &azi2, real &s12, real &M12, real &M21) const