# Use Euler's method with h=0.05 to find approximate values?

1. Nov 4, 2014

### Math10

1. The problem statement, all variables and given/known data
Use Euler's method with h=0.05 to find approximate values for the solution of the initial-value problem y'=2x^2+3y^2-2, y(2)=1 at x=0.1, 0.2, 0.3.

2. Relevant equations
None.

3. The attempt at a solution
Here's my work:

y'=2x^2+3y^2-2, y(2)=1
f(x, y)=2x^2+3y^2-2, x0=2, y0=1
y(0.1)=y1=y0+f(2, 1)(0.05)=1.45
y(0.2)=y2=y1+f(2.1, 1.45)(0.05)=2.10638
y(0.3)=y3=y2+f(2.3, 2.10638)(0.05)=3.20091
The answers I got are 1.45, 2.10638 and 3.20091. But are my answers right? Please check my answer and correct me if I'm wrong.

2. Nov 4, 2014

### HallsofIvy

Staff Emeritus
[No, those are not correct.. If dy/dx= 2x^2+3y^2-2, then dy= (2x^2+3y^2-2)dx
$y_n(x_n)+ f(x_n, y_n)(dx)$ is $y(x_{n+1)}= y(x_n+ dx)$.
$y_0+ f(2, 1)(0.05)$ is $y(0+ 0.05)= y(0.05)$ NOT $y(0.1)$.

3. Nov 4, 2014

### vela

Staff Emeritus
Since you're evaluating f at x=2, that should be y(2.05) = y(2)+f(2,1)(0.05).

4. Nov 5, 2014

### Math10

So how do I start the problem?
y(2.05)=y(2)+f(2, 1)(0.05)=1.45
But where did y(2.05) come from?

5. Nov 5, 2014

### vela

Staff Emeritus
What's the basic idea of Euler's method? You should understand that before trying to do this problem. It'll make the calculations make much more sense. Right now it seems like you're just plugging in numbers without knowing why.

6. Nov 5, 2014

### Math10

To find approximate values for the solution of the initial-value problem at the given points.

7. Nov 5, 2014

### vela

Staff Emeritus
That's so general it describes every method for numerically solving a differential equation. What specifically is the idea behind Euler's method?