Skip to main content

Posts

Showing posts with the label Sin-wave

Sin wave - Colab - Git

 if you want to run the code in python to improve your skills please use the colab link for the code where data is plotted using matplot lib. enjoy python !!!.     get the code and collab link from here - https://github.com/naveez-alagarsamy/matplotlib reference - https://matplotlib.org/stable/plot_types/basic/plot.html   still facing issue in running the code  no worries - run the code in your local machine -  import matplotlib.pyplot as plt import numpy as np x = np.array([0,3.14/4, 3.14/2,3.14, (3.14/2)+3.14, (2*3.14)]) print(x) y = np.sin(x) print((y)) # make data # plot fig, ax = plt.subplots() ax.plot(x, y, linewidth=2.0) ax.set(xlim=(0, 50), xticks=np.arange(0, 20),        ylim=(-2, 2), yticks=np.arange(-2, 2)) plt.show()