1 / 43

M athematical M odeling

M athematical M odeling. Team B 김도현 서수빈 이혜경. Estimate the Solution with Euler s Method. ‘ ’. Context. Preliminary Problem Summary Further. Exact solution MATLAB Code Result. Preliminary. ODE solving method. - seperable -integrate factor. Preliminary. Euler s Method. ‘ ’.

nico
Download Presentation

M athematical M odeling

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. MathematicalModeling Team B 김도현 서수빈 이혜경

  2. Estimate the Solution with Euler s Method • ‘’

  3. Context Preliminary Problem Summary Further • Exact solution • MATLAB Code • Result

  4. Preliminary. ODE solving method -seperable -integrate factor

  5. Preliminary. Eulers Method ‘’

  6. Euler s Method • ‘’

  7. Problem 1. Use Euler s method with step size h = 0.1 to approximate the solution to the IVP ‘’ at the points x = 1.1, 1.2, 1.3, 1.4 and 1.5. Compare your numerical result with the exact solution.

  8. Problem 1. Find Exact Solution

  9. Problem 1. Find Exact Solution

  10. Problem 1. Find Exact Solution

  11. Problem 1. Find Exact Solution

  12. Problem 1. Find Exact Solution

  13. Problem 1. Find Exact Solution

  14. Problem 1. Coding i=1; x(1,1)=1; y(1,1)=4; slope(1,1)=x(1,1).*(y(1,1).^(1/2)); whilei<=5 i=i+1; x(1,i)=x(1,i-1)+0.1; y(1,i)=slope(1,i-1).*0.1+y(1,i-1); slope(1,i)=x(1,i).*(y(1,i).^(1/2)); end z=((x.^2+7).^2)/16; plot(x,y,'r'); hold on plot(x,z,'b'); error=abs(y-z)

  15. Problem 1. Result Exact solution Estimated solution

  16. Problem 2. Use Euler s method to find approximates to the solution of the IVP ‘’ at x = 1, taking 1, 2, 4, 8, and 16 steps. Compare your numerical result with the exact solution.

  17. Problem 2. Find Exact Solution

  18. Problem 2. Find Exact Solution

  19. Problem 2. Find Exact Solution

  20. Problem 2. Find Exact Solution

  21. Problem 2. Find Exact Solution

  22. Problem 2. Coding i=1; y(1,1)=1; n=input('How many steps ?'); x=0:1/n:1; whilei<=n y(1,i+1)=y(1,i)/n+y(1,i); i=i+1; end s=0:1/1000:1; z=exp(s); plot(x,y,'r'); hold on plot(s,z,'b'); hold off

  23. Problem 2. Result n=1 Exact solution Estimated solution Error = 0.7183

  24. Problem 2. Result n=2 Exact solution Estimated solution Error = 0.4684

  25. Problem 2. Result n=4 Exact solution Estimated solution Error = 0.2769

  26. Problem 2. Result n=8 Exact solution Estimated solution Error = 0.1525

  27. Problem 2. Result n=16 Exact solution Estimated solution Error = 0.0804

  28. Problem 2. Result n=1024 Exact solution Estimated solution Error = 0.0013

  29. Problem 2. Result n=1 n=2 n=4 n=8 n=16

  30. Problem 3. ‘’ Use Euler s method with step size h = 0.1 to approximate to the solution of the IVP with x0 = 0, and compute the first 10 iterations of this scheme, and compare the result with the exact solution.

  31. Problem 3. Find Exact Solution

  32. Problem 3. Find Exact Solution

  33. Problem 3. Find Exact Solution

  34. Problem 3. Find Exact Solution

  35. Problem 3. Find Exact Solution

  36. Problem 3. Find Exact Solution

  37. Problem 3. Find Exact Solution

  38. Problem 3. Find Exact Solution

  39. Problem 3. Coding i=1; y(1,1)=1; x=0:0.1:1; whilei<=10 y(1,i+1)=(y(1,i)+sin(x(1,i))).*0.1+y(1,i); i=i+1; end s=0:1/1000:1; z=3*exp(s)/2-sin(s)/2-cos(s)/2; plot(x,y,'r'); hold on plot(s,z,'b'); error=abs(3*exp(x)/2-sin(x)/2-cos(x)/2-y)

  40. Problem 3. Result Exact solution Estimated solution Error = 0.2371

  41. Summary - error 1) Same mesh size, different x value 2) Same x value, different mesh size 3) error=0.2371 with mesh h=0.1 at x=1

  42. Summary - compare whenΔx=1 1) mesh=0.1 (10 iteration) error=0.1983 2) mesh=0.125 (8 steps) error=0.1525 3) mesh h=0.1 error=0.2371

  43. Further... Taylor Series Method Improved Euler s Method Runge-Kutta Method ‘’ Chebyshev Node Choosing

More Related