Question: Assignment If you drop an anvil from a great height, it accelerates downward... Write a program containing two functions: one that returns v(t) and another

Assignment

If you drop an anvil from a great height, it accelerates downward... Write a program containing two functions: one that returns v(t) and another that returns y(t) for the anvil. Your program should plot both these functions on one graph, for time ranging from 0 to 5 seconds. Have the program label the axes appropriately and put ANVIL in the title.

Hint

Actually, everything you need code-wise is on this page, except the physics. Don't forget to import matplotlib.pyplot and numpy! Here's a sample program that puts together much of this example code.

import matplotlib.pyplot as plt import numpy as np def silly(x): y = np.sqrt(x**2 + 9) return y a = np.linspace(0, 10, 100) plt.plot(a, silly(a), 'go') plt.plot(a, silly(a) + 1, 'rx') plt.show() 

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!