1 Use Eulers Method to solve the DFQ For an example of a pro
1. Use Euler\'s Method to solve the DFQ
For an example of a program whose efficient solution requires adaptive step size methods, we consider an Apollo satellite in orbit about the Earth E and Moon M. Figure 4.3.8 shows an x-1x_2-coordinate system whose origin lies at the center of mass of the Earth and the Moon and which rotates at the rate of one revolution per \"moon month\" of approximately tau = 27.32 days, so the Earth and Moon remain fixed in their positions on the x_1-axis. If we take as unit distance the distance (about 384,000 kilometers, assumed constant) between the Earth and Moon centers, then their coordinates are E(-mu, 0) and M(1 - mu, 0), where mu = m_M/(m_E + m_M) in terms of the Earth mass m E and Moon mass m_M. If we take the total mass m_E + m_M as the unit of mass and tau(2pi) 4.35 days as the unit of time, then the gravitational constant is G = 1 in Eq. (26), and the equations of motion of the satellite position S(x_1, x_2) are where r_E and r_M denote the satellite\'s distance to the Earth and Moon (indicated in Fig. 4.3.8). The initial two terms on the right-hand side of each equation result from the rotation of the coordinate system. In the system of units described here, the lunar mass is approximately m_M = 0.012277471. The second-order system in (27) can be converted to an equivalent first-order system (of four differential equations) by substituting x\'_1 = x_3, x\'_2 = x_4 so that x\"_1 = x\'_3, x\"_2 = x\'_4.Solution
Though in principle it is possible to use Taylor\'s method of any order for the given initial value problem to get good approximations, it has few draw backs like
To overcome these difficulties, Euler developed a scheme by approximating y\' in the givenivp. The scheme is as follows:
The derivative term in the first order ivp
y\' = f(x, y) , y(x0) = y0
is approximated by making use of Taylor series approximation of the dependent variabley(x) at the point xi+1. That is
y(xi+1) = y(xi+ Dx) = y(xi) + Dxy\'(xi) + (Dx2 / 2)y\'\'(xi) + . . .
= y(xi) + Dxf(xi, yi) + (Dx2 / 2)y\'\'(xi) + . . .
(... y\'(xi) = f(xi, yi))
if the infinite series is truncated from the term Dx2 onwards, then
y(xi+1) = y(xi) + Dx y\'(xi) (or)
yi+1 = yi + Dx fi for all i
That is,
for i = 0, y1 = y0 + Dx f0
i = 1, y2 = y1 + Dx f1
!
i = n-1, yn = yn-1 + Dx fn-1
Since y0 and hence f0 are known (from initial condition) in the equation corresponding to i = 0, all the terms on the r.h.s are known. So y1 that is, y at x1 is calculated easily from this equation. Similarly once y1 is known, r.h.s of the equation corresponding to i = 1 is also known so y2 can be computed. As we proceed in the same way until i = n-1, yn can be obtained. This is an explicit method because in any equation there is only one unknown which can be separated to the left side of the equation.
