Skip to content

Commit

Permalink
MNT: polishup the notebook
Browse files Browse the repository at this point in the history
  • Loading branch information
Gui-FernandesBR committed Dec 18, 2023
1 parent a9da239 commit 4a350ee
Showing 1 changed file with 1 addition and 34 deletions.
35 changes: 1 addition & 34 deletions docs/examples/juno3_flight_sim.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@
],
"source": [
"mandioca = SolidMotor(\n",
" thrust_source=\"/home/gfalves/Documents/github/RocketPy/data/motors/mandioca/thrustCurve.csv\",\n",
" thrust_source=\"../../data/motors/mandioca/thrustCurve.csv\",\n",
" reshape_thrust_curve=(5.8, 8800),\n",
" grain_number=5,\n",
" grain_separation=0.006,\n",
Expand Down Expand Up @@ -612,39 +612,6 @@
")"
]
},
{
"cell_type": "code",
"execution_count": 55,
"metadata": {},
"outputs": [],
"source": [
"# read the cots_gnss\n",
"\n",
"cots_gnss_df = pd.read_csv(\"../../data/juno3/cots_GNSS.csv\")\n",
"\n",
"# Convert the 'UTCTIME' column to datetime\n",
"cots_gnss_df[\"UTCTIME\"] = pd.to_datetime(\n",
" cots_gnss_df[\"UTCTIME\"], format=\"%b %d %Y %H:%M:%S.%f %Z\"\n",
")\n",
"\n",
"# Calculate the differences in seconds from the first timestamp\n",
"cots_gnss_df[\"time (s)\"] = (\n",
" cots_gnss_df[\"UTCTIME\"] - cots_gnss_df[\"UTCTIME\"].iloc[0]\n",
").dt.total_seconds()\n",
"\n",
"# convert the ALT, HORZV, and the VERTV to m\n",
"# cots_gnss_df[\"ALT\"] = cots_gnss_df[\"ALT\"] * 0.3048\n",
"# cots_gnss_df[\"HORZV\"] = cots_gnss_df[\"HORZV\"] * 0.3048\n",
"# cots_gnss_df[\"VERTV\"] = cots_gnss_df[\"VERTV\"] * 0.3048\n",
"\n",
"# select columns\n",
"cots_gnss_df = cots_gnss_df[[\"time (s)\", \"ALT\", \"HORZV\", \"VERTV\", \"LAT\", \"LON\"]]\n",
"cots_gnss_df\n",
"\n",
"# override the file\n",
"cots_gnss_df.to_csv(\"../../data/juno3/cots_GNSS.csv\", index=False)"
]
},
{
"cell_type": "code",
"execution_count": 58,
Expand Down

0 comments on commit 4a350ee

Please sign in to comment.