basics of euler method
DESCRIPTION
Basics of Euler method for solving ordinary differential equations.TRANSCRIPT
-
Presentation of Numerical Methods
-
**Presented To: Maam Ayesha Akber
Presented By: Muhammad Sarwar 10EL20
-
Introduction To ODEs An equation that consists of derivatives is called a differential equation. Differential equations have applications in all areas of science and engineering. Mathematical formulation of most of the physical and engineering problems leads to differential equations. So, it is important for engineers and scientists to know how to set up differential equations
*
-
Types of ODEsDifferential equations are of two types Ordinary differential equations (ODE) Partial differential equations (PDE) An ordinary differential equation is that in which all the derivatives are with respect to a single independent variable.Examples of Ordinary Differential Equations.
*
-
Order & Degree of ODE Ordinary differential equations are classified in terms of order and degree. Order of an ordinary differential equation is the same as the highest derivative and the degree of an ordinary differential equation is the power of highest derivative. Thus the differential equation,
is of order 3 and degree 1. *
-
Eulers method is a numerical technique to solve ordinary differential equations of the form
So only first order ordinary differential equations can be solved by using Eulers method.
*
-
Eulers Method*Slope Figure 1 Graphical interpretation of the first step of Eulers method
http://numericalmethods.eng.usf.edu
-
Eulers Method*Figure 2. General graphical interpretation of Eulers method
-
How to write Ordinary Differential Equation*Example is rewritten asIn this caseHow does one write a first order differential equation in the form of
http://numericalmethods.eng.usf.edu
-
*A ball at 1200K is allowed to cool down in air at an ambient temperature of 300K. Assuming heat is lost only due to radiation, the differential equation for the temperature of the ball is given by Find the temperature at seconds using Eulers method. Assume a step size of seconds.
-
*Step 1: is the approximate temperature at
-
Solution Cont*For Step 2: is the approximate temperature at
http://numericalmethods.eng.usf.edu
-
Solution Cont*The exact solution of the ordinary differential equation is given by the solution of a non-linear equation asThe solution to this nonlinear equation at t=480 seconds is
-
Comparison of Exact and Numerical Solutions*Figure 3. Comparing exact and Eulers method
Chart1
12001200
901.08106.09
775.09110.32
699.66
647.57
h=240
Exact Solution
(K)
Time, t(sec)
Temperature,
Sheet1
01200
120901.08
240775.09
360699.66
480647.57
01200
240106.09
480110.32
Sheet1
h=240
Exact Solution
(K)
Time, t(sec)
Temperature,
Sheet2
Sheet3
-
Effect of step size*Table 1. Temperature at 480 seconds as a function of step size, h(exact)
Step, hq(480)Et|t|%4802401206030987.81110.32546.77614.97632.771635.4537.26100.8032.60714.806252.5482.96415.5665.03522.2864
-
Comparison with exact results*Figure 4. Comparison of Eulers method with exact solution for different step sizes
Chart1
1200120012001200
653.05106.09-987.81901.08
607.03110.32775.09
573.22699.66
546.77647.57
Exact solution
h=120
h=240
h=480
(K)
Time, t (sec)
Temperature,
Sheet1
01200
120653.05
240607.03
360573.22
480546.77
01200
240106.09
480110.32
01200
480-987.81
01200
120901.08
240775.09
360699.66
480647.57
Sheet1
Exact solution
h=120
h=240
h=480
(K)
Time, t (sec)
Temperature,
Sheet2
Sheet3
-
Effects of step size on Eulers Method*Figure 5. Effect of step size in Eulers method.
Chart1
-987.81647.57
110.32
546.78
614.97
632.77
(K)
Step size, h (s)
Temperature,
Sheet1
480-987.81
240110.32
120546.78
60614.97
30632.77
0647.57
Sheet1
(K)
Step size, h (s)
Temperature,
Sheet2
Sheet3
-
Errors in Eulers Method*It can be seen that Eulers method has large errors. This can be illustrated using Taylor series.As you can see the first two terms of the Taylor seriesThe true error in the approximation is given byare the Eulers method.
-
Some Pointes To Remember:Generally, the approximation gets less accurate the further you are away from the initial value.Better accuracy is achieved when the points in the approximation are closer together.Your approximation is going to be above the actual curve if the function isconcave downand below the actual curve if the function isconcave up .*
-
Euler Method in Electrical EngineeringElectrical Engineering involves use of Differential Equations in many ways:Differential equations(DE's) are used to describe the behavior of circuits containing energy storage components - capacitors and inductors. The order of the DE equates to the number of such storage elements in the circuit - either in series or in parallel.The easiest example is aseries RC network. One resistor and one capacitor in series with a voltage source Vs So Vs = Vc + Vr*
-
Euler Method in Electrical Engineering*
-
Thank You!
Any Questions?*
*