import numpy as np
import matplotlib.pyplot as plt
x0 = 0
y0 = 1
xf = 2
n = 100
deltax = (xf-x0)/(n-1)
x = np.linspace(x0,xf,n)
y = np.zeros([n])
y[0] = y0
for i in range(1,n):
y[i]=deltax*(y[-1])
plt.plot(x,y,'o')
plt.xlabel('Value of x')
plt.ylabel('Value of y' )
plt.title('Approximate Solution with Forward Eulers Method')
plt.show( )