import numpy as np
import matplotlib.pyplot as plt
X = np.linspace(-np.pi, np.pi, 256, endpoint = True)
C, S = np.cos(X), np.sin(X)
plt.rcParams['xtick.direction'] = 'inout' # in; out; inout
plt.rcParams['ytick.direction'] = 'inout'
plt.plot(X,C)
plt.plot(X,S)
plt.show()