{ "cells": [ { "cell_type": "markdown", "id": "7d3bbaeb", "metadata": {}, "source": [ "# Example - 61 - Compute v_inf and arrival declination from flyby dates (2)" ] }, { "cell_type": "markdown", "id": "111bf35d", "metadata": {}, "source": [ "In this example, we compute the arrival v_inf and declination from a trajectory whose last flyby and arrival dates are known." ] }, { "cell_type": "markdown", "id": "846576c6", "metadata": {}, "source": [ "**Note**: This examples requires ```astropy``` and ```poliastro``` to be installed. These are not installed by default when AMAT is installed and must be installed separately using ```pip install astropy``` and ```pip install poliastro```. " ] }, { "cell_type": "code", "execution_count": 1, "id": "fb7b5263", "metadata": {}, "outputs": [], "source": [ "import numpy as np\n", "from astropy.time import Time\n", "from AMAT.arrival import Arrival" ] }, { "cell_type": "markdown", "id": "3f85217e", "metadata": {}, "source": [ "In this example, we use the flyby dates from Option 5: Uranus Orbiter Concept with Probe presented in the [NASA Ice-Giants Pre-Decadal Study Report](https://www.lpi.usra.edu/icegiants/mission_study/Full-Report.pdf)." ] }, { "cell_type": "code", "execution_count": 2, "id": "01af1bca", "metadata": {}, "outputs": [], "source": [ "arrival = Arrival()\n", "arrival.set_vinf_vec_from_lambert_arc(lastFlybyPlanet='JUPITER',\n", " arrivalPlanet='URANUS',\n", " lastFlybyDate=Time(\"2036-03-28 00:00:00\", scale='tdb'),\n", " arrivalDate=Time(\"2043-05-17 00:00:00\", scale='tdb'))" ] }, { "cell_type": "code", "execution_count": 3, "id": "3793363d", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Arrival v_inf vector, ICRF: [-4.0742798 6.69346343 3.04912046] km/s\n" ] } ], "source": [ "print(\"Arrival v_inf vector, ICRF: \"+str(arrival.v_inf_vec)+\" km/s\")" ] }, { "cell_type": "code", "execution_count": 4, "id": "ad187b1b", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Arrival v_inf magnitude: 8.41 km/s.\n" ] } ], "source": [ "print(\"Arrival v_inf magnitude: \"+str(round(arrival.v_inf_mag, 2))+\" km/s.\")" ] }, { "cell_type": "code", "execution_count": 5, "id": "d06d77f1", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Arrival Declination: -47.88 deg.\n" ] } ], "source": [ "print(\"Arrival Declination: \"+str(round(arrival.declination, 2))+\" deg.\")" ] }, { "cell_type": "markdown", "id": "ff78b1fe", "metadata": {}, "source": [ "Compare with values in page 406 of the [NASA Ice-Giants Pre-Decadal Study Report](https://www.lpi.usra.edu/icegiants/mission_study/Full-Report.pdf)." ] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.8.10" } }, "nbformat": 4, "nbformat_minor": 5 }