<jupyter_start><jupyter_text>Preliminaries1. `pip install jplephem`2. `pip install sgp4`3. Put [**de430.bsp**](https://naif.jpl.nasa.gov/pub/naif/generic_kernels/spk/planets/de430.bsp) ephemeris into `Spacecraft_Testbed/Information/Celestial_Bodies/Ephemerides`.<jupyter_code># Import the Celestial Body class
from Spacecraft_Testbed.Body import Celestial_Body
# Importy NumPy tools for math stuff
from numpy import linspace
# Instantiate Earth and Jupiter
Earth = Celestial_Body('Earth')
Jupiter = Celestial_Body('Jupiter')
# Define Julian date of interest (March 20)
March20  = 2457832.5 # Initial time
# Calculate position and velocity of Earth
# with respect to the solar system barycentre

# On March 20
p, v = Earth.Position_and_Velocity(March20)
print "Position: " + str(p)
print "Velocity: " + str(v)
# Examine the Chinese weather satellite Fengyun 1C debris fragements
frag1 = Earth.Satellites.Fengyun_1C.Fengyun_1C_Deb_102
frag2 = Earth.Satellites.Fengyun_1C.Fengyun_1C_Deb_105
# Examine the Iridium debris fragement 4
frag3 = Earth.Satellites.Iridium_33.Iridium_33_Deb_4
# and Breeze debris fragement 1
frag4 = Earth.Satellites.Cosmos_2251.Cosmos_2251_Deb_1
# These positions and velocities can be shown as well
print frag1.Position_and_Velocity(March20) # WRT SS barycentre
# WRT other planets and fragements (all derrived from the body class)
print frag3.Position_and_Velocity_WRT(Earth, March20) # WRT Earth
# WRT another fragement
print frag4.Position_and_Velocity_WRT(frag1, March20)
# WRT Jupiter
print frag2.Position_and_Velocity_WRT(Jupiter, March20)
# Earth WRT Mars
print Earth.Position_and_Velocity_WRT(Celestial_Body('Mars'), March20)<jupyter_output>[[ -2.57966193e+11  -1.77399718e+11  -7.84660765e+10]
 [  1.94062670e+04  -3.98292685e+04  -1.81245049e+04]]
{'fraction_non_alphanumeric': 0.08815272318921955, 'fraction_numerical': 0.07748455923638406, 'mean_word_length': 6.273469387755102, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '605623', 'license': 'MIT', 'n_tokens_mistral': 757, 'n_tokens_neox': 654, 'n_words': 156, 'path': 'Tutorial.ipynb', 'repo_name': 'cisprague/Spacecraft_Testbed', 'size': '1781'}