Is this the Correct Equation for Approximating y(0.8) Using Euler's Method?

  • Context: MHB 
  • Thread starter Thread starter alane1994
  • Start date Start date
  • Tags Tags
    Euler's method Method
Click For Summary

Discussion Overview

The discussion revolves around the application of Euler's method for approximating the value of a function at specific points, particularly focusing on the equation for calculating y(0.8) based on previous values. Participants explore different approaches and calculations related to the initial value problem (IVP) given by the differential equation dy/dx = -2y.

Discussion Character

  • Homework-related
  • Mathematical reasoning
  • Exploratory

Main Points Raised

  • One participant questions whether the correct equation for y(0.8) should be y(0.4) + (Δt × y'(0.4)) or y(0.4) - (Δt × y'(0.4)), noting that their homework system indicates the first option is correct.
  • Another participant provides a detailed application of Euler's method to the IVP dy/dx = -2y, presenting a recursion formula and closed-form solution for y_n, and calculates approximations for y(0.4) and y(0.8) using various time steps (Δt).
  • A third participant introduces a different IVP dy/dx = ky and discusses the expected outcome using Euler's method, suggesting a connection to the exponential function as n approaches infinity.
  • A later reply expresses excitement about understanding the relationship between the time step and the number of iterations needed to solve for "k" in the context of the approximations.

Areas of Agreement / Disagreement

Participants present differing equations and methods for approximating y(0.8), indicating that there is no consensus on the correct approach. Multiple competing views and calculations are shared without resolution.

Contextual Notes

The discussion includes various assumptions about the time step (Δt) and the nature of the differential equations involved. Some calculations depend on specific values of Δt and the number of iterations, which are not universally agreed upon.

alane1994
Messages
36
Reaction score
0
OK, my homework system says that the 0.20000 is correct... but all of my others are incorrect...

Is this the correct term for the top right box?:confused:

y(0.8)=y(0.4)+(\Delta{t} \times y^{\prime}(0.4))
OR
y(0.8)=y(0.4)-(\Delta{t} \times y^{\prime}(0.4))

According to the 0.20000 answer... the top one is correct.

[TABLE="class: cms_table_grid, width: 500, align: center"]
[TR]
[TD="align: center"]
[FONT=MathJax_Main]Δ[FONT=MathJax_Math]t
[/TD]
[TD="align: center"]Approximations of y(0.4)[/TD]
[TD="align: center"]Approximations of y(0.8)[/TD]
[/TR]
[TR]
[TD="align: center"]0.4[/TD]
[TD="align: center"]0.20000[/TD]
[TD="align: center"]?[/TD]
[/TR]
[TR]
[TD="align: center"]0.2[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]0.1[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]0.05[/TD]
[TD="align: center"][/TD]
[TD][/TD]
[/TR]
[/TABLE]
 
Last edited:
Physics news on Phys.org
Since you have been given another problem, I'll work the original in full.

We are given:

$\displaystyle \frac{dy}{dx}=-2y$ where $\displaystyle y(0)=1$

I would generalize as follows:

Using Euler's method for this IVP, we find the recursion:

$\displaystyle y_{n+1}=y_{n}\left(1-2\Delta t \right)$ where $\displaystyle y_0=1$

which gives us the closed-form:

$\displaystyle y_n=\left(1-2\Delta t \right)^n$

a) To approximate $\displaystyle y(0.4)$, we find with:

i) $\displaystyle \Delta t=0.4\,\therefore\,n=1$ we have

$\displaystyle y(0.4)\approx y_1=1-2(0.4)=0.2$

ii) $\displaystyle \Delta t=0.2\,\therefore\,n=2$ we have

$\displaystyle y(0.4)\approx y_2=(1-2(0.2))^2=0.36$

iii) $\displaystyle \Delta t=0.1\,\therefore\,n=4$ we have

$\displaystyle y(0.4)\approx y_4=(1-2(0.1))^4=0.4096$

iv) $\displaystyle \Delta t=0.05\,\therefore\,n=8$ we have

$\displaystyle y(0.4)\approx y_8=(1-2(0.05))^8=0.43046721$

b) To approximate $\displaystyle y(0.8)$, we find with:

i) $\displaystyle \Delta t=0.4\,\therefore\,n=2$ we have

$\displaystyle y(0.4)\approx y_2=(1-2(0.4))^2=0.04$

ii) $\displaystyle \Delta t=0.2\,\therefore\,n=4$ we have

$\displaystyle y(0.4)\approx y_4=(1-2(0.2))^4=0.1296$

iii) $\displaystyle \Delta t=0.1\,\therefore\,n=8$ we have

$\displaystyle y(0.4)\approx y_8=(1-2(0.1))^8=0.16777216$

iv) $\displaystyle \Delta t=0.05\,\therefore\,n=16$ we have

$\displaystyle y(0.4)\approx y_{16}=(1-2(0.05))^{16}=0.185302018885$
 
Last edited:
Suppose we are given the IVP:

$\displaystyle \frac{dy}{dx}=ky$ where $\displaystyle 0\ne k\in{R}$ and $\displaystyle y(x_0)=y_0$

We then obtain using Euler's method:

$\displaystyle y_{n+1}=y_0(1+k\Delta x)^n$

where $\displaystyle \Delta x=\frac{x_n-x_0}{n}$

So, by solving the IVP, we should expect then that:

$\displaystyle y_0\lim_{n\to\infty}\left(1+\frac{k(x_n-x_0)}{n} \right)^n=y_0e^{k(x_n-x_0)}$

You should verify this is true using L'Hôpital's rule.
 
I GOT IT! (Party)(Party)(Dance)(Dance)(Bigsmile)...(Cool)

In the table at the top the y(0.4)=y(t_{k}).

You have the equation t_{k}=\Delta{t} \times k

You know the y(t_{k}) , as well as the \Delta{t}, you then just solve for "k"!

"k" is the number of iterations of it that you have to do.
 
Last edited:

Similar threads

  • · Replies 5 ·
Replies
5
Views
5K
  • · Replies 9 ·
Replies
9
Views
3K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 7 ·
Replies
7
Views
4K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 9 ·
Replies
9
Views
4K
  • · Replies 2 ·
Replies
2
Views
7K
Replies
20
Views
4K
  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K