Строю трехмерный график для функции z = (0.1 * y - sin(0.2 * x - y - 0.4)) * (2 + cos(0.7 * y - x + 2)**2) и никак не могу понять в чем ошибка.
import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
from math import sin, cos, pi
fig = plt.figure(figsize=(7, 4))
ax_3d = Axes3D(fig)
x = np.arange(0, 5, 0.1)
y = x
xgrid, ygrid = np.meshgrid(x, y)
zgrid = (0.1 * y - sin(0.2 * x - y - 0.4)) * (2 + cos(0.7 * y - x + 2)**2)
ax_3d.plot_surface(xgrid, ygrid, zgrid)
plt.show()