import matplotlib.pyplot as plt

from numpy import array

x_grid = array(range(1, 100)) / 30.0

plt.figure()

plt.plot(x_grid, x_grid, "k-")

plt.plot(x_grid, x_grid ** 2, "k--")

plt.plot(x_grid, x_grid ** 3, "k.")

plt.xlabel(r"$x$")

plt.ylabel(r"$y=f(x)$")

plt.title("Linear, Quadratic, and Cubic Growth")

plt.show()