home *** CD-ROM | disk | FTP | other *** search
/ Collection of Education / collectionofeducationcarat1997.iso / SCIENCE / DE118I.ZIP / ACONST.C next >
C/C++ Source or Header  |  1993-02-06  |  20KB  |  554 lines

  1. #include "mconf.h"
  2. #include "prec.h"
  3. #include "ssystem.h"
  4.  
  5. #if LDOUBLE
  6. #if MIEEE
  7. long DTR[] = {0x3ff90000,0x8efa3512,0x94e9c8ae};
  8. long RTD[] = {0x40040000,0xe52ee0d3,0x1e0fbdc3};
  9. long RTS[] = {0x40100000,0xc96e3399,0x8d6bd5c8};
  10. long STR[] = {0x3fed0000,0xa2ad2d97,0xfc7ce8e1};
  11. long PI[] = {0x40000000,0xc90fdaa2,0x2168c235};
  12. long J2000[] = {0x40140000,0x95a16400,0x00000000};
  13. long B1950[] = {0x40140000,0x948409b1,0x26e978d5};
  14. long J1900[] = {0x40140000,0x9366b000,0x00000000};
  15. long B1900[] = {0x40140000,0x9366b140,0x83126e98};
  16. long Jcentury[] = {0x400e0000,0x8ead0000,0x00000000};
  17. long Jmillenium[] = {0x40110000,0xb2584000,0x00000000};
  18. long Jtmillenium[] = {0x40140000,0xdeee5000,0x00000000};
  19.  
  20. /* Solar system barycentric velocity and position
  21.  * state of Mercury, Venus, EMB, ..., Pluto, MOON, Sun
  22.  * in the order dx/dt, x, dy/dt, y, dz/dt, z for each object.
  23.  *
  24.  * EMB is the arithmetic average of Earth and Moon, weighted by
  25.  * their masses. The coordinates of the Moon variable are the
  26.  * the solar system barycentric coordinates of the Moon
  27.  * minus those of the Earth.
  28.  */
  29.  
  30. /* Note, these particular numbers are derived from the heliocentric
  31.  * planet states and barycentric Sun state given in the
  32.  * documentation for the DE118.
  33.  */
  34.  
  35. /* June 28.0, 1969 */
  36. long JD0[] = {0x40140000,0x94f34200,0x00000000};
  37.  
  38. long yn0[3*6*NTOTAL] = {
  39. 0x3ff10000,0xd1bf69c8,0x1d23caa1,
  40. 0x3ff70000,0xc5b414b0,0xa6b903a1,
  41. 0x3fee0000,0xfa0c23bf,0x76086fc6,
  42. 0x3ffd0000,0xc3c90428,0x9a202d35,
  43. 0xbff10000,0xfa78c92e,0xc3fbfff5,
  44. 0x3fff0000,0xa3fe8130,0xc67cfbf8,
  45. 0x3ff60000,0xf30a6c32,0x006e947b,
  46. 0x3ffd0000,0xb87a1c70,0x756c6608,
  47. 0x3ff90000,0xcb9ca061,0x95de1888,
  48. 0xbffb0000,0xc22d40e6,0xc3c3dcab,
  49. 0x3ff80000,0xd3d49d18,0x9afea5a3,
  50. 0xbffb0000,0xb321d08e,0x4dc6f602,
  51. 0x3ff80000,0xb6ca5d1d,0xa0c51235,
  52. 0x3ffe0000,0x9b9d04c8,0x36c03017,
  53. 0x3ff80000,0xfddadce7,0x38a8008d,
  54. 0xbffd0000,0xb5daa0c7,0xc77aa9ef,
  55. 0x3ff70000,0xcdb2915a,0x7feb25b5,
  56. 0xbffc0000,0xcaffcd1a,0xc32be65e,
  57. 0x3ff90000,0x89e5e2d3,0xba33e259,
  58. 0x3ffb0000,0xdd9be1ca,0x0edb8ed2,
  59. 0x3ff50000,0xcc7fbf06,0xb36c6ad9,
  60. 0xbffe0000,0xed57274e,0x0452c885,
  61. 0x3ff40000,0xb1549434,0x330615d6,
  62. 0xbffd0000,0xcddf3248,0xb2029215,
  63. 0x3ff80000,0xed459271,0x3e183b31,
  64. 0xbffc0000,0x83090473,0xaef31309,
  65. 0x3ff10000,0xa8e16e0a,0x7fd1f107,
  66. 0xbfff0000,0xa9c2f259,0x9cc856cf,
  67. 0xbff30000,0xb87dc8a2,0xddcb49d3,
  68. 0xbffe0000,0x9af57883,0xa157914e,
  69. 0x3ff50000,0x83c5c9ff,0xfc36cbf4,
  70. 0xc0010000,0xac784756,0xb781da47,
  71. 0xbff70000,0xd5f84a08,0xafaa21ec,
  72. 0xbffe0000,0xc5301e97,0x0fd3f76e,
  73. 0xbff60000,0xb93260d3,0xe0333656,
  74. 0xbffc0000,0xcb6ea845,0xd512cfb5,
  75. 0xbff60000,0xcf0f0c37,0xe1cebe1d,
  76. 0x40010000,0xfe7d25e2,0x0433e5bf,
  77. 0x3ff70000,0x8f3e7e3a,0xa6fd29a5,
  78. 0x40010000,0x90409235,0xc80618c5,
  79. 0x3ff50000,0xfed27f49,0xbb1af2f2,
  80. 0x3fff0000,0xc295c458,0x6246bf64,
  81. 0x3ff20000,0xb364c57f,0x9e06eadc,
  82. 0xc0030000,0x9239d41a,0x777fe508,
  83. 0xbff60000,0xf6b8b08a,0x9edadeec,
  84. 0xbffe0000,0xf528453e,0x69eacf52,
  85. 0xbff50000,0xd886d7df,0xd1ec17c9,
  86. 0xbffc0000,0xa53191b6,0xc3d55283,
  87. 0x3ff60000,0xabdea800,0x0ef5eb62,
  88. 0xc0030000,0x82f00205,0xea5baf68,
  89. 0xbff50000,0xc83eb17c,0x8b2bedc4,
  90. 0xc0030000,0xbe165105,0xb8e3089f,
  91. 0xbff40000,0xb55c0ed6,0xa75d5e2b,
  92. 0xc0020000,0x9524664b,0x57754788,
  93. 0x3ff30000,0x93bb8bf5,0x336a2eb4,
  94. 0xc0030000,0xf394d962,0xb82386d6,
  95. 0xbff60000,0xce3d3655,0x239c5311,
  96. 0xbffe0000,0x8822b103,0x3b3b7a56,
  97. 0xbff50000,0x8d7b73e1,0xa29602a1,
  98. 0x40020000,0x90f45c75,0x995784e4,
  99. 0x3ff40000,0x9cf59311,0x6be6fee1,
  100. 0xbff40000,0xdb131709,0x9c4f23ef,
  101. 0xbff20000,0xb69d0810,0xb27a7a7b,
  102. 0xbff60000,0x821e2440,0x1cdeb2b0,
  103. 0xbff10000,0xb98cd542,0x03ee8f42,
  104. 0xbff50000,0x8dfc77e2,0x50340914,
  105. 0xbfe90000,0x984eab8f,0x62452954,
  106. 0x3ff70000,0x93eda1ac,0x9b54e4ec,
  107. 0x3fed0000,0xadda1eff,0x03a35753,
  108. 0x3ff40000,0xbd7c318d,0x6a4fbd7a,
  109. 0x3fec0000,0x95b26d4d,0x77dd8c9e,
  110. 0x3ff30000,0x8148e269,0xc41a9edf,
  111. };
  112.  
  113. long JD1[] = {0x40140000,0x94f98200,0x00000000};
  114.  
  115. long yn1[3*6*NTOTAL] = {
  116. 0x3ff10000,0xfb3c55d2,0x55278a54,
  117. 0x3ffa0000,0x85d62851,0x9a64bdd7,
  118. 0xbff10000,0x8fd609d9,0x2204e94f,
  119. 0x3ffd0000,0xc5402f50,0x0bbb6c2b,
  120. 0xbff10000,0xcf2ea32a,0xf216e549,
  121. 0x3fff0000,0xa0c2efd4,0xfbaf4ce2,
  122. 0x3ff80000,0xbeb5f336,0x40886df2,
  123. 0xbffd0000,0xafdf9f2f,0x8d983689,
  124. 0xbff90000,0x932b132b,0xcc3a7c5d,
  125. 0xbffd0000,0x809bdbae,0x4bcdb18d,
  126. 0xbff80000,0xb13b173f,0xdfdd379b,
  127. 0xbffb0000,0xcb1a1bb4,0x4f55bfce,
  128. 0x3ff90000,0x985953db,0x82eab3ca,
  129. 0xbffd0000,0x89cd8b3f,0x343197c4,
  130. 0xbff70000,0xd7d365ee,0xa6d44665,
  131. 0xbffe0000,0x9dd6a78c,0x9e1111dc,
  132. 0xbff70000,0x87c0c263,0x23a03b24,
  133. 0xbffd0000,0x857b6dc5,0xee15890c,
  134. 0x3ff80000,0xd65c8456,0xea1ac32a,
  135. 0x3ffe0000,0xa4819326,0x94a61090,
  136. 0x3ff80000,0xa1f30ffb,0x97a700bf,
  137. 0xbffe0000,0xb888b4d1,0x946fc0a7,
  138. 0x3ff70000,0x8c73eb9c,0x69147b77,
  139. 0xbffd0000,0xa01223e3,0x9c022457,
  140. 0xbff80000,0xa8940b66,0x20d48403,
  141. 0xbfff0000,0x850e24e1,0xf496bc90,
  142. 0xbff70000,0xe7bf088a,0xcc517ef0,
  143. 0x3fff0000,0x937c9ce6,0x69ce9bb1,
  144. 0xbff60000,0xc2a998c3,0x3fab5f93,
  145. 0x3ffe0000,0x8e88bdda,0xf62bd218,
  146. 0x3ff70000,0x977b67c8,0x1ef614b1,
  147. 0xc0010000,0x8798774b,0xc28780bc,
  148. 0xbff70000,0xa5a960de,0xc57d3b60,
  149. 0xc0000000,0xc95fd196,0x1c3098d6,
  150. 0xbff60000,0x958b041b,0x7a341187,
  151. 0xbfff0000,0x9f844602,0x04f923ae,
  152. 0xbff70000,0x8b732e55,0xfa9e6a48,
  153. 0x40010000,0xced427f1,0xe9b57aff,
  154. 0x3ff60000,0xe9865539,0xe9868447,
  155. 0x40010000,0xc351f8f8,0xbda9d31a,
  156. 0x3ff50000,0xd93c56c5,0x69e93ae0,
  157. 0x40000000,0x8fa5434b,0x41aed405,
  158. 0x3ff40000,0x89090244,0xd772637e,
  159. 0xc0030000,0x911d5ec3,0x8daa2dc9,
  160. 0xbff60000,0xf4904e1e,0xed651b24,
  161. 0xc0000000,0x9d4e0cf2,0x405f8cb1,
  162. 0xbff50000,0xd7496afa,0xfee33074,
  163. 0xbffe0000,0xd2156d01,0xa39dfc58,
  164. 0x3ff60000,0xb04857d3,0x06f3b073,
  165. 0xc0020000,0xf4df7f7a,0x3d6b7339,
  166. 0xbff50000,0xbad5c7cb,0xfaf8f24f,
  167. 0xc0030000,0xc2d01d7f,0x6c9bf85a,
  168. 0xbff40000,0xaad14d46,0x9fd87652,
  169. 0xc0020000,0x99711c71,0xb4e90c57,
  170. 0x3ff30000,0xcf306e8c,0xb8b15242,
  171. 0xc0030000,0xf27faeba,0x577edbef,
  172. 0xbff60000,0xcdf48066,0xd7d1fbf0,
  173. 0xbfff0000,0xe519fb3c,0x126783ca,
  174. 0xbff50000,0x91cf207e,0xe8769652,
  175. 0x40020000,0x89f0a78e,0x76fd9bd8,
  176. 0xbff30000,0xf05699a1,0xefba6de3,
  177. 0xbff50000,0xd1e2c835,0x08de8bb0,
  178. 0xbff30000,0x921e1640,0x36920525,
  179. 0x3ff60000,0x8044820e,0x7d61e094,
  180. 0xbff20000,0xb2fd3253,0x62f8b6af,
  181. 0x3ff40000,0xfde1cbe5,0x5313ffcb,
  182. 0xbfec0000,0xe7121630,0x22b4a7ee,
  183. 0x3ff60000,0xf7b706b1,0x2130a8b2,
  184. 0x3fed0000,0x876d6d26,0xdebd4d9d,
  185. 0x3ff60000,0xac657192,0x250be68b,
  186. 0x3feb0000,0xf2eff140,0xd3d38300,
  187. 0x3ff50000,0x8dcddeff,0x22436430,
  188. };
  189.  
  190. /* Speed of light.
  191.  */
  192. long C[] = {0x40060000,0xad2506a6,0x64a29667};
  193. /* Earth's mass divided by Moon's mass
  194.  */
  195. long EMRAT[] = {0x40050000,0xa299e68a,0x0d349be0};
  196.  
  197. /* Gaussian gravitational constant */
  198. long KG[] = {0x3ff90000,0x8ceb6a8d,0x35b4cd0f};
  199.  
  200. /* GM's of the solar system bodies
  201.  * These are scaled such that GMsun = k^2
  202.  * (k = Gaussian gravitational constant).
  203.  */
  204. long GMs[] = {
  205. 0x00000000,0x00000000,0x00000000,
  206. 0x3fdc0000,0xd80e5dff,0x79853690,
  207. 0x3fe00000,0xc71b4aac,0xb49825d0,
  208. 0x3fe00000,0xf44d93df,0xc30a6d51,
  209. 0x3fdd0000,0xd1ff1198,0x6f0cd540,
  210. 0x3fe90000,0x97af34c8,0xdaca4d10,
  211. 0x3fe70000,0xb5aa6b80,0x7d167bf0,
  212. 0x3fe40000,0xdd6abcd3,0x16eff4f0,
  213. 0x3fe50000,0x839b827f,0xefbe3fe0,
  214. 0x3fd80000,0xa02d3bee,0x86f1e570,
  215. 0x3fda0000,0xc050dde4,0xfaf09fde,
  216. 0x3ff30000,0x9b24aa0e,0x7caf3130,
  217. 0x3fd40000,0xc495060f,0xa2db6560,
  218. 0x3fd20000,0x901d7cf7,0x3ab0acd9,
  219. 0x3fd20000,0xb7bf3288,0x046e0f95,
  220. 0x3fcd0000,0xe69594be,0xc44de15b,
  221. 0x3fce0000,0xbb5988da,0xff7f471a,
  222. };
  223.  
  224. /* Astronomical unit */
  225. long AU[] = {0x40240000,0x8b52e969,0x10000000};
  226. /* kilometers: */
  227. long RADS[] = {0x40120000,0xa9ec0000,0x00000000};
  228. long RADM[] = {0x40090000,0xd9400000,0x00000000};
  229. long RADE[] = {0x400b0000,0xc7511eb8,0x51eb851f};
  230. /* equatorial radius of Earth, in au */
  231. long AE[] = {0x3ff00000,0xb2d33b79,0x342ee7e0};
  232. long Je[] = {
  233. 0x3ff50000,0x8de708e3,0x2883d7bb,
  234. 0xbfec0000,0xaa74de23,0x61590b5f,
  235. 0xbfeb0000,0xd8172dc4,0x0883065a,
  236. };
  237. /* equatorial radius of Moon, in au */
  238. long AM[] = {0x3fee0000,0xc2ea1fd7,0xcef2d0d0};
  239. long Jm[] = {
  240. 0x3ff20000,0xd3f8789c,0xb385b2bf,
  241. 0x3fee0000,0xcb70f759,0x3b59010a,
  242. 0xbfe80000,0x9c1a93a1,0xe6df5968,
  243. };
  244. long