mth.122.handout.08

# mth.122.handout.08 - MTH 122 Calculus II Essex County...

This preview shows pages 1–3. Sign up to view the full content.

MTH 122 — Calculus II Essex County College — Division of Mathematics and Physics 1 Lecture Notes #8 — Sakai Web Project Material 1 Numerical Integration -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 2 3 4 5 6 7 8 9 10 11 12 13 14 Figure 1: Area of interest. Suppose we’re asked to evaluate Z 15 - 4 | x | sin x d x ? I think almost everyone would be stumped. However, in reality it is not always necessary to ﬁnd a deﬁnitive answer, but instead an approximation may suﬃce and in fact may be preferred. Approximations can be hard to come by, but today’s mathematical tools are quite good. For your own sake, you should try to do this problem with the tools you have at hand: calculator, desktop computer software, or even a computer language such as FORTRAN or C. Tools are nice to have, and here I am using an application called Grapher that is quite capable of doing numerical integration. Here’s what it give me using three diﬀerent built-in methods: Romberg Method: 44 . 8113 Euler Method: 44 . 8114 Runge Kutta Fourth Order Method: 44 . 8115 Mathematica actually choked 2 on it, but then quickly burped out 44 . 8114, which is the average of Grapher’s values anyway. 1 This document was prepared by Ron Bannon ( ron.bannon@mathography.org ) using L A T E X2 ε . Last revised January 10, 2009. 2 Here’s what it reported before giving me the value, “NIntegrate failed to converge to prescribed accuracy after 7 recursive bisections in x near x = - 0 . 06640625.” 1

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
As some of you may already know, I almost never write down a decimal answer, but sometimes I have no choice. The reason I have no choice here is that I cannot do this integration, so I need to use a method of approximation. Here’s the Mathematica code. You should also notice that In[20]:= Plot @ Abs @ x D ^ H Sin @ x DL , 8 x, - 4, 15 <D -2.5 2.5 5 7.5 10 12.5 15 2 4 6 8 10 12 14 Out[20]= Ü Graphics Ü In[21]:= Integrate @ Abs @ x D ^ H Sin @ x DL , 8 x, - 4, 15 <D Out[21]= - 4 15 Abs @ x D Sin @ x D x In[22]:= NIntegrate @ Abs @ x D ^ H Sin @ x DL , 8 x, - 4, 15 <D NIntegrate::ncvb : NIntegrate failed to converge to prescribed accuracy after 7 recursive bisections in x near x = - 0.0664063. More… Out[22]= 44.8114 Untitled-1 1 Figure 2: Mathematica Code Mathematica cannot do the integration either and I have to resort to a new command to force Mathematica to use a numerical method. Numerical methods are approximate, so although we might conjecture about an exact value, it is doubtful that we will be able to ﬁnd a closed form of this integral. Numerical integration is used on deﬁnite integrals when we cannot ﬁnd the antiderivative, or where speed is essential and approximations suﬃce. Being a numerical technique, we will rarely ﬁnd the exact value of the deﬁnite integral. The techniques discussed in this worksheet are easily implemented on a computer algebra system, however Mathematica actually has some
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 01/31/2011 for the course MTH 222 taught by Professor Ban during the Spring '10 term at Essex County College.

### Page1 / 11

mth.122.handout.08 - MTH 122 Calculus II Essex County...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online