Draw a Heart in Python with Matplotlib ♥️

Published: 09 August 2022
on channel: Python 5
420
15

#shorts #python #programming

import matplotlib.pyplot as plt
import numpy as np
t = np.arange(0,2*np.pi, 0.1)
x = 16*np.sin(t)**3
y = 13*np.cos(t)-5*np.cos(2*t)-2*np.cos(3*t)-np.cos(4*t)
plt.plot(x,y)
plt.show()


Watch video Draw a Heart in Python with Matplotlib ♥️ online without registration, duration hours minute second in high quality. This video was added by user Python 5 09 August 2022, don't forget to share it with your friends and acquaintances, it has been viewed on our site 420 once and liked it 15 people.