diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 840719b3..8d71d843 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -4,11 +4,13 @@
-
-
-
-
-
+
+
+
+
+
+
+
@@ -316,7 +318,7 @@
-
+
@@ -326,10 +328,10 @@
+
-
@@ -337,10 +339,10 @@
+
+
-
-
@@ -370,17 +372,15 @@
-
+
+
-
+
-
-
-
@@ -418,17 +418,17 @@
-
+
+
-
@@ -480,13 +480,6 @@
-
- 1629291897935
-
-
-
- 1629291897935
-
1629292088005
@@ -823,7 +816,14 @@
1642956543110
-
+
+ 1642956703670
+
+
+
+ 1642956703670
+
+
@@ -935,7 +935,6 @@
-
@@ -960,7 +959,8 @@
-
+
+
diff --git a/EphemerisFiles/orbitParsGalileoJupiter.txt b/EphemerisFiles/orbitParsGalileoJupiter.txt
index 151e03ba..4e5e644a 100644
--- a/EphemerisFiles/orbitParsGalileoJupiter.txt
+++ b/EphemerisFiles/orbitParsGalileoJupiter.txt
@@ -13,159 +13,211 @@
%
% Generated via AstroQuery-python interface (JPL HORIZONS database)
%
-155
-2447818.583333 0.778888 0.280053 7.421010 184.294081 25.707903 2447698.041587 1.433811
-2447819.500000 0.824597 0.208942 4.632657 184.921983 25.574765 2447687.169866 1.316260
-2447842.500000 0.832374 0.197801 4.328467 184.720944 25.339617 2447962.104463 1.297856
-2447883.500000 0.832638 0.197418 4.317819 184.780695 25.238812 2447962.133509 1.297237
-2447932.500000 0.842407 0.209606 4.409859 186.161386 23.661939 2447961.789772 1.274739
-2447934.500000 0.994849 0.297933 3.381004 107.179296 76.463983 2447947.934625 0.993272
-2447994.500000 0.989104 0.294469 3.382366 106.817773 76.479287 2447947.765756 1.001938
-2448024.500000 0.988457 0.294572 3.390234 106.592867 76.579015 2447947.717718 1.002922
-2448090.500000 0.988424 0.294602 3.390107 106.577500 76.587775 2447947.716081 1.002973
-2448174.500000 0.988402 0.294644 3.389869 106.575288 76.587950 2448306.638511 1.003006
-2448209.500000 0.988415 0.294705 3.388801 106.564037 76.593808 2448306.626434 1.002987
-2448224.500000 0.988396 0.294819 3.390225 106.574675 76.588146 2448306.616180 1.003016
-2448233.500000 0.988810 0.296691 3.413705 106.613572 76.573091 2448306.463272 1.002385
-2448235.500000 1.593798 0.432591 4.558985 223.155615 256.647072 2448267.725698 0.489840
-2448245.500000 1.588640 0.430541 4.543657 223.125225 256.645026 2448267.732668 0.492228
-2448336.500000 1.587560 0.430212 4.540785 223.077868 256.662905 2448267.712786 0.492730
-2448440.500000 1.587244 0.430305 4.545805 223.061658 256.655666 2448267.718926 0.492877
-2448539.500000 1.587268 0.430288 4.546675 223.059230 256.660419 2448267.717735 0.492866
-2448554.500000 1.587281 0.430279 4.545565 223.066750 256.653737 2448267.716396 0.492860
-2448849.500000 1.589482 0.429546 4.541826 222.594714 256.949986 2448998.208932 0.491836
-2448905.500000 1.589453 0.429540 4.541932 222.599246 256.947335 2448998.210909 0.491850
-2448940.500000 1.589592 0.429597 4.542603 222.603317 256.940639 2448998.205970 0.491785
-2448955.500000 1.590073 0.429782 4.544475 222.605427 256.933437 2448998.197722 0.491562
-2448964.500000 1.601189 0.434146 4.584818 222.633484 256.914805 2448998.131760 0.486452
-2448966.500000 3.165510 0.689635 1.525768 186.242242 256.858462 2448969.852910 0.175000
-2449265.500000 3.133095 0.686152 1.522041 186.422712 256.727957 2448969.897783 0.177723
-2449399.500000 3.142822 0.686060 1.522089 186.585394 256.772637 2448970.070578 0.176899
-2449820.500000 3.126154 0.694893 1.615527 186.750673 256.288204 2448975.835169 0.178315
-2449908.500000 3.111917 0.702568 1.697827 186.567783 256.365464 2448981.807725 0.179540
-2449926.500000 3.102720 0.706995 1.725856 186.278256 256.424265 2448981.443056 0.180339
-2449959.500000 3.090066 0.713970 1.803859 186.038781 256.629589 2448987.176836 0.181448
-2450039.500000 -0.027217 1.071523 5.116653 89.707887 59.796730 2450059.414367 6.782002
-2450046.500000 -0.027191 1.071426 5.114753 89.654763 59.871031 2450059.410517 6.791509
-2450052.500000 -0.027179 1.071397 5.116485 89.702162 59.830604 2450059.410005 6.796065
-2450058.500000 -0.027154 1.071521 5.120472 89.722964 59.784454 2450059.409834 6.805510
-2450060.500000 0.065571 0.971148 5.327293 88.171706 60.769089 2450059.406232 1.813626
-2450157.500000 0.067759 0.908663 5.384298 79.828631 68.868318 2450054.573327 1.726497
-2450207.500000 0.067544 0.914870 5.376638 80.913279 67.916303 2450262.582224 1.734728
-2450247.500000 0.067542 0.917469 5.381518 81.547635 67.509887 2450262.452864 1.734805
-2450259.500000 0.067716 0.917624 5.381543 81.546037 67.484485 2450262.452555 1.728131
-2450261.500000 0.068484 0.918553 5.384863 81.532709 67.485542 2450262.451961 1.699150
-2450262.500000 0.033311 0.841748 4.143743 96.983521 59.458402 2450262.522529 5.008816
-2450296.500000 0.033194 0.842724 4.144108 97.216046 59.198196 2450262.546402 5.035277
-2450301.500000 0.033202 0.842268 4.168168 99.094085 57.332304 2450334.083096 5.033448
-2450323.500000 0.033181 0.843303 4.173390 99.281629 57.180114 2450334.055736 5.038231
-2450326.500000 0.033220 0.843555 4.170161 99.213348 57.234550 2450334.050893 5.029471
-2450332.500000 0.033237 0.843646 4.172893 99.251583 57.199587 2450334.051817 5.025505
-2450333.500000 0.029682 0.828459 2.278461 166.988258 351.653914 2450334.068310 5.955019
-2450336.500000 0.029496 0.827188 2.278981 167.129328 351.621144 2450334.068816 6.011394
-2450365.500000 0.029515 0.828886 2.289523 167.246627 351.495495 2450394.055554 6.005562
-2450384.500000 0.029510 0.829525 2.294342 167.273849 351.489065 2450394.040377 6.007086
-2450391.500000 0.029559 0.829812 2.294550 167.251394 351.492028 2450394.039256 5.992177
-2450392.500000 0.023052 0.809144 1.970368 200.315319 326.520293 2450394.063772 8.700466
-2450398.500000 0.023503 0.812590 1.992962 200.815863 326.274808 2450394.065204 8.451544
-2450414.500000 0.023496 0.813155 1.997252 200.763974 326.308000 2450394.072081 8.455181
-2450433.500000 0.023497 0.813670 1.998235 200.759592 326.323914 2450436.641388 8.454577
-2450436.500000 0.023650 0.814904 1.998441 200.729606 326.353989 2450436.640973 8.372984
-2450437.500000 0.019405 0.776659 1.963601 197.818544 325.467287 2450436.612639 11.265485
-2450441.500000 0.019383 0.776413 1.962383 197.812426 325.454694 2450436.612469 11.284696
-2450461.500000 0.019386 0.776954 1.963254 197.822144 325.462770 2450468.520645 11.282125
-2450468.500000 0.019724 0.780807 1.962444 197.740733 325.464061 2450468.519636 10.992925
-2450469.500000 0.019365 0.776780 1.961005 197.493836 325.445681 2450468.517510 11.300405
-2450486.500000 0.019373 0.777232 1.975675 197.366351 325.621182 2450500.408560 11.293019
-2450492.500000 0.019378 0.777391 1.975541 197.358299 325.610100 2450500.400527 11.289276
-2450499.500000 0.019396 0.777707 1.975517 197.355017 325.610389 2450500.400102 11.273353
-2450500.500000 0.023630 0.815566 1.501933 190.760903 328.380205 2450500.371724 8.383564
-2450503.500000 0.023473 0.814641 1.499042 190.486945 328.569539 2450500.371193 8.467373
-2450521.500000 0.023482 0.815146 1.533047 190.277963 328.803674 2450500.387289 8.462906
-2450536.500000 0.023489 0.813993 1.882146 188.375757 330.753249 2450542.960983 8.459102
-2450543.500000 0.022915 0.809710 1.886818 188.758921 330.723866 2450542.961583 8.778667
-2450544.500000 0.020280 0.790774 2.510630 143.244749 13.382197 2450542.942465 10.543930
-2450568.500000 0.020257 0.790945 2.516066 143.327088 13.280986 2450577.028079 10.562134
-2450575.500000 0.019973 0.790697 2.818462 141.320045 15.915135 2450577.026355 10.787957
-2450576.500000 0.026222 0.830970 2.318930 163.045835 348.144224 2450576.987926 7.171756
-2450617.500000 0.026144 0.831178 2.324601 163.222107 348.085394 2450627.033180 7.203700
-2450624.500000 0.026160 0.831491 2.323943 163.251561 348.065465 2450627.030244 7.197265
-2450625.500000 0.037927 0.863870 2.189796 157.530091 344.004738 2450626.992481 4.122821
-2450701.500000 0.036672 0.860418 2.193549 158.210328 343.973096 2450710.435149 4.336249
-2450708.500000 0.038275 0.867867 2.190503 158.562547 343.871957 2450710.421226 4.066735
-2450709.500000 0.025844 0.830430 1.977857 176.582854 335.031051 2450710.465992 7.329692
-2450752.500000 0.025799 0.832421 1.763660 176.921431 334.824533 2450759.517197 7.348751
-2450758.500000 0.025795 0.832665 1.763457 176.971940 334.820053 2450759.515637 7.350211
-2450759.500000 0.022428 0.808819 2.146732 183.838296 330.004402 2450759.529909 9.066359
-2450791.500000 0.022250 0.807302 2.129305 183.871878 330.019735 2450798.765074 9.175162
-2450798.500000 0.020667 0.796536 2.118983 183.989808 331.701061 2450798.774935 10.249430
-2450799.500000 0.028485 0.849816 1.902301 193.459374 326.689625 2450798.805831 6.334310
-2450847.500000 0.028392 0.849847 1.888566 193.632235 326.595163 2450855.456473 6.365340
-2450854.500000 0.028395 0.850067 1.888069 193.670057 326.581641 2450855.455333 6.364269
-2450855.500000 0.025023 0.830888 1.794940 194.312407 327.431719 2450855.465493 7.692930
-2450893.500000 0.024850 0.829902 1.783731 194.470323 327.361739 2450901.834813 7.773570
-2450900.500000 0.024842 0.830007 1.783208 194.531591 327.328254 2450901.833603 7.777555
-2450901.500000 0.024928 0.830595 1.783129 194.514971 327.333270 2450901.833404 7.736982
-2450957.500000 0.030701 0.861045 1.904893 192.753867 331.697057 2450965.597065 5.660969
-2450964.500000 0.030718 0.861265 1.904462 192.785341 331.681840 2450965.595808 5.656070
-2450965.500000 0.026343 0.839452 2.098187 196.258993 330.031013 2450965.608107 7.122196
-2451008.500000 0.026086 0.837865 2.082308 196.524287 329.919955 2451015.514409 7.227735
-2451015.500000 0.026288 0.839093 2.082222 196.516941 329.916160 2451015.513218 7.144401
-2451016.500000 0.031892 0.866207 1.817351 207.654372 320.900078 2451015.527678 5.346711
-2451075.500000 0.031824 0.865485 1.777747 208.464436 320.284000 2451082.846578 5.363882
-2451082.500000 0.031996 0.866368 1.776918 208.510561 320.265509 2451082.844908 5.320753
-2451083.500000 0.028513 0.850660 1.342139 210.355353 319.515387 2451082.852303 6.324731
-2451132.500000 0.028489 0.849800 1.314309 211.155371 318.844062 2451139.815520 6.332989
-2451139.500000 0.028544 0.850279 1.313454 211.210157 318.811556 2451139.813891 6.314423
-2451140.500000 0.032977 0.869733 1.705186 196.369023 335.161903 2451139.824064 5.084997
-2451203.500000 0.032933 0.868258 1.660818 197.023110 334.700355 2451210.727921 5.095221
-2451210.500000 0.033297 0.869900 1.660417 197.090517 334.676995 2451210.726201 5.011975
-2451211.500000 0.039056 0.888526 2.233799 195.263798 334.326058 2451210.710471 3.945257
-2451296.500000 0.038982 0.885104 2.133640 196.342834 333.535662 2451302.209457 3.956561
-2451303.500000 0.039104 0.885422 2.133332 196.419712 333.521842 2451302.209476 3.938018
-2451304.500000 0.029376 0.865051 2.025064 185.616906 337.614556 2451302.194606 6.048279
-2451352.500000 0.029360 0.863048 2.009652 186.022250 337.268017 2451361.708199 6.053177
-2451359.500000 0.029403 0.863195 2.007948 186.051936 337.228960 2451361.708932 6.039701
-2451360.500000 0.023144 0.849886 2.029151 191.787956 338.689643 2451361.712226 8.648842
-2451397.500000 0.023000 0.847807 2.008504 192.063131 338.547299 2451402.959062 8.730150
-2451404.500000 0.023032 0.848129 2.008047 192.177857 338.533523 2451402.958322 8.711832
-2451405.500000 0.019970 0.844125 2.115986 189.690368 335.865347 2451402.960092 10.790977
-2451430.500000 0.019976 0.843574 2.108685 189.765483 335.819006 2451436.331265 10.785772
-2451437.500000 0.020013 0.843695 2.108071 189.781185 335.807877 2451436.332500 10.756110
-2451438.500000 0.017043 0.845002 2.108767 183.234759 335.789859 2451436.341812 13.686830
-2451455.500000 0.017022 0.844436 2.106135 183.174484 335.823322 2451462.585839 13.712318
-2451462.500000 0.017208 0.845930 2.104839 183.128063 335.805517 2451462.585871 13.490650
-2451463.500000 0.024737 0.891335 2.205048 184.952265 337.518925 2451462.597716 7.827123
-2451500.500000 0.024740 0.890187 2.532862 184.411480 338.075287 2451508.589006 7.825765
-2451507.500000 0.024756 0.890157 2.530901 184.419313 338.047831 2451508.589794 7.818101
-2451508.500000 0.024536 0.889504 2.580877 188.796700 333.911059 2451508.590202 7.923295
-2451539.500000 0.022187 0.877587 2.069076 211.452986 310.313205 2451547.657313 9.214648
-2451546.500000 0.022187 0.877730 2.067744 211.514598 310.252019 2451547.654651 9.214462
-2451547.500000 0.025963 0.893575 1.654852 186.190426 333.729897 2451547.648465 7.279032
-2451589.500000 0.025955 0.892139 1.636953 186.336084 333.614310 2451597.023125 7.282591
-2451596.500000 0.026006 0.892396 1.635963 186.343152 333.595317 2451597.022034 7.261045
-2451597.500000 0.038477 0.926716 2.224495 184.411552 339.437685 2451597.035418 4.034699
-2451677.500000 0.038399 0.923063 2.129179 184.562480 339.174031 2451685.719614 4.046999
-2451684.500000 0.038441 0.923262 2.127242 184.595509 339.149568 2451685.718064 4.040338
-2451685.500000 0.072817 0.956173 2.449159 156.972205 1.469193 2451685.703646 1.549769
-2451899.500000 0.071883 0.948959 2.640689 158.431436 359.330512 2451907.634826 1.580051
-2451906.500000 0.072351 0.949222 2.637402 158.412744 359.311635 2451907.636465 1.564757
-2451907.500000 0.053892 0.933586 2.579996 200.214854 319.495378 2451907.644114 2.434006
-2452047.500000 0.053724 0.935164 2.619227 199.711258 319.590188 2452053.232963 2.445444
-2452054.500000 0.053595 0.935066 2.618723 199.832375 319.571281 2452053.231935 2.454288
-2452055.500000 0.034297 0.915151 1.817382 163.453660 348.253532 2452053.233913 4.794384
-2452119.500000 0.034123 0.916807 1.875271 164.600717 346.906823 2452127.706121 4.831087
-2452126.500000 0.034108 0.916902 1.876091 164.621204 346.918813 2452127.703797 4.834217
-2452127.500000 0.034441 0.917716 1.876140 164.611518 346.925889 2452127.703661 4.764247
-2452191.500000 0.032988 0.916186 3.977431 173.140835 339.160870 2452198.499564 5.082557
-2452198.500000 0.034558 0.920027 3.981085 173.176634 339.110636 2452198.497953 4.740222
-2452199.500000 0.039766 0.930332 2.222860 182.581022 330.405338 2452198.500026 3.840082
-2452284.500000 0.039750 0.933909 2.276841 182.525507 330.390514 2452292.194302 3.842448
-2452291.500000 0.039800 0.934102 2.276885 182.534953 330.389586 2452292.192617 3.835252
-2452292.500000 0.083993 0.968455 1.361498 155.589819 354.622132 2452292.183058 1.250982
-2452575.500000 0.082099 0.988421 1.595345 160.317241 350.312083 2452583.810503 1.294520
-2452582.500000 0.082075 0.988439 1.595734 160.343087 350.310540 2452583.808734 1.295076
-2452583.500000 0.082911 0.988547 1.596360 160.314259 350.319901 2452583.808772 1.275552
-2452896.500000 0.085596 0.995164 1.669910 162.523803 348.929578 2452904.299738 1.215998
-2452903.500000 0.085547 0.995171 1.669236 162.533713 348.932284 2452904.300196 1.217044
-2452904.500000 0.086625 0.995233 1.692011 164.607872 349.776683 2452904.300256 1.194396
+207
+2447818.583333333023 0.778887560118 0.280053210135 7.421009602244 184.294081112325 25.707902522928 2447698.041586788837 1.433811048019
+2447819.500000000000 0.824596834043 0.208941687079 4.632657265696 184.921982631554 25.574764508622 2447687.169865624979 1.316259683810
+2447841.916666666977 0.832349474326 0.197769201237 4.329024002363 184.760855887424 25.342532554034 2447962.147621884011 1.297912782223
+2447842.500000000000 0.832373576646 0.197800527898 4.328466883460 184.720944215277 25.339617321516 2447962.104462962132 1.297856408828
+2447883.500000000000 0.832638400509 0.197417703971 4.317818904324 184.780695195877 25.238811739535 2447962.133508944884 1.297237275690
+2447932.500000000000 0.842406876222 0.209606400282 4.409859189489 186.161385524724 23.661938811017 2447961.789771546144 1.274738841860
+2447933.500000000000 0.999514791364 0.301429543578 3.380418834665 107.286600149871 76.404764351243 2447947.937496391125 0.986325441948
+2447934.500000000000 0.994849466724 0.297932800043 3.381004264891 107.179295946742 76.463982904399 2447947.934624576941 0.993271596653
+2447994.500000000000 0.989104139150 0.294469466143 3.382365985529 106.817772698209 76.479286939576 2447947.765756153967 1.001938454006
+2448024.500000000000 0.988457113379 0.294572461250 3.390234130134 106.592867393866 76.579014502864 2447947.717718434986 1.002922390591
+2448090.500000000000 0.988423609635 0.294601948017 3.390107431559 106.577499503070 76.587775400175 2447947.716081039980 1.002973383817
+2448174.500000000000 0.988402095784 0.294643959321 3.389869122676 106.575288201045 76.587949665941 2448306.638511118013 1.003006130517
+2448209.500000000000 0.988414878916 0.294705175635 3.388800548390 106.564037090721 76.593808046356 2448306.626434287056 1.002986672820
+2448224.500000000000 0.988395679435 0.294818593441 3.390224541966 106.574674752296 76.588146448784 2448306.616180445999 1.003015897325
+2448233.500000000000 0.988810427156 0.296690999231 3.413705422804 106.613572230351 76.573090960362 2448306.463272347115 1.002384904385
+2448234.500000000000 1.634466679191 0.448290922282 4.685539806132 223.312853414132 256.657609554976 2448267.598667051177 0.471671859943
+2448235.500000000000 1.593797847042 0.432590560119 4.558985219839 223.155614896250 256.647072153088 2448267.725697890855 0.489839970364
+2448245.500000000000 1.588639528955 0.430540757291 4.543657219346 223.125224792334 256.645026243551 2448267.732667655218 0.492227674103
+2448336.500000000000 1.587559840818 0.430212486966 4.540785077553 223.077867946402 256.662905271033 2448267.712786469143 0.492729900270
+2448440.500000000000 1.587244346028 0.430305479726 4.545804753086 223.061658256564 256.655666329191 2448267.718926433939 0.492876816630
+2448539.500000000000 1.587267837741 0.430288470308 4.546675166903 223.059229585941 256.660419209208 2448267.717734660953 0.492865874736
+2448554.500000000000 1.587281366376 0.430279335848 4.545565133876 223.066749643526 256.653736812924 2448267.716396328993 0.492859573595
+2448839.500000000000 1.587991326091 0.429977653505 4.544012267851 222.938782233841 256.735468859742 2448998.218278921209 0.492529088796
+2448840.500000000000 1.588608355265 0.429789796111 4.543112593547 222.794052525467 256.826365987059 2448998.216042792890 0.492242162849
+2448844.500000000000 1.589484413908 0.429547025442 4.541823373524 222.594358646321 256.950199449368 2448998.208617671859 0.491835263379
+2448905.500000000000 1.589452812151 0.429540140013 4.541931773077 222.599246268845 256.947334649904 2448998.210909065790 0.491849931574
+2448940.500000000000 1.589591858360 0.429596886152 4.542603050252 222.603316606750 256.940639396891 2448998.205969744828 0.491785397676
+2448955.500000000000 1.590073173211 0.429781747725 4.544475128185 222.605426582627 256.933437157125 2448998.197721512988 0.491562119553
+2448964.500000000000 1.601189244919 0.434145543154 4.584818209446 222.633483799333 256.914805482359 2448998.131759520154 0.486452094234
+2448965.500000000000 3.262839520017 0.698900222017 1.541235041071 186.245580531778 256.867560466788 2448969.851199064869 0.167228580388
+2448966.500000000000 3.165510405588 0.689635438007 1.525767694963 186.242242313821 256.858462129395 2448969.852909686044 0.175000164009
+2449088.500000000000 3.129651717331 0.686040475203 1.520196098240 186.278158804597 256.821517303690 2448969.845814646222 0.178016418442
+2449265.500000000000 3.133095486629 0.686152421883 1.522041482997 186.422711524866 256.727957161522 2448969.897783454973 0.177722996654
+2449266.500000000000 3.135604485490 0.685991786594 1.520589382480 186.439380031964 256.771995762907 2448969.881736653857 0.177509727927
+2449269.500000000000 3.143224233058 0.685500134354 1.516200856237 186.491124768853 256.904598773542 2448969.832314182073 0.176864645444
+2449399.500000000000 3.142821967074 0.686060459020 1.522089162065 186.585393535174 256.772637489365 2448970.070577817038 0.176898603257
+2449777.500000000000 3.130154737728 0.692772086696 1.592714329760 186.774117133800 256.311629966937 2448974.290259968024 0.177973508922
+2449820.500000000000 3.126154023605 0.694892627535 1.615527431414 186.750673413931 256.288204234952 2448975.835168646183 0.178315262181
+2449908.500000000000 3.111916650750 0.702568427703 1.697826871715 186.567782843712 256.365464448228 2448981.807724860031 0.179540379708
+2449926.500000000000 3.102719840524 0.706994633408 1.725855922206 186.278256337722 256.424264618378 2448981.443056060001 0.180339237742
+2449959.500000000000 3.090065858259 0.713970468517 1.803858934863 186.038780545086 256.629588946269 2448987.176836470142 0.181448119041
+2450039.500000000000 -0.027216798363 1.071523227287 5.116653443184 89.707887337282 59.796730452807 2450059.414366906043 6.782002206518
+2450046.500000000000 -0.027191394313 1.071425665802 5.114753447681 89.654763163383 59.871031193096 2450059.410516670905 6.791508737720
+2450052.500000000000 -0.027179239017 1.071397322024 5.116485157718 89.702161810247 59.830603557480 2450059.410004835110 6.796065268588
+2450058.500000000000 -0.027154087513 1.071520698230 5.120471641958 89.722963935449 59.784453790794 2450059.409834465012 6.805509749343
+2450059.500000000000 -0.039383033634 1.048555659185 5.362065060127 90.766152562896 60.502136262916 2450059.413096105214 3.896276157836
+2450059.583333333023 0.066552335524 0.971578504372 5.326008625535 88.175000060028 60.769592598377 2450059.406370982993 1.773652475073
+2450059.666666666977 0.066215734454 0.971431566274 5.326784260532 88.180057472002 60.767345442682 2450059.406357467175 1.787193925586
+2450059.750000000000 0.066055420704 0.971360749611 5.327045239953 88.180990648751 60.767269383895 2450059.406344410963 1.793704039149
+2450060.500000000000 0.065570812737 0.971148257106 5.327293034385 88.171706315844 60.769089048780 2450059.406232076231 1.813625570961
+2450061.500000000000 0.065655796022 0.971194662111 5.327138622565 88.170107725120 60.765288090103 2450059.406416802201 1.810105440587
+2450104.500000000000 0.065576036984 0.972269738092 5.308803547511 88.806531941892 59.913694068177 2450059.440957997926 1.813408846061
+2450157.333333333023 0.067754880716 0.908774108424 5.384454783828 79.821550785303 68.877371400432 2450054.592798742931 1.726643201247
+2450157.500000000000 0.067758708106 0.908662877105 5.384297896397 79.828631373382 68.868318135637 2450054.573326581158 1.726496907683
+2450207.500000000000 0.067544193175 0.914869589139 5.376638373148 80.913279083741 67.916302928997 2450262.582224404905 1.734728257769
+2450247.500000000000 0.067542193928 0.917468507351 5.381517938505 81.547634785773 67.509887365249 2450262.452864417806 1.734805280204
+2450259.500000000000 0.067715977321 0.917623897395 5.381543390762 81.546037448633 67.484484842661 2450262.452555335127 1.728131371366
+2450261.500000000000 0.068483785937 0.918553053899 5.384863149498 81.532709330548 67.485541686403 2450262.451960748993 1.699150465509
+2450262.500000000000 0.033310843370 0.841747517061 4.143743187733 96.983520546147 59.458401777813 2450262.522528906818 5.008815536747
+2450263.500000000000 0.033313134285 0.841700667457 4.145992167737 97.113059995624 59.392953766781 2450262.522968851030 5.008298867798
+2450296.500000000000 0.033194037802 0.842724225110 4.144108324892 97.216046440378 59.198196299444 2450262.546402064152 5.035276851662
+2450301.500000000000 0.033202079223 0.842268481051 4.168167983730 99.094085391298 57.332303870369 2450334.083096418995 5.033447674340
+2450302.500000000000 0.033203060146 0.842138989747 4.169255245243 99.170536762357 57.262663193499 2450334.095438588876 5.033224620179
+2450323.500000000000 0.033181061230 0.843302965483 4.173389721146 99.281628817486 57.180113510369 2450334.055736477952 5.038230962463
+2450326.500000000000 0.033219577191 0.843554884988 4.170160520559 99.213348312372 57.234549623131 2450334.050892571919 5.029471246132
+2450332.500000000000 0.033237053374 0.843645968219 4.172893076750 99.251582705458 57.199587108248 2450334.051816938911 5.025504991821
+2450333.500000000000 0.029681571496 0.828458572558 2.278460508682 166.988258145915 351.653913944732 2450334.068310420029 5.955018896868
+2450336.500000000000 0.029495709937 0.827187688915 2.278980955147 167.129328230103 351.621143810544 2450334.068815696985 6.011394087772
+2450337.500000000000 0.029560809584 0.827496168702 2.279155814535 167.181511827548 351.606611286292 2450334.069504234008 5.991547332681
+2450365.500000000000 0.029514802413 0.828886129770 2.289522797020 167.246627460053 351.495495241741 2450394.055554120801 6.005562073447
+2450366.500000000000 0.029522075137 0.828426855607 2.290128225143 167.250528870852 351.492494213960 2450394.070269573014 6.003343016724
+2450384.500000000000 0.029509808957 0.829525255834 2.294341771326 167.273849379628 351.489065244716 2450394.040377081838 6.007086470703
+2450391.500000000000 0.029558740083 0.829812117124 2.294550138280 167.251394001059 351.492028308957 2450394.039256467018 5.992176574703
+2450392.500000000000 0.023052285037 0.809143874103 1.970367718955 200.315319047694 326.520293475773 2450394.063772419002 8.700465897726
+2450393.500000000000 0.023066400959 0.809221455006 1.970314478742 200.298782655673 326.525315831841 2450394.063849756029 8.692480497125
+2450398.500000000000 0.023502728593 0.812589648098 1.992962045992 200.815862795311 326.274808126315 2450394.065203907900 8.451543913076
+2450414.500000000000 0.023495988442 0.813155300270 1.997251538054 200.763974175923 326.307999550324 2450394.072081470862 8.455180838230
+2450433.500000000000 0.023497107635 0.813670111177 1.998234961597 200.759591755147 326.323913606180 2450436.641387500800 8.454576750935
+2450436.500000000000 0.023649510622 0.814903773866 1.998440912847 200.729605829288 326.353988936128 2450436.640972645022 8.372983646327
+2450437.500000000000 0.019404794671 0.776658757304 1.963600947805 197.818543837101 325.467287016322 2450436.612639135215 11.265485241620
+2450441.500000000000 0.019382765724 0.776413464305 1.962383062677 197.812425839622 325.454694405495 2450436.612468624022 11.284695911329
+2450461.500000000000 0.019385710543 0.776953787476 1.963253748465 197.822143831820 325.462770264801 2450468.520644517150 11.282124677818
+2450468.500000000000 0.019724233995 0.780806855600 1.962443692202 197.740732734109 325.464060694454 2450468.519636192825 10.992924908577
+2450469.500000000000 0.019364798149 0.776779561445 1.961005379819 197.493836021849 325.445680797963 2450468.517509712838 11.300405265070
+2450486.500000000000 0.019373241166 0.777232003451 1.975674791597 197.366351026070 325.621181679330 2450500.408560339827 11.293018857013
+2450492.500000000000 0.019377522788 0.777390580118 1.975541354723 197.358299086632 325.610099842059 2450500.400526615791 11.289276136233
+2450499.500000000000 0.019395765247 0.777707162373 1.975517327152 197.355017221876 325.610389259270 2450500.400101722218 11.273352887735
+2450500.500000000000 0.023629608245 0.815565966192 1.501933346135 190.760903099141 328.380205488866 2450500.371723696124 8.383564272171
+2450503.500000000000 0.023473428781 0.814640557137 1.499042089959 190.486945024304 328.569538904389 2450500.371193379164 8.467372825506
+2450521.500000000000 0.023481688138 0.815145561204 1.533047063869 190.277962890671 328.803674368007 2450500.387288601138 8.462905797645
+2450522.500000000000 0.023505117192 0.813346267644 1.882026686182 188.351946006996 330.749832305830 2450542.971129822079 8.450255672025
+2450536.500000000000 0.023488726816 0.813992895897 1.882146103299 188.375757261590 330.753249089252 2450542.960983078927 8.459102066508
+2450543.500000000000 0.022915179522 0.809710061571 1.886817903440 188.758920992648 330.723865601254 2450542.961583045777 8.778667186932
+2450544.500000000000 0.020280280824 0.790774328683 2.510630466055 143.244748570872 13.382196975864 2450542.942465040833 10.543930480600
+2450545.500000000000 0.020251442503 0.790507399442 2.510618841470 143.215518274101 13.388104438021 2450542.941944268066 10.566460540322
+2450568.500000000000 0.020256972330 0.790944983382 2.516065837664 143.327087964338 13.280986143191 2450577.028079153039 10.562134125627
+2450575.500000000000 0.019973285798 0.790697299814 2.818462453242 141.320044897824 15.915134660759 2450577.026354985777 10.787956979546
+2450576.500000000000 0.026221567536 0.830970213923 2.318930030600 163.045834886574 348.144224442747 2450576.987926451955 7.171755990329
+2450577.500000000000 0.026152517877 0.830522339425 2.319168285167 163.071572697549 348.141001858318 2450576.988122540992 7.200177767969
+2450580.500000000000 0.026160292834 0.830356011282 2.319203542871 163.129738042760 348.134012312635 2450576.987347344868 7.196968118418
+2450617.500000000000 0.026143993011 0.831178470456 2.324601197662 163.222106863902 348.085394219761 2450627.033179759979 7.203699736837
+2450624.500000000000 0.026159573935 0.831491345351 2.323942635759 163.251560535473 348.065464877235 2450627.030243556015 7.197264793533
+2450625.500000000000 0.037926780815 0.863869923773 2.189796273558 157.530091474863 344.004737704723 2450626.992480578832 4.122821268130
+2450626.500000000000 0.036883627704 0.860444075943 2.189794191770 157.873908306808 344.006250294025 2450626.995306666009 4.298956354641
+2450701.500000000000 0.036671849381 0.860418014978 2.193548574239 158.210327605180 343.973096363854 2450710.435149494093 4.336249493686
+2450708.500000000000 0.038274697297 0.867867126080 2.190503134553 158.562547095008 343.871957288431 2450710.421225727070 4.066734625268
+2450709.500000000000 0.025843530857 0.830430046669 1.977856795495 176.582854085931 335.031050834279 2450710.465992414858 7.329691695677
+2450710.500000000000 0.025906419788 0.830838350293 1.977799129996 176.591112744029 335.033443301823 2450710.466024592053 7.303018194698
+2450752.500000000000 0.025798827239 0.832421137184 1.763659711106 176.921430690577 334.824533491365 2450759.517196503002 7.348751029387
+2450758.500000000000 0.025795411207 0.832664807150 1.763457265206 176.971939736872 334.820052962890 2450759.515636994038 7.350210847259
+2450759.500000000000 0.022427818872 0.808819384048 2.146732403593 183.838296067880 330.004402396610 2450759.529908847064 9.066359179510
+2450760.500000000000 0.022269095775 0.807409966337 2.146771601294 183.849747535503 330.003338527505 2450759.529803912155 9.163462477301
+2450791.500000000000 0.022250161843 0.807302262664 2.129305199724 183.871877958192 330.019735199199 2450798.765073571820 9.175161534406
+2450798.500000000000 0.020666923867 0.796536081340 2.118982681008 183.989807949439 331.701061048286 2450798.774935252964 10.249430173036
+2450799.500000000000 0.028484556713 0.849815569138 1.902300993828 193.459374108057 326.689625417702 2450798.805831423029 6.334309545155
+2450800.500000000000 0.028410600818 0.849448627793 1.902284799082 193.438780858613 326.690102207052 2450798.805608063005 6.359058983095
+2450847.500000000000 0.028391907868 0.849847163880 1.888566484998 193.632234583397 326.595162713158 2450855.456473234110 6.365340128524
+2450854.500000000000 0.028395093348 0.850067319647 1.888069405814 193.670057106972 326.581640894371 2450855.455333218910 6.364269022714
+2450855.500000000000 0.025023486414 0.830888085706 1.794939594946 194.312406869282 327.431719490966 2450855.465492540970 7.692929519203
+2450856.500000000000 0.024872614334 0.829821610201 1.794945389774 194.325350243098 327.433249273193 2450855.465366433840 7.763031110820
+2450893.500000000000 0.024850129691 0.829902097505 1.783730877490 194.470323368098 327.361738506432 2450901.834812702145 7.773569594424
+2450900.500000000000 0.024841640048 0.830007303095 1.783208402315 194.531591386533 327.328254262979 2450901.833602983039 7.777554867214
+2450901.500000000000 0.024928410971 0.830594644160 1.783128647518 194.514971449506 327.333269645037 2450901.833403647877 7.736982004034
+2450902.500000000000 0.030615144605 0.860775671740 1.931243350648 192.401097926788 331.799761520570 2450901.849502697121 5.684719075888
+2450957.500000000000 0.030700712196 0.861045367278 1.904892935469 192.753867128667 331.697057387461 2450965.597064530011 5.660969368401
+2450964.500000000000 0.030718439484 0.861265299808 1.904462492789 192.785340991547 331.681840022932 2450965.595808440819 5.656069746659
+2450965.500000000000 0.026343068188 0.839451973956 2.098187036467 196.258993310859 330.031013297268 2450965.608106649015 7.122196414944
+2450966.500000000000 0.026123103637 0.838053026788 2.098160230597 196.294835522183 330.033014761237 2450965.608249837998 7.212342135720
+2451008.500000000000 0.026085999866 0.837865178296 2.082307960981 196.524287418773 329.919954809987 2451015.514408701099 7.227735463201
+2451015.500000000000 0.026288456455 0.839092701889 2.082222028757 196.516941071523 329.916160255268 2451015.513217809144 7.144401451731
+2451016.500000000000 0.031892201157 0.866207439127 1.817350968768 207.654371991922 320.900078025707 2451015.527677605860 5.346711346315
+2451017.500000000000 0.031841334582 0.865870635254 1.816864154204 207.666289251224 320.925039746861 2451015.527232152876 5.359528529662
+2451075.500000000000 0.031824104506 0.865485083389 1.777747337956 208.464436337700 320.284000381111 2451082.846577520948 5.363881719786
+2451082.500000000000 0.031995845606 0.866368060513 1.776918074564 208.510561077497 320.265508502969 2451082.844907559920 5.320752916905
+2451083.500000000000 0.028513307283 0.850660037460 1.342138905163 210.355352949069 319.515387185913 2451082.852302548941 6.324731433656
+2451084.500000000000 0.028510314778 0.850595086543 1.342068754044 210.363456917906 319.523473803772 2451082.852219705004 6.325727246277
+2451132.500000000000 0.028488516958 0.849800400948 1.314308735115 211.155370556632 318.844061822402 2451139.815520284232 6.332988773870
+2451139.500000000000 0.028544330157 0.850279336702 1.313453565171 211.210156813995 318.811556184279 2451139.813891004771 6.314423360818
+2451140.500000000000 0.032977307968 0.869733021762 1.705185951961 196.369023202247 335.161903083589 2451139.824063752778 5.084996758290
+2451141.500000000000 0.032904736044 0.869434478536 1.705193065947 196.365232842651 335.161950021183 2451139.823821289930 5.101828593443
+2451203.500000000000 0.032933179396 0.868257737474 1.660818478476 197.023110081096 334.700354576678 2451210.727921448182 5.095220587345
+2451210.500000000000 0.033296844049 0.869899846816 1.660416663110 197.090517354212 334.676994567826 2451210.726200724021 5.011974727508
+2451211.500000000000 0.039056391844 0.888526369537 2.233799114667 195.263797947605 334.326058205293 2451210.710471352097 3.945257022610
+2451212.500000000000 0.038908779230 0.888130224072 2.233814985855 195.239688863777 334.325058083806 2451210.710175288841 3.967729651508
+2451296.500000000000 0.038981968688 0.885104365621 2.133639902599 196.342834238228 333.535661938559 2451302.209456671029 3.956560655620
+2451303.500000000000 0.039104242460 0.885422249428 2.133332447843 196.419712340725 333.521841566852 2451302.209476373158 3.938017710449
+2451304.500000000000 0.029375669391 0.865050661504 2.025064356035 185.616906131226 337.614555617097 2451302.194605689961 6.048279088698
+2451305.500000000000 0.029363356058 0.864965102365 2.025035284688 185.617251723716 337.615562978684 2451302.194312055130 6.052083947222
+2451352.500000000000 0.029359821077 0.863048470495 2.009652321001 186.022250026454 337.268016951093 2451361.708198800217 6.053177004748
+2451359.500000000000 0.029403477904 0.863195019146 2.007947603021 186.051935515397 337.228960308435 2451361.708932297770 6.039700824087
+2451360.500000000000 0.023143924372 0.849885733655 2.029151009660 191.787956218840 338.689642739278 2451361.712225990836 8.648842296953
+2451361.500000000000 0.023200848448 0.850231653382 2.029127313184 191.781166030291 338.690433497832 2451361.712216651998 8.617031482966
+2451397.500000000000 0.023000000246 0.847807300768 2.008503806404 192.063130861458 338.547299069639 2451402.959061610047 8.730150275940
+2451404.500000000000 0.023032230847 0.848129405038 2.008047155103 192.177856828271 338.533522657556 2451402.958321949933 8.711831629589
+2451405.500000000000 0.019969558933 0.844125358767 2.115986027883 189.690367566570 335.865346600265 2451402.960092030000 10.790977111506
+2451406.500000000000 0.019978173361 0.844077140829 2.115951311006 189.710795061563 335.865907907676 2451402.959908415098 10.783998390148
+2451430.500000000000 0.019975983264 0.843573985178 2.108684896830 189.765482588229 335.819006076708 2451436.331264722161 10.785771918241
+2451437.500000000000 0.020012690731 0.843694779402 2.108071343234 189.781184997617 335.807876599450 2451436.332500127144 10.756110482637
+2451438.500000000000 0.017042778364 0.845001613913 2.108767410633 183.234758788977 335.789859040288 2451436.341812413186 13.686830414917
+2451439.500000000000 0.017022295730 0.844776045179 2.108628050285 183.217921952479 335.792294450527 2451436.340893357992 13.711541534827
+2451455.500000000000 0.017021653330 0.844436097397 2.106134955940 183.174484321491 335.823322211840 2451462.585838998202 13.712317755725
+2451462.500000000000 0.017207604307 0.845929850516 2.104838974481 183.128062713519 335.805516631604 2451462.585870815907 13.490649662676
+2451463.500000000000 0.024736650868 0.891334603736 2.205047797883 184.952265279481 337.518924971878 2451462.597715811804 7.827122505959
+2451464.500000000000 0.024746127357 0.891381446199 2.205029200384 184.951715665213 337.519477048295 2451462.597815167159 7.822626860695
+2451500.500000000000 0.024739510554 0.890187017052 2.532862321210 184.411480381871 338.075286712675 2451508.589005880058 7.825765417752
+2451507.500000000000 0.024755677016 0.890157051315 2.530901042512 184.419313000942 338.047830756963 2451508.589794359170 7.818100855742
+2451508.500000000000 0.024536076728 0.889503985242 2.580876887620 188.796700460239 333.911059277392 2451508.590201622806 7.923294507228
+2451509.500000000000 0.022201693511 0.878118750172 1.453399169628 226.461169242024 295.330129039615 2451508.586485524196 9.205223254814
+2451539.500000000000 0.022186552874 0.877587444855 2.069075671154 211.452985653901 310.313205306487 2451547.657313432079 9.214647660444
+2451546.500000000000 0.022186851500 0.877729803919 2.067743635978 211.514598443732 310.252018962486 2451547.654650636017 9.214461622918
+2451547.500000000000 0.025963300100 0.893574576641 1.654851957202 186.190425959720 333.729897024172 2451547.648464576807 7.279032201322
+2451548.500000000000 0.025905363504 0.893319004222 1.654874640784 186.245966435826 333.742461922876 2451547.648601493798 7.303464866714
+2451589.500000000000 0.025954841738 0.892138952138 1.636953017338 186.336083941104 333.614309983701 2451597.023125294130 7.282590711098
+2451596.500000000000 0.026006161041 0.892395853124 1.635963282750 186.343151576815 333.595317440027 2451597.022033658810 7.261044679878
+2451597.500000000000 0.038477032296 0.926716213839 2.224494808566 184.411551620968 339.437685028455 2451597.035418441985 4.034698888695
+2451598.500000000000 0.038350414215 0.926497425397 2.224502789951 184.392074844496 339.437199324751 2451597.035376339220 4.054696870912
+2451677.500000000000 0.038399027134 0.923063062427 2.129179241524 184.562480076201 339.174030961570 2451685.719614182133 4.046999478660
+2451684.500000000000 0.038441224790 0.923261531745 2.127242270124 184.595508638941 339.149567736855 2451685.718063523993 4.040337606412
+2451685.500000000000 0.072816705653 0.956172711181 2.449159381099 156.972204965926 1.469192993448 2451685.703646002803 1.549768895586
+2451686.500000000000 0.072346899127 0.955886123903 2.449810715129 157.023619913643 1.465462776918 2451685.703788063023 1.564889217818
+2451899.500000000000 0.071883354801 0.948958704495 2.640689130699 158.431436272929 359.330512491031 2451907.634825771209 1.580050524055
+2451906.500000000000 0.072350970802 0.949221636571 2.637401563066 158.412743814331 359.311634767667 2451907.636464701034 1.564757119464
+2451907.500000000000 0.053892438379 0.933585724982 2.579996420496 200.214854152354 319.495377713482 2451907.644113658927 2.434006477967
+2451908.500000000000 0.053907473112 0.933587818618 2.579613508560 200.262385059282 319.489760677928 2451907.644272254780 2.432988286471
+2452047.500000000000 0.053724261104 0.935164346302 2.619227485516 199.711258015560 319.590187591258 2452053.232963465154 2.445444460094
+2452054.500000000000 0.053595123858 0.935066342234 2.618723267383 199.832375046229 319.571281365793 2452053.231934714131 2.454288215636
+2452055.500000000000 0.034296813437 0.915151070199 1.817382016883 163.453659776391 348.253532429931 2452053.233912894037 4.794384094743
+2452056.500000000000 0.034233547373 0.915024984163 1.817395761111 163.435172119720 348.252090971710 2452053.233525314834 4.807680784493
+2452119.500000000000 0.034122886663 0.916807273320 1.875270731229 164.600717064316 346.906822980538 2452127.706120792776 4.831086738384
+2452126.500000000000 0.034108152917 0.916901590341 1.876091354575 164.621204014002 346.918813382078 2452127.703796683811 4.834217413308
+2452127.500000000000 0.034441293816 0.917716037758 1.876140265682 164.611517823001 346.925889450225 2452127.703661021776 4.764247271011
+2452128.500000000000 0.032981383819 0.914039674897 3.786888191273 172.596846107764 339.766092877237 2452127.705983997788 5.084054178944
+2452191.500000000000 0.032987862435 0.916186397923 3.977430673734 173.140834729027 339.160870072637 2452198.499564342201 5.082556536350
+2452198.500000000000 0.034557570110 0.920026979813 3.981085417295 173.176634385341 339.110635984905 2452198.497953318991 4.740222024215
+2452199.500000000000 0.039766312530 0.930331849297 2.222860309600 182.581021544998 330.405337547585 2452198.500026057940 3.840082001146
+2452200.500000000000 0.039814724434 0.930428402827 2.222872956133 182.580103541964 330.404621635680 2452198.500214559026 3.833080226362
+2452284.500000000000 0.039749987318 0.933908657618 2.276841233963 182.525507283553 330.390513876431 2452292.194302026182 3.842447910904
+2452291.500000000000 0.039799689255 0.934101903080 2.276885308390 182.534953184639 330.389585837627 2452292.192617339082 3.835252472841
+2452292.500000000000 0.083992711438 0.968454554040 1.361498258104 155.589819481210 354.622131775322 2452292.183057731949 1.250982051013
+2452293.500000000000 0.082982296217 0.968079323985 1.361627717706 155.550498672395 354.641755399303 2452292.182994844858 1.273899914114
+2452575.500000000000 0.082098756599 0.988421225391 1.595345290825 160.317241445880 350.312083233102 2452583.810503261164 1.294519542057
+2452582.500000000000 0.082075220259 0.988438512308 1.595733877508 160.343087445273 350.310540429389 2452583.808733699843 1.295076417240
+2452583.500000000000 0.082910640446 0.988546670217 1.596359660177 160.314258692857 350.319901463667 2452583.808772113174 1.275551728636
+2452584.500000000000 0.086393903755 0.988987604320 1.604281842949 160.436793753895 350.657577183798 2452583.808790702838 1.199192304984
+2452896.500000000000 0.085596044538 0.995164014522 1.669910056265 162.523803442268 348.929577951276 2452904.299737519119 1.215998212150
+2452903.500000000000 0.085546992050 0.995171214055 1.669236114242 162.533713415095 348.932283725094 2452904.300196123775 1.217044238774
+2452904.500000000000 0.086625044713 0.995233074745 1.692011337742 164.607872481273 349.776682951470 2452904.300256120972 1.194395814381
diff --git a/src/main/java/ephemeris/SPK.java b/src/main/java/ephemeris/SPK.java
old mode 100755
new mode 100644
index 6c02dc65..c4e158cf
--- a/src/main/java/ephemeris/SPK.java
+++ b/src/main/java/ephemeris/SPK.java
@@ -1,5 +1,7 @@
+package ephemeris;
+
/*
- * Copyright (c) 2021 Nico Kuijpers and Marco Brassé
+ * Copyright (c) 2022 Nico Kuijpers and Marco Brassé
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
@@ -18,10 +20,9 @@
* IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* This code was converted from Python3 reader by Marco Brassé
- * Original Python2 code from
- * (C) 2017 Nabla Zero Labs
+ * Based on Python2 code from
+ * 2017 Nabla Zero Labs
*/
-package ephemeris;
import util.Vector3D;
@@ -32,9 +33,12 @@
import java.nio.MappedByteBuffer;
import java.nio.channels.FileChannel;
+
public class SPK {
- // Auxiliary class
+ final int MAX_RECORDS = 1024;
+
+ // AUXILIARY CLASS
public class SummaryRecords
{
private int nRecords;
@@ -49,18 +53,18 @@ public class SummaryRecords
public SummaryRecords()
{
nRecords=0;
- _etbeg = new double[128];
- _etend = new double[128];
- _t = new int[128];
- _o = new int[128];
- _frame = new int[128];
- _type = new int[128];
- _rbeg = new int[128];
- _rend = new int[128];
+ _etbeg = new double[MAX_RECORDS];
+ _etend = new double[MAX_RECORDS];
+ _t = new int[MAX_RECORDS];
+ _o = new int[MAX_RECORDS];
+ _frame = new int[MAX_RECORDS];
+ _type = new int[MAX_RECORDS];
+ _rbeg = new int[MAX_RECORDS];
+ _rend = new int[MAX_RECORDS];
}
public void addRecord( double etbeg, double etend, int t, int o, int frame, int type, int rbeg, int rend)
{
- if (nRecords<128)
+ if (nRecords=2)
+ {
+ JX = JX + 1;
+ for (int J=1; J0; J--) {
+ SUM = SUM + DT[(J-1) + (I-1)*15] * W[J+KS-1];
+ }
+ STATE[I-1] = REFPOS[I-1] + DELTA * (REFVEL[I-1] + DELTA * SUM);
+ }
+
+ for (int J=1; J 0; J--) {
+ SUM = SUM + DT[(J - 1) + (I - 1) * 15] * W[J + KS - 1];
+ }
+ STATE[I + 3 - 1] = REFVEL[I - 1] + DELTA * SUM;
+ }
+
+ return STATE;
+ }
+
/**
* Initialize with BSP file
* @param path filepath to .bsp file
*/
- public void initWithBSPFile(String path) {
+ public void initWithBSPFile(String path)
+ {
String DAFstr = "DAF/SPK";
String NAIFstr = "NAIF/DA";
String LEstr = "LTL-IEEE";
@@ -177,13 +288,9 @@ public void initWithBSPFile(String path) {
try (RandomAccessFile file = new RandomAccessFile(new File(path), "r"))
{
- if (path.indexOf("405")>=0)
- {
- isLittleEndian = Boolean.FALSE;
- }
- else {
- isLittleEndian = Boolean.TRUE;
- }
+ // default endianness
+ isLittleEndian = Boolean.TRUE;
+
//Get file channel in read-only mode
FileChannel fileChannel = file.getChannel();
@@ -192,16 +299,23 @@ public void initWithBSPFile(String path) {
//You can read the file from this buffer the way you like.
buffer.get(bbuf,0,7);
- if ((!isEqualByteArray(bbuf, DAFstr.getBytes(), 7)) && ((!isEqualByteArray(bbuf, NAIFstr.getBytes(), 7)))) {
- System.err.println("ERROR: Wrong BSP File " + path);
+ if ((!isEqualByteArray(bbuf, DAFstr.getBytes(), 7)) && ((!isEqualByteArray(bbuf, NAIFstr.getBytes(), 7))))
+ {
+ System.out.println("File is not correct");
return;
}
- //buffer.position(88);
- //buffer.get(bbuf,0,8);
- //if (isEqualByteArray(bbuf, LEstr.getBytes(), 8))
- //{
- //System.out.println("[DEBUG] Little endianness");
- //}
+ buffer.position(88);
+ buffer.get(bbuf,0,8);
+ if (isEqualByteArray(bbuf, LEstr.getBytes(), 8))
+ {
+ //System.out.println("[DEBUG] Little endianness");
+ isLittleEndian = Boolean.TRUE;
+ }
+ else
+ {
+ //System.out.println("[DEBUG] Big endianness");
+ isLittleEndian = Boolean.FALSE;
+ }
buffer.position(8);
buffer.get(bbuf, 0, 4);
nd = (int) getUnsignedInt(bbuf);
@@ -218,15 +332,15 @@ public void initWithBSPFile(String path) {
buffer.get(bbuf, 0, 4);
bward = (int) getUnsignedInt(bbuf);
//
- assert(nd==2);
- assert(ni==6);
+ //assert(nd==2);
+ //assert(ni==6);
//
int summary_offset = (fward - 1) * RECLEN;
int summary_size = nd + (ni + 1) / 2; // integer division
int nxt=1;
int prv=0;
int nsum=0;
- while (nxt!=0)
+ while (nxt !=0 )
{
int n;
buffer.position(summary_offset);
@@ -250,23 +364,25 @@ public void initWithBSPFile(String path) {
double rec;
buffer.get(bbuf, 0, 8);
drec[j] = (double) getDouble(bbuf);
- //System.out.println("...read double " + drec[j]);
}
// read ni==6 unsigned int
for (int j = 0; j<(int) ni; j++)
{
buffer.get(bbuf, 0, 4);
irec[j] = (int) getUnsignedInt(bbuf);
- //System.out.println("...read uint " + irec[j]);
}
summary_offset = summary_offset + summary_size * 8; // bytes
summary.addRecord(drec[0],drec[1],irec[0],irec[1],irec[2],irec[3],irec[4],irec[5]);
}
+ if (nxt != 0)
+ {
+ summary_offset = (nxt - 1) * RECLEN;
+ }
}
}
catch (Exception e)
{
- System.err.println("ERROR: Error opening BSP file" + path);
+ System.out.println("Error (e.g. opening file, wrong detection of endianness)");
}
isInit = true;
return;
@@ -279,23 +395,19 @@ public void initWithBSPFile(String path) {
* @param observer Code for server object
* @return position [m] and velocity [m/s]
*/
- public Vector3D[] getPositionVelocity(double et, int target, int observer) {
- // et is the relative time in seconds from J2000, so can be minus or plus
- // target is an index, i.e. 0 for SBB, 3 for EMB, 901 for Charon, etc
- // observer is an index (same as target)
- Vector3D[] result = new Vector3D[2];
+ public Vector3D[] getPositionVelocity(double et, int target, int observer)
+ {
+ Vector3D[] result = new Vector3D[2];
result[0] = new Vector3D();
result[1] = new Vector3D();
int order;
- if (!isInit)
- {
- System.out.println("SPK::getPosVel, class instance not initialized");
+ if (!isInit) {
+ System.out.println("SPK::getPositionVelocity, class instance not initialized");
return result;
}
- int idx = summary.searchRecord(et,target,observer);
- if (idx==-1)
- {
- System.out.println("SPK::getPosVel, Cannot find record");
+ int idx = summary.searchRecord(et, target, observer);
+ if (idx == -1) {
+ System.out.println("SPK::getPositionVelocity, Cannot find record");
System.out.println(" et = " + et);
System.out.println(" target = " + target);
System.out.println(" observer = " + observer);
@@ -304,69 +416,104 @@ public Vector3D[] getPositionVelocity(double et, int target, int observer) {
int type = summary._type[idx];
int rbeg = summary._rbeg[idx];
int rend = summary._rend[idx];
- int offset = (rend - 4) * 8;
- //read four doubles according to DAF spec
- buffer.position(offset);
- buffer.get(bbuf, 0, 8);
- double init = (double) getDouble(bbuf);
- buffer.get(bbuf, 0, 8);
- double intlen = (double) getDouble(bbuf);
- buffer.get(bbuf, 0, 8);
- double rsize = (double) getDouble(bbuf);
- buffer.get(bbuf, 0, 8);
- double _n = (double) getDouble(bbuf);
- int internal_offset = (int) (Math.floor((et - init) / intlen) * rsize);
- int record = 8 * (int)(rbeg + internal_offset);
- double px=0.0,py=0.0,pz=0.0;
- double vx=0.0,vy=0.0,vz=0.0;
-
- if (type == 2) // Type II interpolation
- {
- for (int i=0; i<(int)rsize; i++)
- {
- buffer.position(((record-8)+i*8));
+ double px = 0.0, py = 0.0, pz = 0.0;
+ double vx = 0.0, vy = 0.0, vz = 0.0;
+
+ if (type == 1) { // Type I interpolation
+ // original code by Marco Brasse' based on original DAF/SPK specification
+ int M = 71; // specified value for Type-1 interpolation
+ int offset = (rend - 1) * 8;
+ buffer.position(offset);
+ buffer.get(bbuf, 0, 8);
+ int n = (int) (getDouble(bbuf));
+ int dir_size = n + n / 100;
+ assert (n >= 1);
+ int s0 = -1; // on purpose, a negative number due to how data is structured in file
+ int s1 = n - 1;
+ int m;
+ double t;
+ // binary search in epoch table
+ while (s1 != s0 + 1) {
+ m = (s0 + s1) / 2; // m>=0
+ offset = (rend - (dir_size + 1 - m)) * 8;
+ buffer.position(offset);
buffer.get(bbuf, 0, 8);
- data[i] = (double) getDouble(bbuf);
+ t = getDouble(bbuf);
+ if (et > t) s0 = m;
+ else s1 = m;
+ }
+ idx = s0 + 1;
+ assert (idx >= 0);
+ // Extract parameters of MDA record in file
+ double[] p = new double[M];
+ for (int i = 0; i < M; i++) {
+ offset = (rbeg - 1) * 8 + idx * M * 8 + i * 8;
+ buffer.position(offset);
+ buffer.get(bbuf, 0, 8);
+ p[i] = getDouble(bbuf);
}
- order = (int) (((int)(rsize) - 2) / 3 - 1);
- double tau = (et - data[0]) / data[1];
- int deg = (int)(order + 1);
- double factor = 1.0 / data[1];
-
- px = chebyshev(order, tau, 2+0*deg);
- py = chebyshev(order, tau, 2+1*deg);
- pz = chebyshev(order, tau, 2+2*deg);
- vx = der_chebyshev(order, tau, 2+0*deg)*factor;
- vy = der_chebyshev(order, tau, 2+1*deg)*factor;
- vz = der_chebyshev(order, tau, 2+2*deg)*factor;
+ // compute position and velocity from MDA record
+ double[] state = spke01(et, p);
+ px = state[0];
+ py = state[1];
+ pz = state[2];
+ vx = state[3];
+ vy = state[4];
+ vz = state[5];
}
- else if (type == 3) // Type III interpolation
+ else if ((type == 2) || (type==3)) // Type II or III interpolation
{
- for (int i=0; i<(int)rsize; i++)
- {
- buffer.position((record-8)+i*8);
+ int offset = (rend - 4) * 8;
+ buffer.position(offset);
+ buffer.get(bbuf, 0, 8);
+ double init = (double) getDouble(bbuf);
+ buffer.get(bbuf, 0, 8);
+ double intlen = (double) getDouble(bbuf);
+ buffer.get(bbuf, 0, 8);
+ double rsize = (double) getDouble(bbuf);
+ buffer.get(bbuf, 0, 8);
+ double _n = (double) getDouble(bbuf);
+ int internal_offset = (int) (Math.floor((et - init) / intlen) * rsize);
+ int record = 8 * (int) (rbeg + internal_offset);
+
+ for (int i = 0; i < (int) rsize; i++) {
+ buffer.position(((record - 8) + i * 8));
buffer.get(bbuf, 0, 8);
data[i] = (double) getDouble(bbuf);
}
- order =(int)(((int)(rsize) - 2) / 6 - 1);
- double tau = (et - data[0]) / data[1];
- int deg = (int)(order + 1);
- px = chebyshev(order, tau, 2+0*deg);
- py = chebyshev(order, tau, 2+1*deg);
- pz = chebyshev(order, tau, 2+2*deg);
- vx = chebyshev(order, tau, 2+3*deg);
- vy = chebyshev(order, tau, 2+4*deg);
- vz = chebyshev(order, tau, 2+5*deg);
- }
- else
- {
- System.out.println("Type not recognized");
- return result;
+
+ if (type==2) { // Type II specific interpolation
+ order = (int) (((int) (rsize) - 2) / 3 - 1);
+ double tau = (et - data[0]) / data[1];
+ int deg = (int) (order + 1);
+ double factor = 1.0 / data[1];
+
+ px = chebyshev(order, tau, 2 + 0 * deg);
+ py = chebyshev(order, tau, 2 + 1 * deg);
+ pz = chebyshev(order, tau, 2 + 2 * deg);
+ vx = der_chebyshev(order, tau, 2 + 0 * deg) * factor;
+ vy = der_chebyshev(order, tau, 2 + 1 * deg) * factor;
+ vz = der_chebyshev(order, tau, 2 + 2 * deg) * factor;
+ }
+ else { // Type III specific interpolation
+ order = (int) (((int) (rsize) - 2) / 6 - 1);
+ double tau = (et - data[0]) / data[1];
+ int deg = (int) (order + 1);
+ px = chebyshev(order, tau, 2 + 0 * deg);
+ py = chebyshev(order, tau, 2 + 1 * deg);
+ pz = chebyshev(order, tau, 2 + 2 * deg);
+ vx = chebyshev(order, tau, 2 + 3 * deg);
+ vy = chebyshev(order, tau, 2 + 4 * deg);
+ vz = chebyshev(order, tau, 2 + 5 * deg);
+ }
+ } else {
+ System.out.println("SPK::getPositionVelocity, interpolation type in BSP file not recognized");
+ // return initialized values (0,0,0,0,0,0)
}
// Convert position to m and velocity to m/s
- result[0] = new Vector3D(px*1000,py*1000,pz*1000);
- result[1] = new Vector3D(vx*1000,vy*1000,vz*1000);
+ result[0] = new Vector3D(1000.0*px, 1000.0*py, 1000.0*pz);
+ result[1] = new Vector3D(1000.0*vx, 1000.0*vy, 1000.0*vz);
return result;
}
}
\ No newline at end of file
diff --git a/src/main/java/experiments/SpacecraftGalileoEphemerisExperiment.java b/src/main/java/experiments/SpacecraftGalileoEphemerisExperiment.java
new file mode 100644
index 00000000..26571b56
--- /dev/null
+++ b/src/main/java/experiments/SpacecraftGalileoEphemerisExperiment.java
@@ -0,0 +1,456 @@
+/*
+ * Copyright (c) 2022 Nico Kuijpers
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is furnished
+ * to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR I
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
+ * IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+package experiments;
+
+import ephemeris.*;
+import util.Vector3D;
+
+import java.util.Calendar;
+import java.util.GregorianCalendar;
+
+/**
+ * This experiment is designed to confirm that the ephemeris of the Galileo spacecraft
+ * is valid during the entire mission.
+ * In this experiment, position and velocity of the spacecraft are determined each 1 minute
+ * and checked for validity against the previously obtained position and velocity.
+ * @author Nico Kuijpers
+ */
+public class SpacecraftGalileoEphemerisExperiment {
+
+ // Ephemeris for the entire Galileo mission with the Sun as center body
+ private static final IEphemeris ephemerisGalileo = EphemerisGalileoBSP.getInstance();
+
+ // Ephemeris for the Interplanetary cruise with the Sun as center body
+ private static final IEphemeris ephemerisGalileoCruise = EphemerisGalileoCruiseBSP.getInstance();
+
+ // Ephemeris for the Galileo mission after the interplanetary cruise with Jupiter as center body
+ private static final IEphemeris ephemerisGalileoJupiter = EphemerisGalileoJupiterBSP.getInstance();
+
+ // Time step [s]
+ private static final int timeStep = 60; // 1 minute
+
+ // Maximum allowed deviation in position [m]
+ private final double maxDeviationPosition = 1.0E05; // 100 km
+
+ // Maximum allowed deviation in velocity [m/s]
+ private final double maxDeviationVelocity = 1.0E03; // 1 km/s
+
+ public SpacecraftGalileoEphemerisExperiment() {
+ }
+
+ /**
+ * Validate ephemeris for spacecraft with given name.
+ * @param ephemeris ephemeris for spacecraft
+ * @param centerBody name of the center body corresponding to ephemeris
+ * @param spacecraftName name of the spacecraft
+ * @param timeStep time step [s]
+ */
+ private void validateEphemerisForSpacecraft(IEphemeris ephemeris, String centerBody, String spacecraftName, int timeStep) {
+
+ // Initialization
+ double muCenterBody = SolarSystemParameters.getInstance().getMu(centerBody);
+ GregorianCalendar experimentDateTime = (GregorianCalendar) ephemeris.getFirstValidDate().clone();
+ Vector3D[] positionVelocityInit = ephemeris.getBodyPositionVelocity(spacecraftName, experimentDateTime);
+ Vector3D positionInit = positionVelocityInit[0];
+ Vector3D velocityInit = positionVelocityInit[1];
+ double[] orbitParameters =
+ EphemerisUtil.computeOrbitalParametersFromPositionVelocity(muCenterBody,positionInit,velocityInit,experimentDateTime);
+
+ // Count number of violations
+ int nrViolations = 0;
+
+ // Start experiment
+ while (experimentDateTime.before(ephemeris.getLastValidDate())) {
+
+ // Update experiment date/time
+ experimentDateTime.add(Calendar.SECOND,timeStep);
+
+ // Predict current position and velocity from orbital parameters
+ double[] orbitElements = EphemerisUtil.computeOrbitalElements(orbitParameters,experimentDateTime);
+ Vector3D positionPredicted = EphemerisUtil.computePosition(orbitElements);
+ Vector3D velocityPredicted = EphemerisUtil.computeVelocity(muCenterBody, orbitElements);
+
+ // Actual position and velocity of spacecraft according to ephemeris
+ Vector3D[] positionVelocitySpacecraft = ephemeris.getBodyPositionVelocity(spacecraftName, experimentDateTime);
+ Vector3D position = positionVelocitySpacecraft[0];
+ Vector3D velocity = positionVelocitySpacecraft[1];
+
+ // Update orbital parameters
+ orbitParameters = EphemerisUtil.computeOrbitalParametersFromPositionVelocity(muCenterBody,position,velocity,experimentDateTime);
+
+ // Check whether position and velocity are defined
+ if (position.magnitude() < 1.0 || velocity.magnitude() < 1.0) {
+ System.out.println("Date/time: " + CalendarUtil.calendarToString(experimentDateTime));
+ System.out.println(" No ephemeris for " + spacecraftName +
+ " Julian date = " + JulianDateConverter.convertCalendarToJulianDate(experimentDateTime));
+ }
+
+ // Validity check
+ double deviationPosition = position.euclideanDistance(positionPredicted);
+ double deviationVelocity = velocity.euclideanDistance(velocityPredicted);
+ if (deviationPosition > maxDeviationPosition || deviationVelocity > maxDeviationVelocity) {
+ nrViolations++;
+ System.out.println("Date/time: " + CalendarUtil.calendarToString(experimentDateTime));
+ System.out.println(" Center body : " + centerBody);
+ System.out.println(" Deviation position : " + deviationPosition/1000.0 + " km");
+ System.out.println(" Deviation velocity : " + deviationVelocity + " m/s");
+ }
+ }
+
+ // Print number of violations
+ System.out.println("Number of violations : " + nrViolations +"\n");
+ }
+
+ /**
+ * Main method.
+ * Validate ephemeris for spacecraft Galileo.
+ * @param args input arguments (not used)
+ */
+ public static void main(String[] args) {
+ // Experiment set-up
+ SpacecraftGalileoEphemerisExperiment experiment = new SpacecraftGalileoEphemerisExperiment();
+
+ // Run experiment for the entire Galileo mission
+ System.out.println("Validity check for entire Galileo mission");
+ experiment.validateEphemerisForSpacecraft(ephemerisGalileo, "Sun", "Galileo", timeStep );
+
+ // Run experiment for the Interplanetary cruise of theGalileo mission
+ System.out.println("Validity check for Interplanetary cruise of the Galileo mission");
+ experiment.validateEphemerisForSpacecraft(ephemerisGalileoCruise, "Sun", "Galileo", timeStep );
+
+ // Run experiment for the Primary tour, GEM, and GMM parts of the Galileo mission
+ System.out.println("Validity check for Primary tour, GEM, and GMM parts of the Galileo mission");
+ experiment.validateEphemerisForSpacecraft(ephemerisGalileoJupiter, "Jupiter", "Galileo", timeStep);
+
+ // Finished
+ System.out.println("Validity checks finished");
+ }
+}
+ /*
+ Results with
+ Maximum allowed deviation in position 100 km
+ Maximum allowed deviation in velocity 1 km/s
+
+ Validity check for entire Galileo mission
+ Date/time: 1990-06-07 00:01:00.000
+ Center body : Sun
+ Deviation position : 151.92615852221869 km
+ Deviation velocity : 0.14836601143661002 m/s
+ Date/time: 1992-04-19 00:01:00.000
+ Center body : Sun
+ Deviation position : 597.155337175086 km
+ Deviation velocity : 0.05344005572126688 m/s
+ Date/time: 1992-10-20 00:01:00.000
+ Center body : Sun
+ Deviation position : 658.9426381321225 km
+ Deviation velocity : 0.7211208303536897 m/s
+ Date/time: 1993-07-05 00:02:00.000
+ Center body : Sun
+ Deviation position : 143.1779121345211 km
+ Deviation velocity : 0.013325001575939832 m/s
+ Date/time: 1993-10-23 08:01:00.000
+ Center body : Sun
+ Deviation position : 117.45987619108952 km
+ Deviation velocity : 0.0035023624731021566 m/s
+ Date/time: 1994-03-30 00:02:00.000
+ Center body : Sun
+ Deviation position : 144.43077366497283 km
+ Deviation velocity : 0.024539111565242896 m/s
+ Date/time: 1995-11-21 00:00:00.000
+ Center body : Sun
+ Deviation position : 310.1826235971203 km
+ Deviation velocity : 0.08907303381546279 m/s
+ Date/time: 1995-11-21 00:01:00.000
+ Center body : Sun
+ Deviation position : 172.9186863887463 km
+ Deviation velocity : 1.1263788242963875 m/s
+ Date/time: 1996-07-02 05:28:00.000
+ Center body : Sun
+ Deviation position : 156.771294015495 km
+ Deviation velocity : 0.7511303187162287 m/s
+ Date/time: 1997-01-23 06:06:00.000
+ Center body : Sun
+ Deviation position : 267.7855295910289 km
+ Deviation velocity : 1.1944767671181316 m/s
+ Date/time: 1999-08-11 16:20:00.000
+ Center body : Sun
+ Deviation position : 390.41405719990564 km
+ Deviation velocity : 7.341528207363376 m/s
+ Date/time: 2000-11-01 12:02:00.000
+ Center body : Sun
+ Deviation position : 178.70479910015848 km
+ Deviation velocity : 0.021451289714875095 m/s
+ Date/time: 2002-09-11 12:01:00.000
+ Center body : Sun
+ Deviation position : 289.68386517219176 km
+ Deviation velocity : 0.03256136352274796 m/s
+ Date/time: 2003-01-28 01:01:00.000
+ Center body : Sun
+ Deviation position : 406.94739922670635 km
+ Deviation velocity : 0.042183220053723186 m/s
+ Date/time: 2003-09-21 18:49:00.000
+ Center body : Sun
+ Deviation position : 30.25783460368449 km
+ Deviation velocity : 1015.4893811052129 m/s
+ Date/time: 2003-09-21 18:50:00.000
+ Center body : Sun
+ Deviation position : 31.524659168957065 km
+ Deviation velocity : 1058.0440468438233 m/s
+ Date/time: 2003-09-21 18:51:00.000
+ Center body : Sun
+ Deviation position : 32.85183740468746 km
+ Deviation velocity : 1102.6325871772347 m/s
+ Date/time: 2003-09-21 18:52:00.000
+ Center body : Sun
+ Deviation position : 34.239914360253024 km
+ Deviation velocity : 1149.2699929907528 m/s
+ Date/time: 2003-09-21 18:53:00.000
+ Center body : Sun
+ Deviation position : 35.69095829175699 km
+ Deviation velocity : 1197.9508250050205 m/s
+ Date/time: 2003-09-21 18:54:00.000
+ Center body : Sun
+ Deviation position : 37.20159033149421 km
+ Deviation velocity : 1248.6353916451783 m/s
+ Date/time: 2003-09-21 18:55:00.000
+ Center body : Sun
+ Deviation position : 38.7698308040119 km
+ Deviation velocity : 1301.246135824934 m/s
+ Date/time: 2003-09-21 18:56:00.000
+ Center body : Sun
+ Deviation position : 40.39377398275529 km
+ Deviation velocity : 1355.6587604274725 m/s
+ Date/time: 2003-09-21 18:57:00.000
+ Center body : Sun
+ Deviation position : 42.06840770245949 km
+ Deviation velocity : 1411.6934806896431 m/s
+ Date/time: 2003-09-21 18:58:00.000
+ Center body : Sun
+ Deviation position : 43.78399449340801 km
+ Deviation velocity : 1469.10592012084 m/s
+ Date/time: 2003-09-21 18:59:00.000
+ Center body : Sun
+ Deviation position : 45.53428777125963 km
+ Deviation velocity : 1527.5781132441039 m/s
+ Date/time: 2003-09-21 19:00:00.000
+ Center body : Sun
+ Deviation position : 47.30601103868969 km
+ Deviation velocity : 1586.7103576448137 m/s
+ Date/time: 2003-09-21 19:01:00.000
+ Center body : Sun
+ Deviation position : 49.08573464567123 km
+ Deviation velocity : 1646.0146420144076 m/s
+ Date/time: 2003-09-21 19:02:00.000
+ Center body : Sun
+ Deviation position : 50.856444088286274 km
+ Deviation velocity : 1704.9120353496996 m/s
+ Date/time: 2003-09-21 19:03:00.000
+ Center body : Sun
+ Deviation position : 52.598840801387155 km
+ Deviation velocity : 1762.7270851340138 m/s
+ Date/time: 2003-09-21 19:04:00.000
+ Center body : Sun
+ Deviation position : 54.28948596264776 km
+ Deviation velocity : 1818.7047307345488 m/s
+ Date/time: 2003-09-21 19:05:00.000
+ Center body : Sun
+ Deviation position : 55.904637799986 km
+ Deviation velocity : 1872.010819443555 m/s
+ Date/time: 2003-09-21 19:06:00.000
+ Center body : Sun
+ Deviation position : 57.41690536570918 km
+ Deviation velocity : 1921.7570236064735 m/s
+ Date/time: 2003-09-21 19:07:00.000
+ Center body : Sun
+ Deviation position : 58.79978470622002 km
+ Deviation velocity : 1967.026651760979 m/s
+ Date/time: 2003-09-21 19:08:00.000
+ Center body : Sun
+ Deviation position : 60.025631412299006 km
+ Deviation velocity : 2006.9087735536345 m/s
+ Date/time: 2003-09-21 19:09:00.000
+ Center body : Sun
+ Deviation position : 61.0680200154517 km
+ Deviation velocity : 2040.5379980931464 m/s
+ Date/time: 2003-09-21 19:10:00.000
+ Center body : Sun
+ Deviation position : 61.903015966417044 km
+ Deviation velocity : 2067.137404296035 m/s
+ Date/time: 2003-09-21 19:11:00.000
+ Center body : Sun
+ Deviation position : 62.51063273469397 km
+ Deviation velocity : 2086.0610847353346 m/s
+ Date/time: 2003-09-21 19:12:00.000
+ Center body : Sun
+ Deviation position : 62.875505133449415 km
+ Deviation velocity : 2096.832306366511 m/s
+ Date/time: 2003-09-21 19:13:00.000
+ Center body : Sun
+ Deviation position : 62.98828544483812 km
+ Deviation velocity : 2099.173245454756 m/s
+ Date/time: 2003-09-21 19:14:00.000
+ Center body : Sun
+ Deviation position : 62.84607852807282 km
+ Deviation velocity : 2093.0243164583726 m/s
+ Date/time: 2003-09-21 19:15:00.000
+ Center body : Sun
+ Deviation position : 62.45252987237564 km
+ Deviation velocity : 2078.541152433565 m/s
+ Date/time: 2003-09-21 19:16:00.000
+ Center body : Sun
+ Deviation position : 61.81744279359826 km
+ Deviation velocity : 2056.0982354785992 m/s
+ Date/time: 2003-09-21 19:17:00.000
+ Center body : Sun
+ Deviation position : 60.957193467796984 km
+ Deviation velocity : 2026.2512093838122 m/s
+ Date/time: 2003-09-21 19:18:00.000
+ Center body : Sun
+ Deviation position : 59.89224316516262 km
+ Deviation velocity : 1989.7099587914777 m/s
+ Date/time: 2003-09-21 19:19:00.000
+ Center body : Sun
+ Deviation position : 58.64706122650811 km
+ Deviation velocity : 1947.2965328855755 m/s
+ Date/time: 2003-09-21 19:20:00.000
+ Center body : Sun
+ Deviation position : 57.24811814052916 km
+ Deviation velocity : 1899.9019611479675 m/s
+ Date/time: 2003-09-21 19:21:00.000
+ Center body : Sun
+ Deviation position : 55.72182390051741 km
+ Deviation velocity : 1848.4443639571464 m/s
+ Date/time: 2003-09-21 19:22:00.000
+ Center body : Sun
+ Deviation position : 54.09634456082249 km
+ Deviation velocity : 1793.831461783819 m/s
+ Date/time: 2003-09-21 19:23:00.000
+ Center body : Sun
+ Deviation position : 52.39924175727548 km
+ Deviation velocity : 1736.929559277826 m/s
+ Date/time: 2003-09-21 19:24:00.000
+ Center body : Sun
+ Deviation position : 50.652426980824096 km
+ Deviation velocity : 1678.540073412216 m/s
+ Date/time: 2003-09-21 19:25:00.000
+ Center body : Sun
+ Deviation position : 48.88046643846314 km
+ Deviation velocity : 1619.3847076432687 m/s
+ Date/time: 2003-09-21 19:26:00.000
+ Center body : Sun
+ Deviation position : 47.10000051123386 km
+ Deviation velocity : 1560.0912258213718 m/s
+ Date/time: 2003-09-21 19:27:00.000
+ Center body : Sun
+ Deviation position : 45.330700140458084 km
+ Deviation velocity : 1501.2013501802878 m/s
+ Date/time: 2003-09-21 19:28:00.000
+ Center body : Sun
+ Deviation position : 43.58345453350916 km
+ Deviation velocity : 1443.161631709472 m/s
+ Date/time: 2003-09-21 19:29:00.000
+ Center body : Sun
+ Deviation position : 41.87157865467397 km
+ Deviation velocity : 1386.334108811493 m/s
+ Date/time: 2003-09-21 19:30:00.000
+ Center body : Sun
+ Deviation position : 40.203580937576554 km
+ Deviation velocity : 1331.0025846612627 m/s
+ Date/time: 2003-09-21 19:31:00.000
+ Center body : Sun
+ Deviation position : 38.58569931337139 km
+ Deviation velocity : 1277.3812924063807 m/s
+ Date/time: 2003-09-21 19:32:00.000
+ Center body : Sun
+ Deviation position : 37.023785122130725 km
+ Deviation velocity : 1225.6239694880799 m/s
+ Date/time: 2003-09-21 19:33:00.000
+ Center body : Sun
+ Deviation position : 35.519209694109 km
+ Deviation velocity : 1175.8328661743897 m/s
+ Date/time: 2003-09-21 19:34:00.000
+ Center body : Sun
+ Deviation position : 34.07681934000133 km
+ Deviation velocity : 1128.067251158058 m/s
+ Date/time: 2003-09-21 19:35:00.000
+ Center body : Sun
+ Deviation position : 32.695110680773254 km
+ Deviation velocity : 1082.351165834976 m/s
+ Date/time: 2003-09-21 19:36:00.000
+ Center body : Sun
+ Deviation position : 31.373349352296117 km
+ Deviation velocity : 1038.6810364970124 m/s
+ Number of violations : 62
+
+ Validity check for Interplanetary cruise of the Galileo mission
+ Date/time: 1990-06-07 00:01:00.000
+ Center body : Sun
+ Deviation position : 151.92615852221869 km
+ Deviation velocity : 0.14836601143661002 m/s
+ Date/time: 1992-04-19 00:01:00.000
+ Center body : Sun
+ Deviation position : 597.155337175086 km
+ Deviation velocity : 0.05344005572126688 m/s
+ Date/time: 1992-10-20 00:01:00.000
+ Center body : Sun
+ Deviation position : 658.9426381321225 km
+ Deviation velocity : 0.7211208303536897 m/s
+ Date/time: 1993-07-05 00:02:00.000
+ Center body : Sun
+ Deviation position : 143.1779121345211 km
+ Deviation velocity : 0.013325001575939832 m/s
+ Date/time: 1993-10-23 08:01:00.000
+ Center body : Sun
+ Deviation position : 117.45987619108952 km
+ Deviation velocity : 0.0035023624731021566 m/s
+ Date/time: 1994-03-30 00:02:00.000
+ Center body : Sun
+ Deviation position : 144.43077366497283 km
+ Deviation velocity : 0.024539111565242896 m/s
+ Number of violations : 6
+
+ Validity check for Primary tour, GEM, and GMM parts of the Galileo mission
+ Date/time: 1995-11-21 00:00:00.000
+ Center body : Jupiter
+ Deviation position : 310.182651472387 km
+ Deviation velocity : 0.07489990333735713 m/s
+ Date/time: 1995-11-21 00:01:00.000
+ Center body : Jupiter
+ Deviation position : 172.9186008059062 km
+ Deviation velocity : 1.1615791629680043 m/s
+ Date/time: 2000-11-01 12:02:00.000
+ Center body : Jupiter
+ Deviation position : 178.70476231446884 km
+ Deviation velocity : 0.005407727552543998 m/s
+ Date/time: 2002-09-11 12:01:00.000
+ Center body : Jupiter
+ Deviation position : 289.6838631490976 km
+ Deviation velocity : 0.025658671154039258 m/s
+ Date/time: 2003-01-28 01:01:00.000
+ Center body : Jupiter
+ Deviation position : 406.9473942094898 km
+ Deviation velocity : 0.040037638369892777 m/s
+ Number of violations : 5
+
+ Validity checks finished
+ */
+
+
+
diff --git a/src/main/java/spacecraft/Galileo.java b/src/main/java/spacecraft/Galileo.java
index 7ffdddfa..c415bcb6 100644
--- a/src/main/java/spacecraft/Galileo.java
+++ b/src/main/java/spacecraft/Galileo.java
@@ -19,9 +19,9 @@
*/
package spacecraft;
-import ephemeris.CalendarUtil;
-import ephemeris.JulianDateConverter;
+import ephemeris.*;
import solarsystem.SolarSystem;
+import util.Vector3D;
import java.io.File;
import java.io.FileNotFoundException;
@@ -86,7 +86,7 @@ public class Galileo extends Spacecraft implements Serializable {
* TCM-11 Oct 9, 1991 Gaspra target cleanup
* TCM-12 Oct 24, 1991 Gaspra target cleanup
* Gaspra encounter Oct 29, 1991
- * TCM-14 Aug 14, 1992 First Earth-2 target
+ * TCM-14 Aug 4, 1992 First Earth-2 target
* TCM-15 Oct 9, 1992 Second Earth-2 target
* TCM-16 Nov 13, 1992 Final Earth-2 target
* TCM-17 Nov 28, 1992 Post Earth-2 cleanup
@@ -124,9 +124,11 @@ public class Galileo extends Spacecraft implements Serializable {
* On the basis of known TCMs and encounters, the following corrections are simulated:
* 19-Oct-1989 02:00:00 after launch
* 20-Oct-1989 00:00:00 correction after launch
+ * 11-Nov-1989 10:00:00 after TCM-1
* 12-Nov-1989 00:00:00 after TCM-1
* 23-Dec-1989 00:00:00 after TCM-2
* 10-Feb-1990 00:00:00 before Venus encounter
+ * 11-Feb-1990 00:00:00 after Venus encounter
* 12-Feb-1990 00:00:00 after Venus encounter
* 13-Apr-1990 00:00:00 after TCM-4A
* 13-May-1990 00:00:00 after TCM-4B
@@ -135,20 +137,28 @@ public class Galileo extends Spacecraft implements Serializable {
* 14-Nov-1990 00:00:00 after TCM-7
* 29-Nov-1990 00:00:00 after TCM-8
* 08-Dec-1990 00:00:00 before first Earth encounter
+ * 09-Dec-1990 00:00:00 after first Earth encounter
* 10-Dec-1990 00:00:00 after first Earth encounter
* 20-Dec-1990 00:00:00 after TCM-9A
* 21-Mar-1991 00:00:00 after TCM-9B
* 03-Jul-1991 00:00:00 after TCM-10
* 10-Oct-1991 00:00:00 after TCM-11
* 25-Oct-1991 00:00:00 after TCM-12
- * 15-Aug-1992 00:00:00 after TCM-14
+ * 05-Aug-1992 00:00:00 after TCM-14
+ * 06-Aug-1992 00:00:00 after TCM-14
+ * 10-Aug-1992 00:00:00 after TCM-14
* 10-Oct-1992 00:00:00 after TCM-15
* 14-Nov-1992 00:00:00 after TCM-16
* 29-Nov-1992 00:00:00 after TCM-17
* 08-Dec-1992 00:00:00 before second Earth encounter
+ * 09-Dec-1992 00:00:00 after second Earth encounter
* 10-Dec-1992 00:00:00 after second Earth encounter
+ * 11-Apr-1993 00:00:00 extra correction
* 05-Oct-1993 00:00:00 after TCM-22
+ * 06-Oct-1993 00:00:00 after TCM-22
+ * 09-Oct-1993 00:00:00 after TCM-22
* 16-Feb-1994 00:00:00 after TCM-22A
+ * 01-Mar-1995 00:00:00 extra correction
* 13-Apr-1995 00:00:00 after TCM-23
* 10-Jul-1995 00:00:00 probe release
* 28-Jul-1995 00:00:00 after Orbit Deflection Maneuver
@@ -156,17 +166,27 @@ public class Galileo extends Spacecraft implements Serializable {
* 18-Nov-1995 00:00:00 three weeks before Jupiter Orbit Insertion
* 25-Nov-1995 00:00:00 two weeks before Jupiter Orbit Insertion
* 01-Dec-1995 00:00:00 one week before Jupiter Orbit Insertion, transfer spacecraft to Jupiter System
- * 07-Dec-1995 00:00:00 Before IO flyby
+ * 07-Dec-1995 00:00:00 before IO flyby
+ * 08-Dec-1995 00:00:00 after IO flyby
+ * 08-Dec-1995 02:00:00 after IO flyby
+ * 08-Dec-1995 04:00:00 after IO flyby
+ * 08-Dec-1995 06:00:00 after IO flyby
* 09-Dec-1995 00:00:00 after Jupiter Orbit Insertion
+ * 10-Dec-1995 00:00:00 after Jupiter Orbit Insertion
+ * 22-Jan-1995 00:00:00 extra correction
+ * 15-Mar-1996 00:00:00 after PJR (Peri-Jove Raise Maneuver)
* 15-Mar-1996 00:00:00 after PJR (Peri-Jove Raise Maneuver) on Mar 14, 1996
* 04-May-1996 00:00:00 after OTM-4
* 13-Jun-1996 00:00:00 after OTM-5
* 25-Jun-1996 00:00:00 after OTM-6
* 01-Aug-1996 00:00:00 after OTM-7
* 06-Aug-1996 00:00:00 after OTM-8
+ * 07-Aug-1996 00:00:00 after OTM-8
* 28-Aug-1996 00:00:00 after OTM-9
* 10-Sep-1996 00:00:00 after OTM-11
+ * 11-Sep-1996 00:00:00 after OTM-11
* 09-Oct-1996 00:00:00 after OTM-12
+ * 10-Oct-1996 00:00:00 after OTM-12
* 11-Nov-1996 00:00:00 after OTM-14
* 27-Nov-1996 00:00:00 after OTM-15
* 16-Dec-1996 00:00:00 after OTM-16
@@ -174,12 +194,14 @@ public class Galileo extends Spacecraft implements Serializable {
* 07-Feb-1997 00:00:00 after OTM-19
* 24-Feb-1997 00:00:00 after OTM-21
* 14-Mar-1997 00:00:00 after OTM-22
+ * 15-Mar-1997 00:00:00 after OTM-22
*
* https://en.wikipedia.org/wiki/Timeline_of_Galileo_(spacecraft)
- * In addition, three corrections are simulated for each encounter:
+ * In addition, four corrections are simulated for each encounter:
* 1 week before the encounter
* at 0.00 on the day of encounter
* at 0.00 on the next day
+ * at 0.00 the day thereafter
*
* Orbit: C: Callisto, E: Europa, G: Ganymede, I: Io, J: Jupiter, closest approach
* 27-Jun-1996 G1 835 km gravity-assist reduced Galileo's orbital period from 210 to 72 days
@@ -189,7 +211,7 @@ public class Galileo extends Spacecraft implements Serializable {
* 20-Jan-1997 J5 No close encounter to a Jovian moon was scheduled because Earth and Jupiter were in Sun conjunction
* 20-Feb-1997 E6 586 km
* 05-Apr-1997 G7 3102 km
- * 07-May-1997 G8 1603 km
+ * 07-May-1997 G8 1603 km (extra correction added on 12-May-1997 00:00)
* 25-Jun-1997 C9 418 km
* 17-Sep-1997 C10 539 km
* 06-Nov-1997 E11 1266 km
@@ -298,11 +320,26 @@ private void readOrbitParametersFromFile(String fileName) {
}
}
+ @Override
+ public void updateStatus(GregorianCalendar dateTime) {
+ // Obtain position and velocity from Ephemeris of Galileo
+ IEphemeris ephemerisGalileo = EphemerisGalileoBSP.getInstance();
+ if (!(dateTime.before(ephemerisGalileo.getFirstValidDate()) || dateTime.after(ephemerisGalileo.getLastValidDate()))) {
+ Vector3D[] positionVelocityGalileo = ephemerisGalileo.getBodyPositionVelocity("Galileo", dateTime);
+ Vector3D position = positionVelocityGalileo[0];
+ Vector3D velocity = positionVelocityGalileo[1];
+ setPosition(position);
+ setVelocity(velocity);
+ }
+ }
+
@Override
protected List defineTrajectories() {
readOrbitParametersFromFile("EphemerisFiles/orbitParsGalileoJupiter.txt");
List trajectories = new ArrayList<>();
eventDateTimes = new ArrayList<>();
+ double muSun = SolarSystemParameters.getInstance().getMu("Sun");
+ double muJupiter = SolarSystemParameters.getInstance().getMu("Jupiter");
int index = 0;
while (index < orbitPars.length) {
GregorianCalendar startDateTime = JulianDateConverter.convertJulianDateToCalendar(orbitDates[index]);
@@ -316,12 +353,31 @@ protected List defineTrajectories() {
String centerBodyName;
if (startDateTime.before(startJupiterCenterBody)) {
centerBodyName = "Sun";
+ // Use this code to obtain orbital parameters from Ephemeris of Interplanetary cruise
+ Vector3D[] positionVelocityGalileo = EphemerisGalileoBSP.getInstance().getBodyPositionVelocity("Galileo", startDateTime);
+ Vector3D position = positionVelocityGalileo[0];
+ Vector3D velocity = positionVelocityGalileo[1];
+ double[] orbitParsGalileo =
+ EphemerisUtil.computeOrbitalParametersFromPositionVelocity(muSun, position, velocity, startDateTime);
+ trajectories.add(
+ new SpacecraftTrajectory(startDateTime, stopDateTime, centerBodyName, orbitParsGalileo));
}
else {
centerBodyName = "Jupiter";
+ // Use this code to obtain orbital parameters from Ephemeris of Primary mission, GEM, and GMM
+ Vector3D[] positionVelocityGalileo = EphemerisGalileoJupiterBSP.getInstance().getBodyPositionVelocity("Galileo", startDateTime);
+ Vector3D position = positionVelocityGalileo[0];
+ Vector3D velocity = positionVelocityGalileo[1];
+ double[] orbitParsGalileo =
+ EphemerisUtil.computeOrbitalParametersFromPositionVelocity(muJupiter, position, velocity, startDateTime);
+ trajectories.add(
+ new SpacecraftTrajectory(startDateTime, stopDateTime, centerBodyName, orbitParsGalileo));
}
+ /*
+ // Use this line to use orbital parameters read from file
trajectories.add(
new SpacecraftTrajectory(startDateTime, stopDateTime, centerBodyName, orbitPars[index]));
+ */
eventDateTimes.add(startDateTime);
index++;
}
diff --git a/target/classes/ephemeris/EphemerisUtil.class b/target/classes/ephemeris/EphemerisUtil.class
index 657a5103..e52f77ef 100644
Binary files a/target/classes/ephemeris/EphemerisUtil.class and b/target/classes/ephemeris/EphemerisUtil.class differ