Главная » Просмотр файлов » Heath - Scientific Computing

Heath - Scientific Computing (523150), страница 61

Файл №523150 Heath - Scientific Computing (Heath - Scientific Computing) 61 страницаHeath - Scientific Computing (523150) страница 612013-09-15СтудИзба
Просмтор этого файла доступен только зарегистрированным пользователям. Но у нас супер быстрая регистрация: достаточно только электронной почты!

Текст из файла (страница 61)

When representedin the monomial basis, a polynomialpn−1 (t) = x1 + x2 t + · · · + xn tn−1can be evaluated very efficiently using Horner’s method , also known as nested evaluationor synthetic division:pn−1 (t) = x1 + t(x2 + t(x3 + t(· · · (xn−1 + xn t) · · ·))),which requires only n additions and n multiplications. For example,1 − 4t + 5t2 − 2t3 + 3t4 = 1 + t(−4 + t(5 + t(−2 + 3t))).The same principle applies in forming a Vandermonde matrix:ai,j = φj (ti ) = tj−1= ti φj−1 (ti ) = ti ai,j−1ifor j = 2, . . .

, n,which is superior to using explicit exponentiation.Other manipulations of the interpolating polynomial, such as differentiation or integration, are also relatively easy with the monomial basis representation.7.2.2Lagrange InterpolationFor a given set of data points (ti , yi ), i = 1, . . .

, n, the Lagrange basis functions are givenbyQnk=1, k6=j (t − tk )lj (t) = Qn.k=1, k6=j (tj − tk )For the Lagrange basis, we havelj (ti ) =1 if i = j,0 if i 6= jwhich means that the matrix of the linear system Ax = y is the identity matrix I. Thus,in the Lagrange basis the polynomial interpolating the data points (ti , yi ) is given bypn−1 (t) = y1 l1 (t) + y2 l2 (t) + · · · + yn ln (t).7.2. POLYNOMIAL INTERPOLATION1.00.50.0225. ....................

... ... ........................................................................................24...................................................3....................... ....... ................ ............ . ........... ...................

.... ...... ..... ......................5.........1............................................................................................... ........ ........... ..................... .................................. ...................... ......................... ............... ................ ............................... ................. .. ... ................................................................................................................................................................................................................................................

.................................................................................................................................................................. ................................................................. ... ... ...

... ... ... ................ ................................................................................... ...... ...... ....... ...... ..lllll0.00.51.0Figure 7.2: Lagrange basis functions.Fig. 7.2 shows the Lagrange basis functions for five equally spaced points on the interval[0, 1]. Compare this graph with the corresponding graph for the monomial basis functionsin Fig. 7.1.Lagrange interpolation makes it easy to determine the interpolating polynomial for agiven set of data points, but the Lagrangian form of the polynomial is more expensiveto evaluate for a given argument compared with the monomial basis representation.

TheLagrangian form is also more difficult to differentiate, integrate, etc.Example 7.2 Lagrange Interpolation. We illustrate Lagrange interpolation by usingit to find the interpolating polynomial for the three data points (−2, −27), (0, −1), (1, 0)of Example 7.1. The Lagrange form for the polynomial of degree two interpolating threepoints (t1 , y1 ), (t2 , y2 ), (t3 , y3 ) isp2 (t) = y1(t − t2 )(t − t3 )(t − t1 )(t − t3 )(t − t1 )(t − t2 )+ y2+ y3.(t1 − t2 )(t1 − t3 )(t2 − t1 )(t2 − t3 )(t3 − t1 )(t3 − t2 )For this particular set of data, this formula becomes(t − 0)(t − 1)(t − (−2))(t − 1)(t − (−2))(t − 0)+ (−1)+0(−2 − 0)(−2 − 1)(0 − (−2))(0 − 1)(1 − (−2))(1 − 0)t(t − 1) (t + 2)(t − 1)= −27+.62p2 (t) = −27Depending on the use to be made of it, the polynomial can be evaluated in this form forany t, or it can be simplified to produce the same result as we saw previously for the samedata using the monomial basis (as expected, since the interpolating polynomial is unique).7.2.3Newton InterpolationWe have thus far seen two methods for polynomial interpolation, one for which the basismatrix A is full (Vandermonde) and the other for which it is diagonal (Lagrange).

As aresult, these two methods have very different trade-offs between the cost of computing the226CHAPTER 7. INTERPOLATIONinterpolant and the cost of evaluating it for a given argument. We will now consider Newtoninterpolation, for which the basis matrix is between these two extremes.For a given set of data points (ti , yi ), i = 1, . . . , n, the Newton interpolating polynomialhas the formpn−1 (t) = x1 + x2 (t − t1 ) + x3 (t − t1 )(t − t2 ) + · · · + xn (t − t1 )(t − t2 ) · · · (t − tn−1 ).Thus, the basis functions for Newton interpolation are given byφj (t) =j−1Y(t − tk ),j = 1, . . .

, n,k=1where we take the value of the product to be 1 when the limits make it vacuous. For i < j,we then have φj (ti ) = 0, so that the basis matrix A, with aij = φj (ti ), is lower triangular.Hence, the solution x to the system Ax = y, which determines the coefficients of the basisfunctions in the interpolant, can be computed by forward-substitution in O(n2 ) arithmeticoperations. In practice, the triangular matrix need not be formed explicitly, since its entriescan be computed as needed during the forward-substitution process.Fig. 7.3 shows the Newton basis functions for five equally spaced points on the interval[0, 2].

Compare this graph with the corresponding graphs for the monomial and Lagrangebasis functions given earlier.3.02.01.0.............. ..... ...... ..... ............................... ... ............... ... ... ....... ... ... ... .... ... .......... ... ... ... ..................... ........................... ... ............ ... .............................. ... ... .....................................................................................................................................................................................................................................................................................................................................................................................................

................................ ... ...1........... ... ................ ..... ... ................ ...... ..................................................2345........... ... ..... ........................... ... ......... ....... ... ................. ............................................ .................................................. ...........................

........................................... ........................... ...................................... ................... . ..................................φφ0.00.00.5φ1.0φ1.5φ2.0Figure 7.3: Newton basis functions.Example 7.3 Newton Interpolation. We illustrate Newton interpolation by using itto find the interpolating polynomial for the three data points (−2, −27), (0, −1), (1, 0) ofExample 7.1. With the Newton basis, we have the triangular linear system1110t2 − t1t3 − t1   0x1y10x2 = y2  .(t3 − t1 )(t3 − t2 )x3y37.2.

POLYNOMIAL INTERPOLATION227For this particular set of data, this system becomes  1 0 0x1−27 1 2 0   x2  =  −1  ,1 3 3x30whose solution, obtained by forward-substitution, is x = [ −27interpolating polynomial is13−4 ]T . Thus, thep(t) = −27 + 13(t + 2) − 4(t + 2)t,which reduces to the same polynomial we obtained earlier by the other two methods.Once the coefficients xj have been determined, the resulting Newton polynomial interpolant can be evaluated efficiently for any argument using Horner’s nested evaluationscheme:pn−1 (t) = x1 + (t − t1 )(x2 + (t − t2 )(x3 + (t − t3 )(· · · (xn−1 + xn (t − tn−1 )) · · ·))).Thus, Newton interpolation has a better balance between the cost of computing the interpolant and the cost of evaluating it for a given argument than the other two methods.The Newton basis functions can be derived by considering the problem of building apolynomial interpolant incrementally as successive new data points are added. If pj (t) is apolynomial of degree j − 1 interpolating j given points, then for any constant xj+1pj+1 (t) = pj (t) + xj+1 φj+1 (t)is a polynomial of degree j that also interpolates the same j points.

The free parameterxj+1 can then be chosen so that pj+1 (t) interpolates the (j + 1)st point, yj+1 . Specifically,xj+1 =yj+1 − pj (tj+1 ).φj+1 (tj+1 )In this manner, Newton interpolation begins with the constant polynomial p1 (t) = y1interpolating the first data point and builds successively from there to incorporate theremaining data points into the interpolant.Example 7.4 Incremental Newton Interpolation.

Характеристики

Тип файла
PDF-файл
Размер
1,88 Mb
Тип материала
Учебное заведение
Неизвестно

Список файлов книги

Свежие статьи
Популярно сейчас
А знаете ли Вы, что из года в год задания практически не меняются? Математика, преподаваемая в учебных заведениях, никак не менялась минимум 30 лет. Найдите нужный учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
6455
Авторов
на СтудИзбе
305
Средний доход
с одного платного файла
Обучение Подробнее