open-space-toolkit-astrodynamics 9.4.1__py38-none-manylinux2014_x86_64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- open_space_toolkit_astrodynamics-9.4.1.dist-info/METADATA +30 -0
- open_space_toolkit_astrodynamics-9.4.1.dist-info/RECORD +98 -0
- open_space_toolkit_astrodynamics-9.4.1.dist-info/WHEEL +5 -0
- open_space_toolkit_astrodynamics-9.4.1.dist-info/top_level.txt +1 -0
- open_space_toolkit_astrodynamics-9.4.1.dist-info/zip-safe +1 -0
- ostk/__init__.py +1 -0
- ostk/astrodynamics/OpenSpaceToolkitAstrodynamicsPy.cpython-38-x86_64-linux-gnu.so +0 -0
- ostk/astrodynamics/__init__.py +11 -0
- ostk/astrodynamics/converters.py +185 -0
- ostk/astrodynamics/display.py +220 -0
- ostk/astrodynamics/libopen-space-toolkit-astrodynamics.so.9 +0 -0
- ostk/astrodynamics/pytrajectory/__init__.py +1 -0
- ostk/astrodynamics/pytrajectory/pystate.py +36 -0
- ostk/astrodynamics/test/__init__.py +1 -0
- ostk/astrodynamics/test/access/__init__.py +1 -0
- ostk/astrodynamics/test/access/test_generator.py +248 -0
- ostk/astrodynamics/test/conftest.py +119 -0
- ostk/astrodynamics/test/conjunction/message/ccsds/__init__.py +1 -0
- ostk/astrodynamics/test/conjunction/message/ccsds/conftest.py +325 -0
- ostk/astrodynamics/test/conjunction/message/ccsds/data/cdm.json +303 -0
- ostk/astrodynamics/test/conjunction/message/ccsds/test_cdm.py +416 -0
- ostk/astrodynamics/test/dynamics/__init__.py +1 -0
- ostk/astrodynamics/test/dynamics/data/Tabulated_Earth_Gravity.csv +565 -0
- ostk/astrodynamics/test/dynamics/data/Tabulated_Earth_Gravity_Truth.csv +100 -0
- ostk/astrodynamics/test/dynamics/test_atmospheric_drag.py +128 -0
- ostk/astrodynamics/test/dynamics/test_central_body_gravity.py +58 -0
- ostk/astrodynamics/test/dynamics/test_dynamics.py +50 -0
- ostk/astrodynamics/test/dynamics/test_position_derivative.py +51 -0
- ostk/astrodynamics/test/dynamics/test_tabulated.py +138 -0
- ostk/astrodynamics/test/dynamics/test_third_body_gravity.py +67 -0
- ostk/astrodynamics/test/dynamics/test_thruster.py +142 -0
- ostk/astrodynamics/test/event_condition/test_angular_condition.py +113 -0
- ostk/astrodynamics/test/event_condition/test_boolean_condition.py +55 -0
- ostk/astrodynamics/test/event_condition/test_coe_condition.py +87 -0
- ostk/astrodynamics/test/event_condition/test_instant_condition.py +48 -0
- ostk/astrodynamics/test/event_condition/test_logical_condition.py +120 -0
- ostk/astrodynamics/test/event_condition/test_real_condition.py +50 -0
- ostk/astrodynamics/test/flight/__init__.py +1 -0
- ostk/astrodynamics/test/flight/system/__init__.py +1 -0
- ostk/astrodynamics/test/flight/system/test_propulsion_system.py +73 -0
- ostk/astrodynamics/test/flight/system/test_satellite_system.py +91 -0
- ostk/astrodynamics/test/flight/system/test_satellite_system_builder.py +71 -0
- ostk/astrodynamics/test/flight/test_maneuver.py +212 -0
- ostk/astrodynamics/test/flight/test_profile.py +153 -0
- ostk/astrodynamics/test/flight/test_system.py +55 -0
- ostk/astrodynamics/test/guidance_law/test_constant_thrust.py +91 -0
- ostk/astrodynamics/test/guidance_law/test_qlaw.py +138 -0
- ostk/astrodynamics/test/solvers/__init__.py +1 -0
- ostk/astrodynamics/test/solvers/test_finite_difference_solver.py +181 -0
- ostk/astrodynamics/test/solvers/test_temporal_condition_solver.py +153 -0
- ostk/astrodynamics/test/test_access.py +128 -0
- ostk/astrodynamics/test/test_converters.py +387 -0
- ostk/astrodynamics/test/test_display.py +115 -0
- ostk/astrodynamics/test/test_event_condition.py +58 -0
- ostk/astrodynamics/test/test_import.py +26 -0
- ostk/astrodynamics/test/test_root_solver.py +70 -0
- ostk/astrodynamics/test/test_trajectory.py +40 -0
- ostk/astrodynamics/test/test_utilities.py +121 -0
- ostk/astrodynamics/test/test_viewer.py +129 -0
- ostk/astrodynamics/test/trajectory/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/message/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/message/spacex/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/message/spacex/conftest.py +18 -0
- ostk/astrodynamics/test/trajectory/orbit/message/spacex/data/opm_1.yaml +44 -0
- ostk/astrodynamics/test/trajectory/orbit/message/spacex/test_opm.py +108 -0
- ostk/astrodynamics/test/trajectory/orbit/models/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/models/kepler/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_brouwer_lyddane_mean.py +65 -0
- ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_brouwer_lyddane_mean_long.py +102 -0
- ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_brouwer_lyddane_mean_short.py +102 -0
- ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_coe.py +167 -0
- ostk/astrodynamics/test/trajectory/orbit/models/sgp4/__init__.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/models/sgp4/test_tle.py +331 -0
- ostk/astrodynamics/test/trajectory/orbit/models/test_kepler.py +130 -0
- ostk/astrodynamics/test/trajectory/orbit/models/test_propagated.py +234 -0
- ostk/astrodynamics/test/trajectory/orbit/models/test_sgp4.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/models/test_tabulated.py +380 -0
- ostk/astrodynamics/test/trajectory/orbit/test_model.py +1 -0
- ostk/astrodynamics/test/trajectory/orbit/test_pass.py +72 -0
- ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_angular_velocity.py +30 -0
- ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_attitude_quaternion.py +18 -0
- ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_cartesian_position.py +107 -0
- ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_cartesian_velocity.py +115 -0
- ostk/astrodynamics/test/trajectory/state/test_coordinate_broker.py +84 -0
- ostk/astrodynamics/test/trajectory/state/test_coordinate_subset.py +46 -0
- ostk/astrodynamics/test/trajectory/state/test_numerical_solver.py +314 -0
- ostk/astrodynamics/test/trajectory/test_local_orbital_frame_direction.py +81 -0
- ostk/astrodynamics/test/trajectory/test_local_orbital_frame_factory.py +76 -0
- ostk/astrodynamics/test/trajectory/test_model.py +1 -0
- ostk/astrodynamics/test/trajectory/test_orbit.py +174 -0
- ostk/astrodynamics/test/trajectory/test_propagator.py +458 -0
- ostk/astrodynamics/test/trajectory/test_segment.py +305 -0
- ostk/astrodynamics/test/trajectory/test_sequence.py +477 -0
- ostk/astrodynamics/test/trajectory/test_state.py +237 -0
- ostk/astrodynamics/test/trajectory/test_state_builder.py +171 -0
- ostk/astrodynamics/utilities.py +158 -0
- ostk/astrodynamics/viewer.py +392 -0
@@ -0,0 +1,30 @@
|
|
1
|
+
Metadata-Version: 2.1
|
2
|
+
Name: open-space-toolkit-astrodynamics
|
3
|
+
Version: 9.4.1
|
4
|
+
Summary: Orbit, attitude, access.
|
5
|
+
Author: Open Space Collective
|
6
|
+
Author-email: contact@open-space-collective.org
|
7
|
+
License: Apache License 2.0
|
8
|
+
Keywords: open-space-collective,open-space-toolkit astrodynamics
|
9
|
+
Classifier: Development Status :: 3 - Alpha
|
10
|
+
Classifier: Programming Language :: Python :: 3
|
11
|
+
Classifier: License :: OSI Approved :: Apache Software License
|
12
|
+
Classifier: Operating System :: POSIX :: Linux
|
13
|
+
Description-Content-Type: text/markdown
|
14
|
+
Requires-Dist: open-space-toolkit-core ~=3.0
|
15
|
+
Requires-Dist: open-space-toolkit-io ~=3.0
|
16
|
+
Requires-Dist: open-space-toolkit-mathematics ~=3.0
|
17
|
+
Requires-Dist: open-space-toolkit-physics ~=7.0
|
18
|
+
|
19
|
+
# Open Space Toolkit ▸ Astrodynamics
|
20
|
+
|
21
|
+
Orbit, attitude, access.
|
22
|
+
|
23
|
+
[](https://github.com/open-space-collective/open-space-toolkit-astrodynamics/actions/workflows/build-test.yml)
|
24
|
+
[](https://codecov.io/gh/open-space-collective/open-space-toolkit-astrodynamics)
|
25
|
+
[](https://open-space-collective.github.io/open-space-toolkit-astrodynamics)
|
26
|
+
[](https://badge.fury.io/gh/open-space-collective%2Fopen-space-toolkit-astrodynamics)
|
27
|
+
[](https://badge.fury.io/py/open-space-toolkit-astrodynamics)
|
28
|
+
[](https://opensource.org/licenses/Apache-2.0)
|
29
|
+
|
30
|
+
[GitHub](https://github.com/open-space-collective/open-space-toolkit-astrodynamics)
|
@@ -0,0 +1,98 @@
|
|
1
|
+
ostk/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
2
|
+
ostk/astrodynamics/OpenSpaceToolkitAstrodynamicsPy.cpython-38-x86_64-linux-gnu.so,sha256=B7BPix-Uqd1MwNC06cv1iCUD9HkoCWEmQu32s_6GR1Q,2176920
|
3
|
+
ostk/astrodynamics/__init__.py,sha256=3gWyqFIbhAfcdeMhmfBPQPlPQTmaOzm-6flkJe745Zk,251
|
4
|
+
ostk/astrodynamics/converters.py,sha256=vsm7SHdlPIyIxW1h5ZGAizl284koGaRmyPCu--AQJfA,4670
|
5
|
+
ostk/astrodynamics/display.py,sha256=KiEGsjNftQfoUe-HfZeYpQQQ4TkaEnxtEl6p5_LX5f0,6303
|
6
|
+
ostk/astrodynamics/libopen-space-toolkit-astrodynamics.so.9,sha256=nKwRhFq_KxwI2BYKDX8ox9RgfzoiQLeTJ5pk97Ep1_o,105977824
|
7
|
+
ostk/astrodynamics/utilities.py,sha256=Jw-AT9CU-a2ERDDSNp7rEhZQKhbmZSCr2flGti9XysU,4813
|
8
|
+
ostk/astrodynamics/viewer.py,sha256=8UxqsvU5wui7gPUwxXaKcIB-509NJiih9Df3mQgXyXY,11776
|
9
|
+
ostk/astrodynamics/pytrajectory/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
10
|
+
ostk/astrodynamics/pytrajectory/pystate.py,sha256=ByOq8szit74xQ-pnLz0uGGxM6Jqfa17dFJyFB8qIXUg,1033
|
11
|
+
ostk/astrodynamics/test/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
12
|
+
ostk/astrodynamics/test/conftest.py,sha256=fsdUQnLxyfvBzfaSCkgipkPIhkPHchQqbeAro1pF648,2717
|
13
|
+
ostk/astrodynamics/test/test_access.py,sha256=MCBsUPtuVm7NgHZR0z0DpWnPZ_qBu4aRhLI2PnRNUYs,3940
|
14
|
+
ostk/astrodynamics/test/test_converters.py,sha256=hnvqOCtUGrzBvjv7GnmaRdl2mlKM3eWuJUspe305B-A,12114
|
15
|
+
ostk/astrodynamics/test/test_display.py,sha256=YnwnqXh-a1OODN2YqHr-l5-q1DrgZ-P4pOY5gxJp4II,3732
|
16
|
+
ostk/astrodynamics/test/test_event_condition.py,sha256=mhMTH7wAoYFWRYt_8l2d1vjNPrFhVjMAEET4INLCVXY,1472
|
17
|
+
ostk/astrodynamics/test/test_import.py,sha256=py_hALBR0IYuUzv9dfgQZzrrLHJIpnyKvt3Oi1XBqCg,1251
|
18
|
+
ostk/astrodynamics/test/test_root_solver.py,sha256=hQ8O6g-WP49gZH_H3Rdufv0F0gQorpzJyIcjBGGUQ34,1831
|
19
|
+
ostk/astrodynamics/test/test_trajectory.py,sha256=WC9X-O_prHeVLIZlmmYzgkskrs5ZwvmOfhz8yth2lgI,1345
|
20
|
+
ostk/astrodynamics/test/test_utilities.py,sha256=kw8quvFTRuoXTbdNdac6IWrjnmA897btNntTMBn-30Q,3614
|
21
|
+
ostk/astrodynamics/test/test_viewer.py,sha256=rbVAiclzBZ1bS4Zdh4xUNJ-STCN4G0O7Gr8suSPJrSc,3986
|
22
|
+
ostk/astrodynamics/test/access/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
23
|
+
ostk/astrodynamics/test/access/test_generator.py,sha256=7l_MJCZIhWIyPpZ-XouBXlSd5-BfqFDGVOMMxjoRIHA,8032
|
24
|
+
ostk/astrodynamics/test/conjunction/message/ccsds/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
25
|
+
ostk/astrodynamics/test/conjunction/message/ccsds/conftest.py,sha256=xyTd24828Ue2HgOWY8UhizIc5mzgRgoH2VSOfVfKCdw,14632
|
26
|
+
ostk/astrodynamics/test/conjunction/message/ccsds/test_cdm.py,sha256=ztpnOHI3ZiIV0QwijJ6Si_lIna8jLZF45r1KtPVK4ws,18514
|
27
|
+
ostk/astrodynamics/test/conjunction/message/ccsds/data/cdm.json,sha256=-CL8Bu-ivigzkrqHs9Q5snSubHJ_D0YMroatEInkidc,12965
|
28
|
+
ostk/astrodynamics/test/dynamics/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
29
|
+
ostk/astrodynamics/test/dynamics/test_atmospheric_drag.py,sha256=PryQJcYTi3EWjTDHPZ12-c6wVMzlgjaMdYxboWLgLJc,3737
|
30
|
+
ostk/astrodynamics/test/dynamics/test_central_body_gravity.py,sha256=B8HvZz_ppsmeGijfMJArJbkLP9fSPciGtScuVT9AM_g,1782
|
31
|
+
ostk/astrodynamics/test/dynamics/test_dynamics.py,sha256=KUyn8qwvzYkEHmhJV8AJXqK1MUnsXQXztSNr2GYZR4Q,1237
|
32
|
+
ostk/astrodynamics/test/dynamics/test_position_derivative.py,sha256=JRuq-oRrJfisbN75OnE-ldm6TeYcIc0qYaGVMflbn2g,1610
|
33
|
+
ostk/astrodynamics/test/dynamics/test_tabulated.py,sha256=qFHA7nmcvJtWucpCOYHAFmNRtImhTGlAZ0CHGEadeX8,4029
|
34
|
+
ostk/astrodynamics/test/dynamics/test_third_body_gravity.py,sha256=7xBOKbVio-zZ2-QQaje152cP38n_ALAaR5x6QIdBmXE,1879
|
35
|
+
ostk/astrodynamics/test/dynamics/test_thruster.py,sha256=cCJtKWuNcRHmcreCv7BajwuJnHCat9m88OHh_o0cB7w,4383
|
36
|
+
ostk/astrodynamics/test/dynamics/data/Tabulated_Earth_Gravity.csv,sha256=jJWOMJcQ83Vy1Wrb9PTh3ffOdoDF98kk6w5b-_E0uWg,47419
|
37
|
+
ostk/astrodynamics/test/dynamics/data/Tabulated_Earth_Gravity_Truth.csv,sha256=f4x-zmxZADxD_doAbACt24k36VSTp3rSIJiSzuSroKs,8377
|
38
|
+
ostk/astrodynamics/test/event_condition/test_angular_condition.py,sha256=MDRwjU5zXIRBaIFZA3jG3hcnyIIFo_0QyBRtNIfH2aQ,3119
|
39
|
+
ostk/astrodynamics/test/event_condition/test_boolean_condition.py,sha256=Ng6FLKD8XoUHUz6-gi3wvrYhSGNSB_iJ_n89ajN4O3s,1580
|
40
|
+
ostk/astrodynamics/test/event_condition/test_coe_condition.py,sha256=AM0olK1s4jDRs_dJs0sk9raY9Nm1eZpdEEso6wyvipk,2580
|
41
|
+
ostk/astrodynamics/test/event_condition/test_instant_condition.py,sha256=Qr5dN6nrK7XDff7L4vnGCqasMK-Fa6qvxwy_U0xgH5M,1438
|
42
|
+
ostk/astrodynamics/test/event_condition/test_logical_condition.py,sha256=09h5TYWtwGt4NQW3k_tziiVs0Q2981rNII9wyKg7p2Q,3321
|
43
|
+
ostk/astrodynamics/test/event_condition/test_real_condition.py,sha256=tle6HVzMFMIIkfRY7CuaA0mPtw3riJBG_JQkc1L0dpk,1374
|
44
|
+
ostk/astrodynamics/test/flight/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
45
|
+
ostk/astrodynamics/test/flight/test_maneuver.py,sha256=6LhnNhaiwId-IveUraHnhx8dYxeOgzntP_WPtv9GFjQ,6197
|
46
|
+
ostk/astrodynamics/test/flight/test_profile.py,sha256=RULN-34ERmlZjgNQe6Kj797dklJBKAm-QYUIqitxvwA,5185
|
47
|
+
ostk/astrodynamics/test/flight/test_system.py,sha256=MVaE7lJYisH4vmJPD-G-Hw4wNj-Xe8yMksgu8IXCLvg,1322
|
48
|
+
ostk/astrodynamics/test/flight/system/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
49
|
+
ostk/astrodynamics/test/flight/system/test_propulsion_system.py,sha256=jLUC74YjIQz7APr-kQcdYRYiKm8lfequjosptG29kmI,1964
|
50
|
+
ostk/astrodynamics/test/flight/system/test_satellite_system.py,sha256=_9r_IgsGGPFTbpJ-6NQ3JU_T8Ac7-WUg-MaEsl6iUqU,2526
|
51
|
+
ostk/astrodynamics/test/flight/system/test_satellite_system_builder.py,sha256=QCk70dPcptvdpWQOxtYR0-iGnlbtOIx2V6oO0UhYIQ0,2426
|
52
|
+
ostk/astrodynamics/test/guidance_law/test_constant_thrust.py,sha256=YpMkMvat4YnE1Fyy5vZ1Sf3VvbvDaC_UvbIKNNCG_B4,2635
|
53
|
+
ostk/astrodynamics/test/guidance_law/test_qlaw.py,sha256=kZaBZeU_J8Qk2nFnnpSuu-2NXT_13g3vLamG--eZfeU,3634
|
54
|
+
ostk/astrodynamics/test/solvers/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
55
|
+
ostk/astrodynamics/test/solvers/test_finite_difference_solver.py,sha256=49hS9EF7YXQH4spzyLA_NftZYmNFb7y1pxiza0oxcLw,5408
|
56
|
+
ostk/astrodynamics/test/solvers/test_temporal_condition_solver.py,sha256=ukDuIiEbBBvfqbHfiMIsPk5eyeRsWywCvNT1A3YnmIQ,4862
|
57
|
+
ostk/astrodynamics/test/trajectory/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
58
|
+
ostk/astrodynamics/test/trajectory/test_local_orbital_frame_direction.py,sha256=d72J50UGG9m0Atei0UQ8sITU1WdJmws5xgUiacLZMbw,2515
|
59
|
+
ostk/astrodynamics/test/trajectory/test_local_orbital_frame_factory.py,sha256=33SuZgkXEgYwXhFftRBaSr9Vv60DDJBi5MiXD5H-n6A,2173
|
60
|
+
ostk/astrodynamics/test/trajectory/test_model.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
61
|
+
ostk/astrodynamics/test/trajectory/test_orbit.py,sha256=s002kf16REvXyWkyDHI9BnEjxjiavQl2B0ceu0CuJ2s,5671
|
62
|
+
ostk/astrodynamics/test/trajectory/test_propagator.py,sha256=dG31S5FY0NjJ5bnisqJ_HdL7amj_AZAWWLiOmdHfJAc,14233
|
63
|
+
ostk/astrodynamics/test/trajectory/test_segment.py,sha256=ACVMYvjlTyCQHZ2-hFEurK08-LQxt6VlcGTMOrgDHaE,9333
|
64
|
+
ostk/astrodynamics/test/trajectory/test_sequence.py,sha256=gswWqEBTYvbi5TQjF0DNPkAj5COo9Nb9IK7TdwJ_5C0,12882
|
65
|
+
ostk/astrodynamics/test/trajectory/test_state.py,sha256=PZUpGZKMFRDIyDAfKvSMmmOkiFqkquMz8Hgn_nK_SvI,6878
|
66
|
+
ostk/astrodynamics/test/trajectory/test_state_builder.py,sha256=PSlXtmGURCrlf0w50tn3dEBRo6p0x4NmIF9gJsNOR3k,4782
|
67
|
+
ostk/astrodynamics/test/trajectory/orbit/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
68
|
+
ostk/astrodynamics/test/trajectory/orbit/test_model.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
69
|
+
ostk/astrodynamics/test/trajectory/orbit/test_pass.py,sha256=LYo0II9117pW7EszCTg5UupqfOJu0NnvejKTPkn2hqU,2397
|
70
|
+
ostk/astrodynamics/test/trajectory/orbit/message/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
71
|
+
ostk/astrodynamics/test/trajectory/orbit/message/spacex/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
72
|
+
ostk/astrodynamics/test/trajectory/orbit/message/spacex/conftest.py,sha256=O75ywkPJjoFp0uKptCu4C2tGMRaGN-8NVFVhps85eWE,379
|
73
|
+
ostk/astrodynamics/test/trajectory/orbit/message/spacex/test_opm.py,sha256=Z9jdjYXAexn3VpnYpUX78akjcK_3U6DXzm6YPouEZww,3889
|
74
|
+
ostk/astrodynamics/test/trajectory/orbit/message/spacex/data/opm_1.yaml,sha256=DqIdfLCPD9oV4qDvgq35fIT8Gb8zgtrHr5Nx53InSQM,1363
|
75
|
+
ostk/astrodynamics/test/trajectory/orbit/models/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
76
|
+
ostk/astrodynamics/test/trajectory/orbit/models/test_kepler.py,sha256=zgMf98cFi2lBIFGQxxskTjxsmOqxy8LPvARLTUM9YX0,3366
|
77
|
+
ostk/astrodynamics/test/trajectory/orbit/models/test_propagated.py,sha256=j_DEg2wwqYVqqzCai0IpmJu8L00ZZfhYcDYFx80Oa24,7140
|
78
|
+
ostk/astrodynamics/test/trajectory/orbit/models/test_sgp4.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
79
|
+
ostk/astrodynamics/test/trajectory/orbit/models/test_tabulated.py,sha256=kNSHwdz-IiTU4ThtmovGvEYs8QyH9i3uPQFz3L6OHxw,11025
|
80
|
+
ostk/astrodynamics/test/trajectory/orbit/models/kepler/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
81
|
+
ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_brouwer_lyddane_mean.py,sha256=NvtwHJzZvfp8LZGcRhWU1kJ_rdLCim8GBXUbzMrPjjc,1542
|
82
|
+
ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_brouwer_lyddane_mean_long.py,sha256=c-8M4py0LEDHoRuc-ukmUyGYN7PcSDWFKY2Bh1KFNRk,2468
|
83
|
+
ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_brouwer_lyddane_mean_short.py,sha256=rLA6Ud41SFZSWZiOzGFU1FBPlzv6-c6eP8Ly-bqsFKo,2485
|
84
|
+
ostk/astrodynamics/test/trajectory/orbit/models/kepler/test_coe.py,sha256=H42bc4SkXl7tvEMDwAdPImiJpFPBRjSD_Npsmxq4xaY,4778
|
85
|
+
ostk/astrodynamics/test/trajectory/orbit/models/sgp4/__init__.py,sha256=epnVn2PwdQkUDZ1msqBRO5nEZIOUBIq-IfK3IlNPijE,21
|
86
|
+
ostk/astrodynamics/test/trajectory/orbit/models/sgp4/test_tle.py,sha256=jkyRr5NJQMaSpI3ey7cKcH0E-BlalaUlf_mZPYTSow8,11482
|
87
|
+
ostk/astrodynamics/test/trajectory/state/test_coordinate_broker.py,sha256=ho5FBfB3IvIjfQl7EYoIN1KBuH9lu76IiNMuweq8cqg,2844
|
88
|
+
ostk/astrodynamics/test/trajectory/state/test_coordinate_subset.py,sha256=KjltLEPbxMfyebwjG5mulyGCT5INtiItPq6ID6sP9jI,1289
|
89
|
+
ostk/astrodynamics/test/trajectory/state/test_numerical_solver.py,sha256=_t4OKnYLzTjOhSkVTgT2307DQkz_DnGxqqLx8mmzLRA,9389
|
90
|
+
ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_angular_velocity.py,sha256=xjyGREKpxDuT8gjtBPkV4osfW-6UyWv9hgvBXZVb_wk,625
|
91
|
+
ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_attitude_quaternion.py,sha256=UEu9ApzQLmT87eeISw6_gcHTlX-4b2scIvHz-uE1p_c,393
|
92
|
+
ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_cartesian_position.py,sha256=XvHdk1KjacTwtkgx2jUAc9I9N3nvjPDv03FAanpv8jQ,2702
|
93
|
+
ostk/astrodynamics/test/trajectory/state/coordinate_subset/test_cartesian_velocity.py,sha256=-kd5TZO5TICihbkqDTew2i_tDpggdpe3Yf23046FATM,3057
|
94
|
+
open_space_toolkit_astrodynamics-9.4.1.dist-info/METADATA,sha256=ENRF4_67BvymxRZBFCr0WXhX4e2buEhpkVsU9w4UBm8,1915
|
95
|
+
open_space_toolkit_astrodynamics-9.4.1.dist-info/WHEEL,sha256=UAGnXGE6TUJ5_odNW3WnEDi604O0AtVRrnlTu7KBuB4,110
|
96
|
+
open_space_toolkit_astrodynamics-9.4.1.dist-info/top_level.txt,sha256=zOR18699uDYnafgarhL8WU_LmTZY_5NVqutv-flp_x4,5
|
97
|
+
open_space_toolkit_astrodynamics-9.4.1.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
98
|
+
open_space_toolkit_astrodynamics-9.4.1.dist-info/RECORD,,
|
@@ -0,0 +1 @@
|
|
1
|
+
ostk
|
@@ -0,0 +1 @@
|
|
1
|
+
|
ostk/__init__.py
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
# Apache License 2.0
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# Apache License 2.0
|
2
|
+
|
3
|
+
from ostk.physics import *
|
4
|
+
|
5
|
+
from .OpenSpaceToolkitAstrodynamicsPy import *
|
6
|
+
|
7
|
+
from .pytrajectory.pystate import State as PyState
|
8
|
+
|
9
|
+
trajectory.State = (
|
10
|
+
PyState # Override the pure c++ State class with the modified Python one
|
11
|
+
)
|
@@ -0,0 +1,185 @@
|
|
1
|
+
# Apache License 2.0
|
2
|
+
|
3
|
+
from datetime import datetime, timedelta, timezone
|
4
|
+
|
5
|
+
import numpy as np
|
6
|
+
|
7
|
+
from ostk.mathematics.geometry.d3.transformation.rotation import Quaternion
|
8
|
+
|
9
|
+
from ostk.physics.time import Instant
|
10
|
+
from ostk.physics.time import Interval
|
11
|
+
from ostk.physics.time import Duration
|
12
|
+
from ostk.physics.time import Scale
|
13
|
+
from ostk.physics.coordinate import Position
|
14
|
+
from ostk.physics.coordinate import Velocity
|
15
|
+
from ostk.physics.coordinate import Frame
|
16
|
+
|
17
|
+
|
18
|
+
def coerce_to_datetime(value: Instant | datetime | str) -> datetime:
|
19
|
+
"""
|
20
|
+
Return datetime from value.
|
21
|
+
|
22
|
+
Args:
|
23
|
+
value (Instant | datetime | str): A value to coerce.
|
24
|
+
|
25
|
+
Returns:
|
26
|
+
datetime: The coerced datetime.
|
27
|
+
"""
|
28
|
+
|
29
|
+
if isinstance(value, datetime):
|
30
|
+
return value
|
31
|
+
|
32
|
+
if isinstance(value, Instant):
|
33
|
+
return value.get_date_time(Scale.UTC).replace(tzinfo=timezone.utc)
|
34
|
+
|
35
|
+
if isinstance(value, str):
|
36
|
+
return datetime.fromisoformat(value)
|
37
|
+
|
38
|
+
raise TypeError("Argument must be a datetime, an Instant, or a str.")
|
39
|
+
|
40
|
+
|
41
|
+
def coerce_to_instant(value: Instant | datetime | str) -> Instant:
|
42
|
+
"""
|
43
|
+
Return Instant from value.
|
44
|
+
|
45
|
+
Args:
|
46
|
+
value (Instant | datetime | str): A value to coerce.
|
47
|
+
|
48
|
+
Returns:
|
49
|
+
Instant: The coerced Instant.
|
50
|
+
"""
|
51
|
+
|
52
|
+
if isinstance(value, Instant):
|
53
|
+
return value
|
54
|
+
|
55
|
+
if isinstance(value, datetime):
|
56
|
+
return Instant.date_time(value.astimezone(tz=timezone.utc), Scale.UTC)
|
57
|
+
|
58
|
+
if isinstance(value, str):
|
59
|
+
return coerce_to_instant(coerce_to_datetime(value))
|
60
|
+
|
61
|
+
raise TypeError("Argument must be a datetime, an Instant, or a str.")
|
62
|
+
|
63
|
+
|
64
|
+
def coerce_to_iso(value: Instant | datetime | str, timespec: str = "microseconds") -> str:
|
65
|
+
"""
|
66
|
+
Return an ISO string from value.
|
67
|
+
|
68
|
+
Args:
|
69
|
+
value (Instant | datetime | str): A value to coerce.
|
70
|
+
timespec (str): A time resolution. Defaults to "microseconds".
|
71
|
+
|
72
|
+
Returns:
|
73
|
+
str: The coerced ISO string.
|
74
|
+
"""
|
75
|
+
|
76
|
+
if isinstance(value, str):
|
77
|
+
return coerce_to_iso(coerce_to_datetime(value), timespec=timespec)
|
78
|
+
|
79
|
+
if isinstance(value, datetime):
|
80
|
+
return value.isoformat(timespec=timespec)
|
81
|
+
|
82
|
+
if isinstance(value, Instant):
|
83
|
+
return coerce_to_iso(coerce_to_datetime(value), timespec=timespec)
|
84
|
+
|
85
|
+
raise TypeError("Argument must be a datetime, an Instant, or a str.")
|
86
|
+
|
87
|
+
|
88
|
+
def coerce_to_interval(
|
89
|
+
value: Interval | tuple[Instant, Instant] | tuple[datetime, datetime],
|
90
|
+
) -> Interval:
|
91
|
+
"""
|
92
|
+
Return Interval from value.
|
93
|
+
|
94
|
+
Args:
|
95
|
+
value (Interval | tuple[Instant, Instant] | tuple[datetime, datetime]): A value to coerce.
|
96
|
+
|
97
|
+
Returns:
|
98
|
+
Interval: The coerced Interval.
|
99
|
+
"""
|
100
|
+
|
101
|
+
if isinstance(value, Interval):
|
102
|
+
return value
|
103
|
+
|
104
|
+
return Interval.closed(
|
105
|
+
start_instant=coerce_to_instant(value[0]),
|
106
|
+
end_instant=coerce_to_instant(value[1]),
|
107
|
+
)
|
108
|
+
|
109
|
+
|
110
|
+
def coerce_to_duration(value: Duration | timedelta) -> Duration:
|
111
|
+
"""
|
112
|
+
Return Duration from value.
|
113
|
+
|
114
|
+
Args:
|
115
|
+
value (Duration | datetime): A value to coerce.
|
116
|
+
|
117
|
+
Returns:
|
118
|
+
Duration: The coerced Duration.
|
119
|
+
"""
|
120
|
+
|
121
|
+
if isinstance(value, Duration):
|
122
|
+
return value
|
123
|
+
|
124
|
+
return Duration.seconds(value.total_seconds())
|
125
|
+
|
126
|
+
|
127
|
+
def coerce_to_position(
|
128
|
+
value: Position | tuple[float, float, float] | list[float] | np.ndarray,
|
129
|
+
frame: Frame,
|
130
|
+
) -> Position:
|
131
|
+
"""
|
132
|
+
Return Position from value.
|
133
|
+
|
134
|
+
Args:
|
135
|
+
value (Position | tuple[float, float, float] | list[float] | np.ndarray): A value to coerce.
|
136
|
+
frame (Frame): A reference frame.
|
137
|
+
|
138
|
+
Returns:
|
139
|
+
Position: The coerced Position.
|
140
|
+
"""
|
141
|
+
|
142
|
+
if isinstance(value, Position):
|
143
|
+
return value
|
144
|
+
|
145
|
+
return Position.meters(value, frame)
|
146
|
+
|
147
|
+
|
148
|
+
def coerce_to_velocity(
|
149
|
+
value: Velocity | tuple[float, float, float] | list[float] | np.ndarray,
|
150
|
+
frame: Frame,
|
151
|
+
) -> Velocity:
|
152
|
+
"""
|
153
|
+
Return Velocity from value.
|
154
|
+
|
155
|
+
Args:
|
156
|
+
value (Velocity | tuple[float, float, float] | list[float] | np.ndarray): A value to coerce.
|
157
|
+
frame (Frame): A reference frame.
|
158
|
+
|
159
|
+
Returns:
|
160
|
+
Velocity: The coerced Velocity.
|
161
|
+
"""
|
162
|
+
|
163
|
+
if isinstance(value, Velocity):
|
164
|
+
return value
|
165
|
+
|
166
|
+
return Velocity.meters_per_second(value, frame)
|
167
|
+
|
168
|
+
|
169
|
+
def coerce_to_quaternion(
|
170
|
+
value: Quaternion | tuple[float, float, float, float] | list[float] | np.ndarray
|
171
|
+
) -> Quaternion:
|
172
|
+
"""
|
173
|
+
Return quaternion from value.
|
174
|
+
|
175
|
+
Args:
|
176
|
+
value (Quaternion | tuple[float, float, float, float] | list[float] | np.ndarray): A value to coerce.
|
177
|
+
|
178
|
+
Returns:
|
179
|
+
Quaternion: The coerced Quaternion.
|
180
|
+
"""
|
181
|
+
|
182
|
+
if isinstance(value, Quaternion):
|
183
|
+
return value
|
184
|
+
|
185
|
+
return Quaternion(vector=value, format=Quaternion.Format.XYZS)
|
@@ -0,0 +1,220 @@
|
|
1
|
+
# Apache License 2.0
|
2
|
+
|
3
|
+
from typing import Any
|
4
|
+
|
5
|
+
import pandas as pd
|
6
|
+
|
7
|
+
import plotly.graph_objs as go
|
8
|
+
|
9
|
+
from ostk.mathematics.object import RealInterval
|
10
|
+
|
11
|
+
from ostk.physics.coordinate import Position
|
12
|
+
from ostk.physics.coordinate import Frame
|
13
|
+
from ostk.physics.coordinate.spherical import LLA
|
14
|
+
from ostk.physics.environment.object import Celestial
|
15
|
+
from ostk.physics.time import Duration
|
16
|
+
from ostk.physics.time import Instant
|
17
|
+
from ostk.physics.unit import Length
|
18
|
+
|
19
|
+
from ostk.astrodynamics import Access
|
20
|
+
from ostk.astrodynamics import Trajectory
|
21
|
+
|
22
|
+
|
23
|
+
DEFAULT_COLOR: str = "rgba(255, 0, 0, 0.5)"
|
24
|
+
|
25
|
+
DEFAULT_LAYOUT_2D: go.Layout = go.Layout(
|
26
|
+
title=None,
|
27
|
+
showlegend=False,
|
28
|
+
height=1000,
|
29
|
+
geo=go.layout.Geo(
|
30
|
+
showland=True,
|
31
|
+
landcolor="rgb(243, 243, 243)",
|
32
|
+
countrycolor="rgb(204, 204, 204)",
|
33
|
+
lonaxis=dict(
|
34
|
+
showgrid=True,
|
35
|
+
gridcolor="rgb(102, 102, 102)",
|
36
|
+
gridwidth=0.1,
|
37
|
+
),
|
38
|
+
lataxis=dict(
|
39
|
+
showgrid=True,
|
40
|
+
gridcolor="rgb(102, 102, 102)",
|
41
|
+
gridwidth=0.1,
|
42
|
+
),
|
43
|
+
),
|
44
|
+
)
|
45
|
+
|
46
|
+
DEFAULT_LAYOUT_3D: go.Layout = go.Layout(
|
47
|
+
title=None,
|
48
|
+
showlegend=False,
|
49
|
+
height=1000,
|
50
|
+
geo=go.layout.Geo(
|
51
|
+
showland=True,
|
52
|
+
showlakes=True,
|
53
|
+
showcountries=False,
|
54
|
+
showocean=True,
|
55
|
+
countrywidth=0.0,
|
56
|
+
landcolor="rgb(100, 100, 100)",
|
57
|
+
lakecolor="rgb(240, 240, 240)",
|
58
|
+
oceancolor="rgb(240, 240, 240)",
|
59
|
+
projection=dict(
|
60
|
+
type="orthographic",
|
61
|
+
rotation=dict(
|
62
|
+
lon=0,
|
63
|
+
lat=0,
|
64
|
+
roll=0,
|
65
|
+
),
|
66
|
+
),
|
67
|
+
lonaxis=dict(
|
68
|
+
showgrid=True,
|
69
|
+
gridcolor="rgb(102, 102, 102)",
|
70
|
+
gridwidth=0.5,
|
71
|
+
),
|
72
|
+
lataxis=dict(
|
73
|
+
showgrid=True,
|
74
|
+
gridcolor="rgb(102, 102, 102)",
|
75
|
+
gridwidth=0.5,
|
76
|
+
),
|
77
|
+
),
|
78
|
+
)
|
79
|
+
|
80
|
+
|
81
|
+
def convert_to_ground_track_plotting_data(
|
82
|
+
longitude: list, latitude: list, color: str = DEFAULT_COLOR
|
83
|
+
) -> go.Scattergeo:
|
84
|
+
return go.Scattergeo(
|
85
|
+
lon=longitude,
|
86
|
+
lat=latitude,
|
87
|
+
mode="lines",
|
88
|
+
line=dict(
|
89
|
+
width=1,
|
90
|
+
color=color,
|
91
|
+
),
|
92
|
+
)
|
93
|
+
|
94
|
+
|
95
|
+
def create_plotly_figure(data: Any, layout: go.Layout) -> go.Figure:
|
96
|
+
return go.Figure(
|
97
|
+
data=data,
|
98
|
+
layout=layout,
|
99
|
+
)
|
100
|
+
|
101
|
+
|
102
|
+
def create_2d_map(data: Any) -> go.Figure:
|
103
|
+
return create_plotly_figure(data, DEFAULT_LAYOUT_2D)
|
104
|
+
|
105
|
+
|
106
|
+
def create_3d_globe(data: Any) -> go.Figure:
|
107
|
+
return create_plotly_figure(data, DEFAULT_LAYOUT_3D)
|
108
|
+
|
109
|
+
|
110
|
+
class AccessesPlot:
|
111
|
+
"""
|
112
|
+
Accesses plot. Display a 2D world map, with 1 ground station and
|
113
|
+
multiple satellites, highlighting the accesses.
|
114
|
+
"""
|
115
|
+
|
116
|
+
def __init__(
|
117
|
+
self,
|
118
|
+
earth: Celestial,
|
119
|
+
interval: RealInterval,
|
120
|
+
trajectory_step: Duration,
|
121
|
+
access_step: Duration,
|
122
|
+
ground_station_lla: LLA,
|
123
|
+
color: str,
|
124
|
+
):
|
125
|
+
self._earth = earth
|
126
|
+
self._trajectory_grid: list[Instant] = interval.generate_grid(trajectory_step)
|
127
|
+
self._access_step: Instant = access_step
|
128
|
+
self._ned_frame: Frame = self._earth.get_frame_at(
|
129
|
+
ground_station_lla, self._earth.FrameType.NED
|
130
|
+
)
|
131
|
+
self._ground_station_position_ned: Position = Position(
|
132
|
+
[0.0, 0.0, 0.0],
|
133
|
+
Length.Unit.Meter,
|
134
|
+
self._ned_frame,
|
135
|
+
)
|
136
|
+
self._data = []
|
137
|
+
self._data.append(
|
138
|
+
dict(
|
139
|
+
type="scattergeo",
|
140
|
+
lon=[float(ground_station_lla.get_longitude().in_degrees())],
|
141
|
+
lat=[float(ground_station_lla.get_latitude().in_degrees())],
|
142
|
+
mode="markers",
|
143
|
+
marker=dict(
|
144
|
+
size=10,
|
145
|
+
color=color,
|
146
|
+
),
|
147
|
+
)
|
148
|
+
)
|
149
|
+
|
150
|
+
def _generate_and_append_data(
|
151
|
+
self, data: list[list[float]], trajectory: Trajectory, grid: list[Instant]
|
152
|
+
) -> None:
|
153
|
+
for state in trajectory.get_states_at(grid):
|
154
|
+
lla: LLA = LLA.cartesian(
|
155
|
+
state.get_position()
|
156
|
+
.in_frame(Frame.ITRF(), state.get_instant())
|
157
|
+
.get_coordinates(),
|
158
|
+
self._earth.get_equatorial_radius(),
|
159
|
+
self._earth.get_flattening(),
|
160
|
+
)
|
161
|
+
data.append(
|
162
|
+
[
|
163
|
+
float(lla.get_longitude().in_degrees()),
|
164
|
+
float(lla.get_latitude().in_degrees()),
|
165
|
+
]
|
166
|
+
)
|
167
|
+
|
168
|
+
def _append_line(
|
169
|
+
self, df: pd.DataFrame, width: int, rgb: list[int], alpha: float
|
170
|
+
) -> None:
|
171
|
+
self._data.append(
|
172
|
+
dict(
|
173
|
+
type="scattergeo",
|
174
|
+
lon=df["Longitude"],
|
175
|
+
lat=df["Latitude"],
|
176
|
+
mode="lines",
|
177
|
+
line=dict(
|
178
|
+
width=width,
|
179
|
+
color=f"rgba({str(rgb[0])},{str(rgb[1])},{str(rgb[2])},{str(alpha)})",
|
180
|
+
),
|
181
|
+
)
|
182
|
+
)
|
183
|
+
|
184
|
+
def add_satellite(
|
185
|
+
self, trajectory: Trajectory, accesses: list[Access], rgb: list[int]
|
186
|
+
) -> None:
|
187
|
+
"""
|
188
|
+
Add a satellite trajectory to the plot, including a highligh ot the interference
|
189
|
+
accesses.
|
190
|
+
"""
|
191
|
+
|
192
|
+
# Satellite trajectory
|
193
|
+
satellite_trajectory_data: list[list[float]] = []
|
194
|
+
self._generate_and_append_data(
|
195
|
+
satellite_trajectory_data, trajectory, self._trajectory_grid
|
196
|
+
)
|
197
|
+
satellite_trajectory_df: pd.Dataframe = pd.DataFrame(
|
198
|
+
satellite_trajectory_data, columns=["Longitude", "Latitude"]
|
199
|
+
)
|
200
|
+
self._append_line(satellite_trajectory_df, 1, rgb, 0.1)
|
201
|
+
|
202
|
+
# Satellite accesses
|
203
|
+
for access in accesses:
|
204
|
+
satellite_access_data: list[list[float]] = []
|
205
|
+
self._generate_and_append_data(
|
206
|
+
satellite_access_data,
|
207
|
+
trajectory,
|
208
|
+
access.get_interval().generate_grid(self._access_step),
|
209
|
+
)
|
210
|
+
satellite_access_df: pd.Dataframe = pd.DataFrame(
|
211
|
+
satellite_access_data, columns=["Longitude", "Latitude"]
|
212
|
+
)
|
213
|
+
self._append_line(satellite_access_df, 2, rgb, 1.0)
|
214
|
+
|
215
|
+
def show(self):
|
216
|
+
"""
|
217
|
+
Display the figure.
|
218
|
+
"""
|
219
|
+
figure = create_2d_map(data=self._data)
|
220
|
+
figure.show()
|
Binary file
|
@@ -0,0 +1 @@
|
|
1
|
+
# Apache License 2.0
|
@@ -0,0 +1,36 @@
|
|
1
|
+
# Apache License 2.0
|
2
|
+
|
3
|
+
|
4
|
+
# Python-only State functionality
|
5
|
+
import numpy as np
|
6
|
+
|
7
|
+
from ostk.physics.coordinate import Frame
|
8
|
+
from ostk.physics.time import Instant
|
9
|
+
|
10
|
+
from ostk.astrodynamics.trajectory import State, StateBuilder
|
11
|
+
|
12
|
+
|
13
|
+
@staticmethod
|
14
|
+
def custom_class_generator(frame: Frame, coordinate_subsets: list) -> type:
|
15
|
+
"""
|
16
|
+
Emit a custom class type for States. This is meta-programming syntactic sugar on top of the StateBuilder class.
|
17
|
+
|
18
|
+
StateType = State.template(frame, coordinate_subsets)
|
19
|
+
state = StateType(instant, coordinates)
|
20
|
+
|
21
|
+
is equivalent to
|
22
|
+
|
23
|
+
state_builder = StateBuilder(frame, coordinate_subsets)
|
24
|
+
state = state_builder.build(instant, coordinates)
|
25
|
+
"""
|
26
|
+
|
27
|
+
class StateTemplateType(State):
|
28
|
+
state_builder: StateBuilder = StateBuilder(frame, coordinate_subsets)
|
29
|
+
|
30
|
+
def __init__(self, instant: Instant, coordinates: np.ndarray):
|
31
|
+
super().__init__(StateTemplateType.state_builder.build(instant, coordinates))
|
32
|
+
|
33
|
+
return StateTemplateType
|
34
|
+
|
35
|
+
|
36
|
+
State.template = custom_class_generator
|
@@ -0,0 +1 @@
|
|
1
|
+
# Apache License 2.0
|
@@ -0,0 +1 @@
|
|
1
|
+
# Apache License 2.0
|