Last active
July 10, 2019 21:45
-
-
Save jorgepiloto/8fe297f8e10f5394c789ff2e9bbefcc6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
from astropy import units as u | |
from astropy.time import Time | |
from poliastro.bodies import Earth | |
from poliastro.frames import GeocentricSolarEcliptic | |
from poliastro.plotting.static import StaticOrbitPlotter | |
from poliastro.twobody import Orbit | |
EPOCH = Time("2018-02-19") | |
ss_2018cb = Orbit.from_sbdb("2018cb").propagate(EPOCH) | |
ss_earth = Orbit.from_body_ephem(Earth, epoch=EPOCH) | |
plotter = StaticOrbitPlotter() | |
plotter.set_frame(GeocentricSolarEcliptic(obstime=EPOCH)) | |
plotter.plot(ss_2018cb, label="2018cb", color="green") | |
plotter.plot(ss_earth, label="Earth", color="navy") | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment