Finished assignment

See code and plot