fig, ax = plt.subplots() fig.set_tight_layout(False) X = np.linspace(-np.pi, np.pi, 256,endpoint=True) C,S = np.cos(X), np.sin(X) ax.plot(X,C) ax.plot(X,S) plt.show()