.
x = a * cos(u) * cos(v)
y = b * cos(u) * sin(v)
z = c * sin(u)
np.meshgrid
, .
a, b, c = 4, 8, 6
space = np.linspace(0, 2 * np.pi, 50)
u, v = np.meshgrid(space)
x = a * np.cos(u) * np.cos(v)
y = b * np.cos(u) * np.sin(v)
z = c * np.sin(u)
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')
ax.scatter(x, y, z)
fig.show()


, , , . x ^ 2/a ^ 2 + y ^ 2/b ^ 2 + z ^ 2/c ^ 2 = 1
a, b, c = 4, 8, 6
xs, ys, zs = np.mgrid[-a + 1:a + 1:15j, -b + 1:b + 1:15j, -c + 1:c + 1:15j]
mask = xs**2/(a**2) + ys**2/(b**2) + zs**2/(c**2) <= 1
xs[~mask] = 0
ys[~mask] = 0
zs[~mask] = 0
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')
ax.scatter(xs, ys, zs)
fig.show()

