{ "cells": [ { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "#Script to support Exercise 2.2.9, modeling shuttlecock data.\n", "\n", "#Times at which position was measured (seconds)\n", "times = [0, 0.347, 0.47, 0.519, 0.582, 0.65, 0.674, 0.717, 0.766, 0.823, 0.87, 1.031, 1.193, 1.354, 1.501, 1.726, 1.873];" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "#Distance fallen (meters)\n", "data = [0, 0.61, 1.00, 1.22, 1.52, 1.83, 2.00, 2.13, 2.44, 2.74, 3.00, 4.00, 5.00, 6.00, 7.00, 8.50, 9.50];" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "#Plot the raw data versus time. Call the plot \"plot1\".\n", "pdata = list(zip(times,data))\n", "plt1 = scatter_plot(pdata)\n", "plt1.axes_labels(['time (seconds)','Distance (meters)'])\n", "show(plt1)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "#Now use g = 9.8, take a guess at k (k=1 is a good start), plot d(t) from part (b), and compare to the data." ] } ], "metadata": { "kernelspec": { "display_name": "SageMath 9.2", "language": "sage", "name": "sagemath" }, "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.7.7" } }, "nbformat": 4, "nbformat_minor": 4 }