Untitled

 avatar
unknown
plain_text
a year ago
1.1 kB
2
Indexable
import matplotlib.pyplot as plt
import numpy as np

# Create a diagram of a spider or Sputnik sinker

fig, ax = plt.subplots()

# Draw the sinker
sinker_body = plt.Circle((0.5, 0.5), 0.1, color='gray')
ax.add_artist(sinker_body)

# Draw the prongs
prong_length = 0.2
prong_angle = 45  # degrees
angles = [i * prong_angle for i in range(8)]

for angle in angles:
    x_end = 0.5 + prong_length * np.cos(np.radians(angle))
    y_end = 0.5 + prong_length * np.sin(np.radians(angle))
    ax.plot([0.5, x_end], [0.5, y_end], color='black')

# Draw the seabed
ax.plot([0, 1], [0.3, 0.3], color='saddlebrown', linewidth=3)

# Labels
ax.text(0.1, 0.5, 'Sinker Body', fontsize=10, verticalalignment='center')
ax.text(0.1, 0.6, 'Prong', fontsize=10, verticalalignment='center')
ax.text(0.1, 0.2, 'Seabed', fontsize=10, verticalalignment='center', color='saddlebrown')

# Set plot limits and title
ax.set_xlim(0, 1)
ax.set_ylim(0, 1)
ax.set_aspect('equal', adjustable='box')
ax.axis('off')
plt.title('Spider/Sputnik Sinker with Prongs')

# Show the diagram
plt.show()
Editor is loading...
Leave a Comment