Finding arctan with Euler

282 Views Asked by At

I am asked to find $y(t) = \arctan(t)$ using forward Euler method for $t=1,$ using initial condition. There is exact solution, but I need to approximate using methods such as Euler and Runge Kutta.

so $$y´ = 1 / (1 + x^2),\,y(0) = 0$$

but $y´$ is not a function dependent on 2 variables. there is only x in the function. is there something fundamentally wrong with the question or with my understanding?

1

There are 1 best solutions below

0
On BEST ANSWER

$$y_{n+1}=y_n+hy_n'=y_n+\frac{h}{1+x_n^2}$$