layup.dash_ui
Attributes
Functions
|
Add the reference plane (either ecliptic or equatorial) to the 3D plot at Z=0 |
|
Rough first pass orbit classifier based on input orbital elements. Does NOT do any |
|
Create a 2D (1x2 subplot) interactive Plotly figure of orbits |
|
Create a 3D interactive Plotly figure of orbits |
|
Create and |
Module Contents
- add_reference_plane_xy(fig, lines: numpy.ndarray, planet_lines: numpy.ndarray, opacity: float = 0.1)[source]
Add the reference plane (either ecliptic or equatorial) to the 3D plot at Z=0
- Parameters:
fig (object) – Plotly figure object
lines (numpy float array) – Array of x,y,z coordinates of objects to be plotted
lines – Array of x,y,z coordinates of planets to be plotted
opacity (float, optional (default = 0.10)) – Transparency of the reference plane
- classify(a: float, e: float, Tj: float) str[source]
Rough first pass orbit classifier based on input orbital elements. Does NOT do any orbit integrations to verify e.g. Trojan or other resonant behaviour, so use only as an approximate guess. Check your orbits thoroughly.
- Parameters:
a (float) – Semimajor axis of the object, in units of AU
e (float) – Eccentricity of the object
Tj (float) – Tisserand parameter with respect to Jupiter of the object
- plotly_2D(lines: numpy.ndarray, canon: layup.orbit_maths.ClassicalConic, plot_sun: bool = True, sun_xyz: numpy.ndarray | None = None, planet_lines: numpy.ndarray | None = None, planet_id: numpy.ndarray | None = None, return_fig: bool = False, output: str | None = None, panel: PANEL | None = None, panels: Tuple[PANEL, PANEL] | None = None, special_lines: numpy.ndarray | None = None, special_canon: layup.orbit_maths.ClassicalConic | None = None)[source]
Create a 2D (1x2 subplot) interactive Plotly figure of orbits
- Parameters:
lines (dict of numpy array) – Dictionary of arrays with the orbit lines for each object in each plane+origin combination
canon (ClassicalConic object) – Object with the conic section class instances of each object and their properties
plot_sun (bool, optional (default = True)) – Flag to turn on/off plotting the Sun
sun_xyz (dict of numpy array, optional (default = None)) – Dictionary of arrays with the Sun positions in each plane+origin combination
planet_lines (dict of arrays, optional (default = None)) – Dictionary of arrays containing planet orbit lines for each planet in each plane+origin combination of shape (n_planets, n_points, 3)
planet_id (numpy string array, optional (default = None)) – Array containing ID tags for each planet of shape (n_planets,)
return_fig (bool, optional (default = False)) – Flag to turn on/off returning the figure object
output (str, optional (default = None)) – String containing the html of the figure
panel (str, optional (default = None)) – String containing which orientation to draw a single panel of. Must be one of “XY”, “XZ”, “YZ”
panels (str, optional (default = None)) – String containing which orientation to draw two panels of. Must be one of “XY”, “XZ”, “YZ”
special_lines (dict of arrays, option (default = None)) – Dictionary of arrays with the orbit lines for each special object in each plane+origin combination
special_canon (ClassicalConic object (default = None)) – Object with the conic section class instances of each special object and their properties
- Returns:
fig – Plotly figure object
- Return type:
object
- plotly_3D(lines: numpy.ndarray, canon: layup.orbit_maths.ClassicalConic, plot_sun: bool = True, show_plane: bool = True, planet_lines: numpy.ndarray | None = None, planet_id: numpy.ndarray | None = None, sun_xyz: numpy.ndarray | None = None, return_fig: bool = False, output: str | None = None, special_lines: numpy.ndarray | None = None, special_canon: layup.orbit_maths.ClassicalConic | None = None)[source]
Create a 3D interactive Plotly figure of orbits
- Parameters:
lines (dict of numpy array) – Dictionary of arrays with the orbit lines for each object in each plane+origin combination
canon (dict of objects) – Dictionary with the conic section class instances of each object and their properties
plot_sun (bool, optional (default = True)) – Flag to turn on/off plotting the Sun
show_plane (bool, optional (default = True)) – Flag to turn on/off plotting the reference plane (ecliptic or equatorial)
planet_lines (dict of arrays, optional (default = None)) – Dictionary of arrays containing planet orbit lines for each planet in each plane+origin combination of shape (n_planets, n_points, 3)
planet_id (numpy string array, optional (default = None)) – Array containing ID tags for each planet of shape (n_planets,)
sun_xyz (dict of numpy array, optional (default = None)) – Dictionary of arrays with the Sun positions in each plane+origin combination
return_fig (bool, optional (default = False)) – Flag to turn on/off returning the figure object
output (str, optional (default = None)) – String containing the html of the figure
special_lines (dict of arrays, option (default = None)) – Dictionary of arrays with the orbit lines for each special object in each plane+origin combination
special_canon (ClassicalConic object (default = None)) – Object with the conic section class instances of each special object and their properties
- Returns:
fig – Plotly figure object
- Return type:
object