Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from mpl_toolkits import mplot3d
- import matplotlib.pyplot as plt
- import math
- import numpy as np
- def z_func(x,y):
- return np.exp(np.cos(x**2+y**2))
- x=np.linspace(-2*math.pi,2*math.pi,30)
- y=np.linspace(-2*math.pi,2*math.pi,30)
- Z=z_func(X,Y)
- X,Y=np.meshgrid(x,y)
- ax=plt.axes(projection='3d')
- fig=plt.figure(figsize=(10,8))
- ax.plot_surface(X,Y,Z)
- ax.view_init(45,45)
- ax.set_title("September2016 Q3(b)")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement