3D Surface
Damped Ripple Wave
Radial sine wave with exponential damping using cyan-magenta custom colormap.
Output
Python
import matplotlib.pyplot as plt
import numpy as np
from matplotlib.colors import LinearSegmentedColormap
# Create custom colormap
colors = ['#0a0a0f', '#1a1a3f', '#06b6d4', '#ec4899']
cmap = LinearSegmentedColormap.from_list('cyan_magenta', colors, N=256)
# Make data
X = np.linspace(-5, 5, 100)
Y = np.linspace(-5, 5, 100)
X, Y = np.meshgrid(X, Y)
R = np.sqrt(X**2 + Y**2)
Z = np.sin(R) * np.exp(-R/5)
fig = plt.figure(figsize=(10, 8), facecolor='#0a0a0f')
ax = fig.add_subplot(111, projection='3d', facecolor='#0a0a0f')
surf = ax.plot_surface(X, Y, Z, cmap=cmap, linewidth=0, antialiased=True, alpha=0.9)
ax.set_xlabel('X', color='white', fontsize=10)
ax.set_ylabel('Y', color='white', fontsize=10)
ax.set_zlabel('Z', color='white', fontsize=10)
ax.set_title('Damped Ripple Wave', color='white', fontsize=14, fontweight='bold', pad=20)
ax.tick_params(colors='#64748b', labelsize=8)
ax.xaxis.pane.fill = False
ax.yaxis.pane.fill = False
ax.zaxis.pane.fill = False
ax.xaxis.pane.set_edgecolor('#1e293b')
ax.yaxis.pane.set_edgecolor('#1e293b')
ax.zaxis.pane.set_edgecolor('#1e293b')
ax.view_init(elev=25, azim=45)
plt.tight_layout()
plt.show()
Library
Matplotlib
Category
3D Charts
More 3D Surface examples
☕