OmniSciDB  a5dc49c757
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
constants.h File Reference

Constants used by more than one source code file. More...

+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define M_PI   3.14159265358979323846
 
#define M_PI_2   1.5707963267948966
 
#define M_2PI   6.28318530717958647692528676655900576839433
 
#define M_PI_180   0.0174532925199432957692369076848861271111
 
#define M_180_PI   57.29577951308232087679815481410517033240547
 
#define EPSILON   0.0000000000000001
 
#define M_SQRT3_2   0.8660254037844386467637231707529361834714
 
#define M_SIN60   M_SQRT3_2
 
#define M_AP7_ROT_RADS   0.333473172251832115336090755351601070065900389
 
#define M_SIN_AP7_ROT   0.3273268353539885718950318
 
#define M_COS_AP7_ROT   0.9449111825230680680167902
 
#define EARTH_RADIUS_KM   6371.007180918475
 
#define RES0_U_GNOMONIC   0.38196601125010500003
 
#define MAX_H3_RES   15
 
#define NUM_ICOSA_FACES   20
 
#define NUM_BASE_CELLS   122
 
#define NUM_HEX_VERTS   6
 
#define NUM_PENT_VERTS   5
 
#define NUM_PENTAGONS   12
 
#define H3_HEXAGON_MODE   1
 
#define H3_UNIEDGE_MODE   2
 
#define H3_EDGE_MODE   3
 
#define H3_VERTEX_MODE   4
 

Detailed Description

Constants used by more than one source code file.

Definition in file constants.h.

Macro Definition Documentation

#define EARTH_RADIUS_KM   6371.007180918475

earth radius in kilometers using WGS84 authalic radius

Definition at line 60 of file constants.h.

#define EPSILON   0.0000000000000001

threshold epsilon

Definition at line 42 of file constants.h.

Referenced by _geoAzDistanceRads(), _geoToHex2d(), and _hex2dToGeo().

#define H3_EDGE_MODE   3

Definition at line 84 of file constants.h.

#define H3_HEXAGON_MODE   1

H3 index modes

Definition at line 82 of file constants.h.

Referenced by _faceIjkToH3().

#define H3_UNIEDGE_MODE   2

Definition at line 83 of file constants.h.

#define H3_VERTEX_MODE   4

Definition at line 85 of file constants.h.

#define M_180_PI   57.29577951308232087679815481410517033240547

pi * 180

Definition at line 39 of file constants.h.

Referenced by radsToDegs().

#define M_2PI   6.28318530717958647692528676655900576839433

2.0 * PI

Definition at line 34 of file constants.h.

Referenced by _posAngleRads().

#define M_AP7_ROT_RADS   0.333473172251832115336090755351601070065900389

rotation angle between Class II and Class III resolution axes (asin(sqrt(3.0 / 28.0)))

Definition at line 51 of file constants.h.

Referenced by _geoToHex2d(), and _hex2dToGeo().

#define M_COS_AP7_ROT   0.9449111825230680680167902

cos(M_AP7_ROT_RADS)

Definition at line 57 of file constants.h.

#define M_PI   3.14159265358979323846
#define M_PI_180   0.0174532925199432957692369076848861271111

pi / 180

Definition at line 37 of file constants.h.

Referenced by degsToRads().

#define M_PI_2   1.5707963267948966

pi / 2.0

Definition at line 30 of file constants.h.

Referenced by _geoAzDistanceRads().

#define M_SIN60   M_SQRT3_2

sin(60')

Definition at line 46 of file constants.h.

Referenced by _hex2dToCoordIJK().

#define M_SIN_AP7_ROT   0.3273268353539885718950318

sin(M_AP7_ROT_RADS)

Definition at line 54 of file constants.h.

#define M_SQRT3_2   0.8660254037844386467637231707529361834714

sqrt(3) / 2.0

Definition at line 44 of file constants.h.

Referenced by _ijkToHex2d().

#define MAX_H3_RES   15

max H3 resolution; H3 version 1 has 16 resolutions, numbered 0 through 15

Definition at line 68 of file constants.h.

Referenced by geoToH3(), and h3ToParent().

#define NUM_BASE_CELLS   122

The number of H3 base cells

Definition at line 73 of file constants.h.

#define NUM_HEX_VERTS   6

The number of vertices in a hexagon

Definition at line 75 of file constants.h.

#define NUM_ICOSA_FACES   20

The number of faces on an icosahedron

Definition at line 71 of file constants.h.

Referenced by _geoToHex2d().

#define NUM_PENT_VERTS   5

The number of vertices in a pentagon

Definition at line 77 of file constants.h.

#define NUM_PENTAGONS   12

The number of pentagons per resolution

Definition at line 79 of file constants.h.

#define RES0_U_GNOMONIC   0.38196601125010500003

scaling factor from hex2d resolution 0 unit length (or distance between adjacent cell center points on the plane) to gnomonic unit length.

Definition at line 65 of file constants.h.

Referenced by _geoToHex2d(), and _hex2dToGeo().