Jpp  17.2.0
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JNOAA.hh
Go to the documentation of this file.
1 #ifndef __JCOMPASS__JNOAA__
2 #define __JCOMPASS__JNOAA__
3 
4 #include <string>
5 #include <ostream>
6 
7 #include "JTools/JConstants.hh"
9 
10 #include "JLang/JTitle.hh"
11 #include "JLang/JManip.hh"
12 
13 
14 namespace JCOMPASS {}
15 namespace JPP { using namespace JCOMPASS; }
16 
17 namespace JCOMPASS {
18 
19  using JLANG::JTitle;
20 
21  /**
22  * Auxiliary base class for interpolation of magnetic declination data obtained
23  * from website of <a href="https://www.ngdc.noaa.gov/geomag/calculators/magcalc.shtml">NOAA</a>.\n
24  */
27  public JTitle
28  {
29  /**
30  * Write function to output stream.
31  *
32  * \param out output stream
33  * \param object function
34  * \return output stream
35  */
36  friend inline std::ostream& operator<<(std::ostream& out, const JNOAAFunction1D_t& object)
37  {
38  return out << object.getTitle() << ' ' << "[" << FIXED(12,0) << object.getXmin() << "," << FIXED(12,0) << object.getXmax() << "]";
39  }
40 
41 
42  protected:
43  /**
44  * Constructor.
45  *
46  * \param title title
47  */
48  JNOAAFunction1D_t(const std::string& title) :
49  JTitle(title)
50  {}
51 
52 
53  /**
54  * Function compilation.
55  *
56  * Convert degrees to radians.
57  */
58  virtual void do_compile() override
59  {
60  using namespace JPP;
61 
62  for (iterator i = this->begin(); i != this->end(); ++i) {
63  i->getY() *= PI / 180.0;
64  }
65 
67  }
68  };
69 
70 
71  /**
72  * Interpolation of magnetic declination data at ARCA site.
73  *
74  * The data have been converted using the scripts by Vladimir Kulikovski,
75  * see GIT <a href="https://git.km3net.de/vkulikovskiy/TiltCompass">repository</a>.
76  */
78  public JNOAAFunction1D_t
79  {
80  /**
81  * Default constructor.
82  */
84  JNOAAFunction1D_t("ARCA")
85  {
86  (*this)[ 946684800] = 1.695480;
87  (*this)[ 949363200] = 1.701550;
88  (*this)[ 951868800] = 1.707230;
89  (*this)[ 954547200] = 1.713300;
90  (*this)[ 957139200] = 1.719180;
91  (*this)[ 959817600] = 1.725250;
92  (*this)[ 962409600] = 1.731120;
93  (*this)[ 965088000] = 1.737190;
94  (*this)[ 967766400] = 1.743260;
95  (*this)[ 970358400] = 1.749130;
96  (*this)[ 973036800] = 1.755200;
97  (*this)[ 975628800] = 1.761070;
98  (*this)[ 978307200] = 1.767140;
99  (*this)[ 980985600] = 1.773220;
100  (*this)[ 983404800] = 1.778720;
101  (*this)[ 986083200] = 1.784800;
102  (*this)[ 988675200] = 1.790680;
103  (*this)[ 991353600] = 1.796770;
104  (*this)[ 993945600] = 1.802650;
105  (*this)[ 996624000] = 1.808730;
106  (*this)[ 999302400] = 1.814810;
107  (*this)[1001894400] = 1.820700;
108  (*this)[1004572800] = 1.826780;
109  (*this)[1007164800] = 1.832660;
110  (*this)[1009843200] = 1.838740;
111  (*this)[1012521600] = 1.844820;
112  (*this)[1014940800] = 1.850310;
113  (*this)[1017619200] = 1.856380;
114  (*this)[1020211200] = 1.862270;
115  (*this)[1022889600] = 1.868340;
116  (*this)[1025481600] = 1.874220;
117  (*this)[1028160000] = 1.880300;
118  (*this)[1030838400] = 1.886370;
119  (*this)[1033430400] = 1.892250;
120  (*this)[1036108800] = 1.898330;
121  (*this)[1038700800] = 1.904210;
122  (*this)[1041379200] = 1.910280;
123  (*this)[1044057600] = 1.916350;
124  (*this)[1046476800] = 1.921840;
125  (*this)[1049155200] = 1.927910;
126  (*this)[1051747200] = 1.933790;
127  (*this)[1054425600] = 1.939860;
128  (*this)[1057017600] = 1.945740;
129  (*this)[1059696000] = 1.951810;
130  (*this)[1062374400] = 1.957880;
131  (*this)[1064966400] = 1.963750;
132  (*this)[1067644800] = 1.969820;
133  (*this)[1070236800] = 1.975700;
134  (*this)[1072915200] = 1.981770;
135  (*this)[1075593600] = 1.987820;
136  (*this)[1078099200] = 1.993480;
137  (*this)[1080777600] = 1.999530;
138  (*this)[1083369600] = 2.005390;
139  (*this)[1086048000] = 2.011440;
140  (*this)[1088640000] = 2.017290;
141  (*this)[1091318400] = 2.023340;
142  (*this)[1093996800] = 2.029390;
143  (*this)[1096588800] = 2.035250;
144  (*this)[1099267200] = 2.041300;
145  (*this)[1101859200] = 2.047150;
146  (*this)[1104537600] = 2.053200;
147  (*this)[1107216000] = 2.060830;
148  (*this)[1109635200] = 2.067720;
149  (*this)[1112313600] = 2.075350;
150  (*this)[1114905600] = 2.082730;
151  (*this)[1117584000] = 2.090350;
152  (*this)[1120176000] = 2.097730;
153  (*this)[1122854400] = 2.105360;
154  (*this)[1125532800] = 2.112980;
155  (*this)[1128124800] = 2.120360;
156  (*this)[1130803200] = 2.127980;
157  (*this)[1133395200] = 2.135360;
158  (*this)[1136073600] = 2.142980;
159  (*this)[1138752000] = 2.150600;
160  (*this)[1141171200] = 2.157480;
161  (*this)[1143849600] = 2.165100;
162  (*this)[1146441600] = 2.172470;
163  (*this)[1149120000] = 2.180090;
164  (*this)[1151712000] = 2.187460;
165  (*this)[1154390400] = 2.195070;
166  (*this)[1157068800] = 2.202690;
167  (*this)[1159660800] = 2.210060;
168  (*this)[1162339200] = 2.217670;
169  (*this)[1164931200] = 2.225030;
170  (*this)[1167609600] = 2.232650;
171  (*this)[1170288000] = 2.240260;
172  (*this)[1172707200] = 2.247130;
173  (*this)[1175385600] = 2.254740;
174  (*this)[1177977600] = 2.262100;
175  (*this)[1180656000] = 2.269710;
176  (*this)[1183248000] = 2.277070;
177  (*this)[1185926400] = 2.284670;
178  (*this)[1188604800] = 2.292280;
179  (*this)[1191196800] = 2.299630;
180  (*this)[1193875200] = 2.307240;
181  (*this)[1196467200] = 2.314590;
182  (*this)[1199145600] = 2.322190;
183  (*this)[1201824000] = 2.329770;
184  (*this)[1204329600] = 2.336860;
185  (*this)[1207008000] = 2.344440;
186  (*this)[1209600000] = 2.351770;
187  (*this)[1212278400] = 2.359350;
188  (*this)[1214870400] = 2.366680;
189  (*this)[1217548800] = 2.374250;
190  (*this)[1220227200] = 2.381830;
191  (*this)[1222819200] = 2.389160;
192  (*this)[1225497600] = 2.396730;
193  (*this)[1228089600] = 2.404050;
194  (*this)[1230768000] = 2.411630;
195  (*this)[1233446400] = 2.419220;
196  (*this)[1235865600] = 2.426070;
197  (*this)[1238544000] = 2.433660;
198  (*this)[1241136000] = 2.441000;
199  (*this)[1243814400] = 2.448590;
200  (*this)[1246406400] = 2.455930;
201  (*this)[1249084800] = 2.463510;
202  (*this)[1251763200] = 2.471100;
203  (*this)[1254355200] = 2.478440;
204  (*this)[1257033600] = 2.486020;
205  (*this)[1259625600] = 2.493360;
206  (*this)[1262304000] = 2.500940;
207  (*this)[1264982400] = 2.509630;
208  (*this)[1267401600] = 2.517480;
209  (*this)[1270080000] = 2.526170;
210  (*this)[1272672000] = 2.534580;
211  (*this)[1275350400] = 2.543270;
212  (*this)[1277942400] = 2.551670;
213  (*this)[1280620800] = 2.560360;
214  (*this)[1283299200] = 2.569050;
215  (*this)[1285891200] = 2.577450;
216  (*this)[1288569600] = 2.586130;
217  (*this)[1291161600] = 2.594540;
218  (*this)[1293840000] = 2.603220;
219  (*this)[1296518400] = 2.611900;
220  (*this)[1298937600] = 2.619740;
221  (*this)[1301616000] = 2.628420;
222  (*this)[1304208000] = 2.636820;
223  (*this)[1306886400] = 2.645500;
224  (*this)[1309478400] = 2.653890;
225  (*this)[1312156800] = 2.662570;
226  (*this)[1314835200] = 2.671240;
227  (*this)[1317427200] = 2.679640;
228  (*this)[1320105600] = 2.688310;
229  (*this)[1322697600] = 2.696710;
230  (*this)[1325376000] = 2.705380;
231  (*this)[1328054400] = 2.714020;
232  (*this)[1330560000] = 2.722110;
233  (*this)[1333238400] = 2.730760;
234  (*this)[1335830400] = 2.739120;
235  (*this)[1338508800] = 2.747770;
236  (*this)[1341100800] = 2.756130;
237  (*this)[1343779200] = 2.764770;
238  (*this)[1346457600] = 2.773410;
239  (*this)[1349049600] = 2.781770;
240  (*this)[1351728000] = 2.790410;
241  (*this)[1354320000] = 2.798770;
242  (*this)[1356998400] = 2.807410;
243  (*this)[1359676800] = 2.816070;
244  (*this)[1362096000] = 2.823890;
245  (*this)[1364774400] = 2.832550;
246  (*this)[1367366400] = 2.840930;
247  (*this)[1370044800] = 2.849580;
248  (*this)[1372636800] = 2.857960;
249  (*this)[1375315200] = 2.866610;
250  (*this)[1377993600] = 2.875270;
251  (*this)[1380585600] = 2.883640;
252  (*this)[1383264000] = 2.892290;
253  (*this)[1385856000] = 2.900670;
254  (*this)[1388534400] = 2.909320;
255  (*this)[1391212800] = 2.917970;
256  (*this)[1393632000] = 2.925780;
257  (*this)[1396310400] = 2.934420;
258  (*this)[1398902400] = 2.942790;
259  (*this)[1401580800] = 2.951440;
260  (*this)[1404172800] = 2.959800;
261  (*this)[1406851200] = 2.968450;
262  (*this)[1409529600] = 2.977090;
263  (*this)[1412121600] = 2.985460;
264  (*this)[1414800000] = 2.994100;
265  (*this)[1417392000] = 3.002460;
266  (*this)[1420070400] = 3.011100;
267  (*this)[1422748800] = 3.020800;
268  (*this)[1425168000] = 3.029560;
269  (*this)[1427846400] = 3.039260;
270  (*this)[1430438400] = 3.048640;
271  (*this)[1433116800] = 3.058340;
272  (*this)[1435708800] = 3.067720;
273  (*this)[1438387200] = 3.077420;
274  (*this)[1441065600] = 3.087110;
275  (*this)[1443657600] = 3.096490;
276  (*this)[1446336000] = 3.106180;
277  (*this)[1448928000] = 3.115560;
278  (*this)[1451606400] = 3.125250;
279  (*this)[1454284800] = 3.134910;
280  (*this)[1456790400] = 3.143950;
281  (*this)[1459468800] = 3.153610;
282  (*this)[1462060800] = 3.162950;
283  (*this)[1464739200] = 3.172610;
284  (*this)[1467331200] = 3.181960;
285  (*this)[1470009600] = 3.191610;
286  (*this)[1472688000] = 3.201270;
287  (*this)[1475280000] = 3.210610;
288  (*this)[1477958400] = 3.220260;
289  (*this)[1480550400] = 3.229600;
290  (*this)[1483228800] = 3.239250;
291  (*this)[1485907200] = 3.248930;
292  (*this)[1488326400] = 3.257670;
293  (*this)[1491004800] = 3.267340;
294  (*this)[1493596800] = 3.276700;
295  (*this)[1496275200] = 3.286370;
296  (*this)[1498867200] = 3.295730;
297  (*this)[1501545600] = 3.305400;
298  (*this)[1504224000] = 3.315070;
299  (*this)[1506816000] = 3.324420;
300  (*this)[1509494400] = 3.334090;
301  (*this)[1512086400] = 3.343450;
302  (*this)[1514764800] = 3.353110;
303  (*this)[1517443200] = 3.362770;
304  (*this)[1519862400] = 3.371500;
305  (*this)[1522540800] = 3.381160;
306  (*this)[1525132800] = 3.390510;
307  (*this)[1527811200] = 3.400170;
308  (*this)[1530403200] = 3.409520;
309  (*this)[1533081600] = 3.419170;
310  (*this)[1535760000] = 3.428830;
311  (*this)[1538352000] = 3.438170;
312  (*this)[1541030400] = 3.447830;
313  (*this)[1543622400] = 3.457170;
314  (*this)[1546300800] = 3.466820;
315  (*this)[1548979200] = 3.476470;
316  (*this)[1551398400] = 3.485190;
317  (*this)[1554076800] = 3.494840;
318  (*this)[1556668800] = 3.504170;
319  (*this)[1559347200] = 3.513820;
320  (*this)[1561939200] = 3.523160;
321  (*this)[1564617600] = 3.532800;
322  (*this)[1567296000] = 3.542440;
323  (*this)[1569888000] = 3.551780;
324  (*this)[1572566400] = 3.561420;
325  (*this)[1575158400] = 3.570750;
326  (*this)[1577836800] = 3.580390;
327  (*this)[1580515200] = 3.589700;
328  (*this)[1583020800] = 3.598420;
329  (*this)[1585699200] = 3.607730;
330  (*this)[1588291200] = 3.616750;
331  (*this)[1590969600] = 3.626060;
332  (*this)[1593561600] = 3.635070;
333  (*this)[1596240000] = 3.644380;
334  (*this)[1598918400] = 3.653690;
335  (*this)[1601510400] = 3.662700;
336  (*this)[1604188800] = 3.672010;
337  (*this)[1606780800] = 3.681020;
338  (*this)[1609459200] = 3.690320;
339  (*this)[1612137600] = 3.699660;
340  (*this)[1614556800] = 3.708080;
341  (*this)[1617235200] = 3.717410;
342  (*this)[1619827200] = 3.726440;
343  (*this)[1622505600] = 3.735770;
344  (*this)[1625097600] = 3.744800;
345  (*this)[1627776000] = 3.754120;
346  (*this)[1630454400] = 3.763450;
347  (*this)[1633046400] = 3.772470;
348  (*this)[1635724800] = 3.781800;
349  (*this)[1638316800] = 3.790820;
350  (*this)[1640995200] = 3.800140;
351  (*this)[1643673600] = 3.809460;
352  (*this)[1646092800] = 3.817880;
353  (*this)[1648771200] = 3.827200;
354  (*this)[1651363200] = 3.836220;
355  (*this)[1654041600] = 3.845540;
356  (*this)[1656633600] = 3.854550;
357  (*this)[1659312000] = 3.863870;
358  (*this)[1661990400] = 3.873180;
359  (*this)[1664582400] = 3.882200;
360  (*this)[1667260800] = 3.891510;
361  (*this)[1669852800] = 3.900520;
362  (*this)[1672531200] = 3.909830;
363  (*this)[1675209600] = 3.919150;
364  (*this)[1677628800] = 3.927550;
365  (*this)[1680307200] = 3.936860;
366  (*this)[1682899200] = 3.945870;
367  (*this)[1685577600] = 3.955180;
368  (*this)[1688169600] = 3.964180;
369  (*this)[1690848000] = 3.973490;
370  (*this)[1693526400] = 3.982800;
371  (*this)[1696118400] = 3.991800;
372  (*this)[1698796800] = 4.001100;
373  (*this)[1701388800] = 4.010100;
374  (*this)[1704067200] = 4.019410;
375  (*this)[1706745600] = 4.028680;
376  (*this)[1709251200] = 4.037360;
377  (*this)[1711929600] = 4.046630;
378  (*this)[1714521600] = 4.055600;
379  (*this)[1717200000] = 4.064870;
380  (*this)[1719792000] = 4.073840;
381  (*this)[1722470400] = 4.083110;
382  (*this)[1725148800] = 4.092380;
383  (*this)[1727740800] = 4.101350;
384  (*this)[1730419200] = 4.110620;
385  (*this)[1733011200] = 4.119590;
386 
387  compile();
388  }
389  };
390 
391 
392  /**
393  * Interpolation of magnetic declination data at ORCA site.
394  *
395  * The data have been converted using the scripts by Vladimir Kulikovski,
396  * see GIT <a href="https://git.km3net.de/vkulikovskiy/TiltCompass">repository</a>.
397  */
399  public JNOAAFunction1D_t
400  {
401  /**
402  * Default constructor.
403  */
405  JNOAAFunction1D_t("ORCA")
406  {
407  (*this)[ 946684800] = -0.280210;
408  (*this)[ 949363200] = -0.271470;
409  (*this)[ 951868800] = -0.263290;
410  (*this)[ 954547200] = -0.254560;
411  (*this)[ 957139200] = -0.246100;
412  (*this)[ 959817600] = -0.237370;
413  (*this)[ 962409600] = -0.228910;
414  (*this)[ 965088000] = -0.220180;
415  (*this)[ 967766400] = -0.211450;
416  (*this)[ 970358400] = -0.203000;
417  (*this)[ 973036800] = -0.194260;
418  (*this)[ 975628800] = -0.185820;
419  (*this)[ 978307200] = -0.177080;
420  (*this)[ 980985600] = -0.168330;
421  (*this)[ 983404800] = -0.160430;
422  (*this)[ 986083200] = -0.151670;
423  (*this)[ 988675200] = -0.143200;
424  (*this)[ 991353600] = -0.134450;
425  (*this)[ 993945600] = -0.125990;
426  (*this)[ 996624000] = -0.117240;
427  (*this)[ 999302400] = -0.108490;
428  (*this)[1001894400] = -0.100020;
429  (*this)[1004572800] = -0.091270;
430  (*this)[1007164800] = -0.082810;
431  (*this)[1009843200] = -0.074070;
432  (*this)[1012521600] = -0.065320;
433  (*this)[1014940800] = -0.057420;
434  (*this)[1017619200] = -0.048680;
435  (*this)[1020211200] = -0.040220;
436  (*this)[1022889600] = -0.031480;
437  (*this)[1025481600] = -0.023020;
438  (*this)[1028160000] = -0.014280;
439  (*this)[1030838400] = -0.005540;
440  (*this)[1033430400] = 0.002920;
441  (*this)[1036108800] = 0.011660;
442  (*this)[1038700800] = 0.020120;
443  (*this)[1041379200] = 0.028850;
444  (*this)[1044057600] = 0.037590;
445  (*this)[1046476800] = 0.045480;
446  (*this)[1049155200] = 0.054210;
447  (*this)[1051747200] = 0.062670;
448  (*this)[1054425600] = 0.071400;
449  (*this)[1057017600] = 0.079850;
450  (*this)[1059696000] = 0.088580;
451  (*this)[1062374400] = 0.097310;
452  (*this)[1064966400] = 0.105760;
453  (*this)[1067644800] = 0.114490;
454  (*this)[1070236800] = 0.122940;
455  (*this)[1072915200] = 0.131670;
456  (*this)[1075593600] = 0.140370;
457  (*this)[1078099200] = 0.148510;
458  (*this)[1080777600] = 0.157210;
459  (*this)[1083369600] = 0.165630;
460  (*this)[1086048000] = 0.174330;
461  (*this)[1088640000] = 0.182750;
462  (*this)[1091318400] = 0.191450;
463  (*this)[1093996800] = 0.200150;
464  (*this)[1096588800] = 0.208570;
465  (*this)[1099267200] = 0.217270;
466  (*this)[1101859200] = 0.225680;
467  (*this)[1104537600] = 0.234380;
468  (*this)[1107216000] = 0.243640;
469  (*this)[1109635200] = 0.252010;
470  (*this)[1112313600] = 0.261270;
471  (*this)[1114905600] = 0.270230;
472  (*this)[1117584000] = 0.279490;
473  (*this)[1120176000] = 0.288450;
474  (*this)[1122854400] = 0.297710;
475  (*this)[1125532800] = 0.306970;
476  (*this)[1128124800] = 0.315920;
477  (*this)[1130803200] = 0.325180;
478  (*this)[1133395200] = 0.334130;
479  (*this)[1136073600] = 0.343390;
480  (*this)[1138752000] = 0.352640;
481  (*this)[1141171200] = 0.360990;
482  (*this)[1143849600] = 0.370240;
483  (*this)[1146441600] = 0.379190;
484  (*this)[1149120000] = 0.388430;
485  (*this)[1151712000] = 0.397380;
486  (*this)[1154390400] = 0.406630;
487  (*this)[1157068800] = 0.415870;
488  (*this)[1159660800] = 0.424810;
489  (*this)[1162339200] = 0.434050;
490  (*this)[1164931200] = 0.442990;
491  (*this)[1167609600] = 0.452230;
492  (*this)[1170288000] = 0.461470;
493  (*this)[1172707200] = 0.469810;
494  (*this)[1175385600] = 0.479050;
495  (*this)[1177977600] = 0.487980;
496  (*this)[1180656000] = 0.497210;
497  (*this)[1183248000] = 0.506150;
498  (*this)[1185926400] = 0.515380;
499  (*this)[1188604800] = 0.524610;
500  (*this)[1191196800] = 0.533540;
501  (*this)[1193875200] = 0.542760;
502  (*this)[1196467200] = 0.551690;
503  (*this)[1199145600] = 0.560920;
504  (*this)[1201824000] = 0.570110;
505  (*this)[1204329600] = 0.578720;
506  (*this)[1207008000] = 0.587910;
507  (*this)[1209600000] = 0.596810;
508  (*this)[1212278400] = 0.606000;
509  (*this)[1214870400] = 0.614900;
510  (*this)[1217548800] = 0.624090;
511  (*this)[1220227200] = 0.633280;
512  (*this)[1222819200] = 0.642170;
513  (*this)[1225497600] = 0.651360;
514  (*this)[1228089600] = 0.660250;
515  (*this)[1230768000] = 0.669440;
516  (*this)[1233446400] = 0.678650;
517  (*this)[1235865600] = 0.686960;
518  (*this)[1238544000] = 0.696170;
519  (*this)[1241136000] = 0.705080;
520  (*this)[1243814400] = 0.714280;
521  (*this)[1246406400] = 0.723190;
522  (*this)[1249084800] = 0.732390;
523  (*this)[1251763200] = 0.741590;
524  (*this)[1254355200] = 0.750500;
525  (*this)[1257033600] = 0.759700;
526  (*this)[1259625600] = 0.768600;
527  (*this)[1262304000] = 0.777790;
528  (*this)[1264982400] = 0.788410;
529  (*this)[1267401600] = 0.798000;
530  (*this)[1270080000] = 0.808610;
531  (*this)[1272672000] = 0.818880;
532  (*this)[1275350400] = 0.829500;
533  (*this)[1277942400] = 0.839760;
534  (*this)[1280620800] = 0.850370;
535  (*this)[1283299200] = 0.860980;
536  (*this)[1285891200] = 0.871250;
537  (*this)[1288569600] = 0.881850;
538  (*this)[1291161600] = 0.892120;
539  (*this)[1293840000] = 0.902720;
540  (*this)[1296518400] = 0.913320;
541  (*this)[1298937600] = 0.922900;
542  (*this)[1301616000] = 0.933500;
543  (*this)[1304208000] = 0.943750;
544  (*this)[1306886400] = 0.954350;
545  (*this)[1309478400] = 0.964610;
546  (*this)[1312156800] = 0.975200;
547  (*this)[1314835200] = 0.985790;
548  (*this)[1317427200] = 0.996040;
549  (*this)[1320105600] = 1.006640;
550  (*this)[1322697600] = 1.016880;
551  (*this)[1325376000] = 1.027470;
552  (*this)[1328054400] = 1.038030;
553  (*this)[1330560000] = 1.047910;
554  (*this)[1333238400] = 1.058460;
555  (*this)[1335830400] = 1.068680;
556  (*this)[1338508800] = 1.079230;
557  (*this)[1341100800] = 1.089440;
558  (*this)[1343779200] = 1.100000;
559  (*this)[1346457600] = 1.110550;
560  (*this)[1349049600] = 1.120750;
561  (*this)[1351728000] = 1.131300;
562  (*this)[1354320000] = 1.141510;
563  (*this)[1356998400] = 1.152050;
564  (*this)[1359676800] = 1.162630;
565  (*this)[1362096000] = 1.172170;
566  (*this)[1364774400] = 1.182750;
567  (*this)[1367366400] = 1.192970;
568  (*this)[1370044800] = 1.203540;
569  (*this)[1372636800] = 1.213770;
570  (*this)[1375315200] = 1.224330;
571  (*this)[1377993600] = 1.234900;
572  (*this)[1380585600] = 1.245120;
573  (*this)[1383264000] = 1.255680;
574  (*this)[1385856000] = 1.265900;
575  (*this)[1388534400] = 1.276460;
576  (*this)[1391212800] = 1.287020;
577  (*this)[1393632000] = 1.296550;
578  (*this)[1396310400] = 1.307110;
579  (*this)[1398902400] = 1.317320;
580  (*this)[1401580800] = 1.327870;
581  (*this)[1404172800] = 1.338090;
582  (*this)[1406851200] = 1.348640;
583  (*this)[1409529600] = 1.359190;
584  (*this)[1412121600] = 1.369390;
585  (*this)[1414800000] = 1.379940;
586  (*this)[1417392000] = 1.390150;
587  (*this)[1420070400] = 1.400690;
588  (*this)[1422748800] = 1.412860;
589  (*this)[1425168000] = 1.423850;
590  (*this)[1427846400] = 1.436010;
591  (*this)[1430438400] = 1.447780;
592  (*this)[1433116800] = 1.459940;
593  (*this)[1435708800] = 1.471710;
594  (*this)[1438387200] = 1.483870;
595  (*this)[1441065600] = 1.496020;
596  (*this)[1443657600] = 1.507790;
597  (*this)[1446336000] = 1.519940;
598  (*this)[1448928000] = 1.531700;
599  (*this)[1451606400] = 1.543850;
600  (*this)[1454284800] = 1.555970;
601  (*this)[1456790400] = 1.567300;
602  (*this)[1459468800] = 1.579410;
603  (*this)[1462060800] = 1.591140;
604  (*this)[1464739200] = 1.603250;
605  (*this)[1467331200] = 1.614960;
606  (*this)[1470009600] = 1.627070;
607  (*this)[1472688000] = 1.639180;
608  (*this)[1475280000] = 1.650890;
609  (*this)[1477958400] = 1.663000;
610  (*this)[1480550400] = 1.674710;
611  (*this)[1483228800] = 1.686810;
612  (*this)[1485907200] = 1.698940;
613  (*this)[1488326400] = 1.709900;
614  (*this)[1491004800] = 1.722030;
615  (*this)[1493596800] = 1.733760;
616  (*this)[1496275200] = 1.745890;
617  (*this)[1498867200] = 1.757620;
618  (*this)[1501545600] = 1.769750;
619  (*this)[1504224000] = 1.781870;
620  (*this)[1506816000] = 1.793600;
621  (*this)[1509494400] = 1.805720;
622  (*this)[1512086400] = 1.817450;
623  (*this)[1514764800] = 1.829560;
624  (*this)[1517443200] = 1.841680;
625  (*this)[1519862400] = 1.852620;
626  (*this)[1522540800] = 1.864730;
627  (*this)[1525132800] = 1.876450;
628  (*this)[1527811200] = 1.888560;
629  (*this)[1530403200] = 1.900280;
630  (*this)[1533081600] = 1.912380;
631  (*this)[1535760000] = 1.924490;
632  (*this)[1538352000] = 1.936200;
633  (*this)[1541030400] = 1.948300;
634  (*this)[1543622400] = 1.960010;
635  (*this)[1546300800] = 1.972110;
636  (*this)[1548979200] = 1.984210;
637  (*this)[1551398400] = 1.995130;
638  (*this)[1554076800] = 2.007230;
639  (*this)[1556668800] = 2.018930;
640  (*this)[1559347200] = 2.031020;
641  (*this)[1561939200] = 2.042720;
642  (*this)[1564617600] = 2.054810;
643  (*this)[1567296000] = 2.066900;
644  (*this)[1569888000] = 2.078590;
645  (*this)[1572566400] = 2.090680;
646  (*this)[1575158400] = 2.102370;
647  (*this)[1577836800] = 2.114450;
648  (*this)[1580515200] = 2.127360;
649  (*this)[1583020800] = 2.139440;
650  (*this)[1585699200] = 2.152350;
651  (*this)[1588291200] = 2.164850;
652  (*this)[1590969600] = 2.177760;
653  (*this)[1593561600] = 2.190250;
654  (*this)[1596240000] = 2.203150;
655  (*this)[1598918400] = 2.216060;
656  (*this)[1601510400] = 2.228540;
657  (*this)[1604188800] = 2.241440;
658  (*this)[1606780800] = 2.253930;
659  (*this)[1609459200] = 2.266830;
660  (*this)[1612137600] = 2.279760;
661  (*this)[1614556800] = 2.291440;
662  (*this)[1617235200] = 2.304370;
663  (*this)[1619827200] = 2.316880;
664  (*this)[1622505600] = 2.329810;
665  (*this)[1625097600] = 2.342320;
666  (*this)[1627776000] = 2.355240;
667  (*this)[1630454400] = 2.368160;
668  (*this)[1633046400] = 2.380670;
669  (*this)[1635724800] = 2.393590;
670  (*this)[1638316800] = 2.406090;
671  (*this)[1640995200] = 2.419010;
672  (*this)[1643673600] = 2.431920;
673  (*this)[1646092800] = 2.443590;
674  (*this)[1648771200] = 2.456500;
675  (*this)[1651363200] = 2.469000;
676  (*this)[1654041600] = 2.481910;
677  (*this)[1656633600] = 2.494400;
678  (*this)[1659312000] = 2.507310;
679  (*this)[1661990400] = 2.520210;
680  (*this)[1664582400] = 2.532700;
681  (*this)[1667260800] = 2.545610;
682  (*this)[1669852800] = 2.558090;
683  (*this)[1672531200] = 2.570990;
684  (*this)[1675209600] = 2.583890;
685  (*this)[1677628800] = 2.595540;
686  (*this)[1680307200] = 2.608440;
687  (*this)[1682899200] = 2.620920;
688  (*this)[1685577600] = 2.633810;
689  (*this)[1688169600] = 2.646280;
690  (*this)[1690848000] = 2.659180;
691  (*this)[1693526400] = 2.672060;
692  (*this)[1696118400] = 2.684540;
693  (*this)[1698796800] = 2.697420;
694  (*this)[1701388800] = 2.709890;
695  (*this)[1704067200] = 2.722780;
696  (*this)[1706745600] = 2.735620;
697  (*this)[1709251200] = 2.747640;
698  (*this)[1711929600] = 2.760480;
699  (*this)[1714521600] = 2.772910;
700  (*this)[1717200000] = 2.785750;
701  (*this)[1719792000] = 2.798180;
702  (*this)[1722470400] = 2.811020;
703  (*this)[1725148800] = 2.823850;
704  (*this)[1727740800] = 2.836270;
705  (*this)[1730419200] = 2.849110;
706  (*this)[1733011200] = 2.861530;
707 
708  compile();
709  }
710  };
711 
712 
713  /**
714  * Fall back class for zero magnetic declination.
715  */
717  public JNOAAFunction1D_t
718  {
719  /**
720  * Default constructor.
721  */
723  JNOAAFunction1D_t("zero")
724  {
725  this->setExceptionHandler(new JNOAAFunction1D_t::JDefaultResult(0.0));
726  }
727  };
728 
729 
730  static JARCAMagneticDeclination getARCAMagneticDeclination; //!< Function object for magnetic declination at ARCA site.
731  static JORCAMagneticDeclination getORCAMagneticDeclination; //!< Function object for magnetic declination at ORCA site.
732  static JZEROMagneticDeclination getZEROMagneticDeclination; //!< Function object for zero magnetic declination.
733 }
734 
735 #endif
static JARCAMagneticDeclination getARCAMagneticDeclination
Function object for magnetic declination at ARCA site.
Definition: JNOAA.hh:730
Interpolation of magnetic declination data at ORCA site.
Definition: JNOAA.hh:398
static JZEROMagneticDeclination getZEROMagneticDeclination
Function object for zero magnetic declination.
Definition: JNOAA.hh:732
virtual void do_compile() override
Function compilation.
Definition: JPolint.hh:771
Fall back class for zero magnetic declination.
Definition: JNOAA.hh:716
Auxiliary data structure for floating point format specification.
Definition: JManip.hh:446
static JORCAMagneticDeclination getORCAMagneticDeclination
Function object for magnetic declination at ORCA site.
Definition: JNOAA.hh:731
JNOAAFunction1D_t(const std::string &title)
Constructor.
Definition: JNOAA.hh:48
Type definition of a 1st degree polynomial interpolation based on a JGridCollection with result type ...
friend std::ostream & operator<<(std::ostream &out, const JNOAAFunction1D_t &object)
Write function to output stream.
Definition: JNOAA.hh:36
JZEROMagneticDeclination()
Default constructor.
Definition: JNOAA.hh:722
Auxiliary base class for interpolation of magnetic declination data obtained from website of NOAA...
Definition: JNOAA.hh:25
Auxiliary class for title.
Definition: JTitle.hh:19
static const double PI
Mathematical constants.
I/O manipulators.
void setExceptionHandler(const JSupervisor &supervisor)
Set the supervisor for handling of exceptions.
Definition: JFunctional.hh:288
Constants.
JORCAMagneticDeclination()
Default constructor.
Definition: JNOAA.hh:404
std::string title
Definition: JTitle.hh:73
virtual void do_compile() override
Function compilation.
Definition: JNOAA.hh:58
JARCAMagneticDeclination()
Default constructor.
Definition: JNOAA.hh:83
Interpolation of magnetic declination data at ARCA site.
Definition: JNOAA.hh:77