Comprendre la méthode de Newton sur l'exemple des polynômes.

Le but de ce bloc-notes est de comprendre la méthode de Newton-Raphson d'abord telle qu'elle a été expliquée par Newton, puis avec les notations de Raphson, mais toujours sur l'exemple des polynômes.

La méthode de Newton-Raphson est une méthode pour approcher les racines d'une fonctions dérivables - c'est à dire les arguments sur lesquels la fonction s'annule. Vous en saurez plus très vite.

Crédits: Ce bloc-notes s'inspire de l'article «La méthode de Newton et son histoire» d'André Bonnet, paru dans un bulletin de l'APMEP et disponible en libre téléchargement ici :
http://www.apmep.fr/IMG/pdf/APMEP_article_BV_7_C_A.pdf
Cependant les seuls extraits de texte recopiés tels quel depuis cet article, sont ceux des textes historiques. (Il n'est pas clair par quelle licence de droit d'auteur est régi cet article.)

1. La méthode telle qu'elle est décrite par Newton

Dans les deux paragraphes suivants, vous avez des extraits du texte de Newton (en anglais) où ce qu'on appelle aujourd'hui la méthode de Newton apparaît pour la première fois. Ce texte a été publié après sa mort par Colson sous le titre "The method of fluxions and infinite series". Vous pouvez le télécharger ici :
http://www.e-rara.ch/zut/doi/10.3931/e-rara-10833
Ce même texte traduit en français par Buffon est lisible ici:
http://gallica.bnf.fr/ark:/12148/bpt6k62411f.r=La%20m%C3%A9thode%20des%20fluxions%20et%20des%20suites%20infinies?rk=21459;2

«§20. Let this equation y³−2y−5=0 be proposed to be resolved, and let 2 be a number (any how found) which differs from the true Root less than by a tenth part of itself. Then I make 2+p=y, and substitute 2+p for the given Equation, by which is produced a new Equation p³+6p²+10p−1=0, whose Root is to be sought for, that it maybe added to the Quote. Thus rejecting p³+6p² because of its smallness, the remaining Equation 10p−1=0, or p = 0.1 will approach very near to the truth. Therefore I write this in the Quote and suppose 0,1+q=p, and substitute this fictious value of P as before, which produces q³+6,3q²+11,23q+0,061=0. And since 11,23q+0,061=0 is near the truth, or q = −0.054 nearly, (that is dividing 0,061 by 11,23, till so many Figures arise as there are places between the first figures of this, and of the principal Quote exclusively, as there are two places between 2 and 0,005) I write −0,0054 in the lower part of the quote, as being negative; and supposing −0,0054+r=q, I substitute this as before. And thus I continue the Operation as far as I please, in the manner of the following diagram:
┌────────────────┬─────────────────────────────┐ │y³−2y−5=0 │+2,10000000 │ │ │−0,00544852 │ │ │─────────── │ │ │+2,09455148, &c=y │ ├────────────────┼─────────────────────────────┤ │2+p=y. +y³│+ 8 + 12p + 6p² + p³ │ │ −2y │− 4 −2p │ │ −5 │− 5 │ ├────────────────┼─────────────────────────────┤ │ The sum │− 1 + 10p + 6p² + p³ │ ├────────────────┼─────────────────────────────┤ │0,1+q=p. +p³│+ 0,001 + 0,03q + 0,3q² + q³│ │ +6p²│+ 0,06 + 1,2 q + 6 q² │ │ +10p │+ 1 + 10 q │ │ −1 │− 1 │ ├────────────────┼─────────────────────────────┤ │ The sum │+ 0,061 + 11,23q + 6,3q² + q³│ ├────────────────┼─────────────────────────────┤ │−0,0054+r=q. +q³│[…] │ │ +6,3 q²│[…] │ │ +11,23 q │[…] │ │ +0,061 │[…] │ ├────────────────┼─────────────────────────────┤ │ The sum │0,0005416+11,162r […] │ ├────────────────┼─────────────────────────────┤ │−0,00004852+s=r.│[…] │ └────────────────┴─────────────────────────────┘
»

«§21. But the Work may be much abbreviated towards the end by this Method, especially in Equations of many Dimensions. Having first determined how far you intend to extract the Root, count so many places after the first Figure of the Coefficient of the last Term but one, of the Equations that result on the right side of the Diagram, as there remain places to be filled up in the Quote, and reject the Decimals that follow. But in the last Term the Decimals may be neglected, after so many more places as are the decimal places that are filled up in the Quote. And in the antepenultimate Term reject all that are after fo many fewer places. And so on, by proceeding Arithmetically, according to that Interval of places: Or, which is the same thing, you may cut off every where so many Figures as in the penultimate Term, so that their lowest places may be in Arithmetical Progression, according to the Series of the Terms, or are to be supposed to be supplied with Cyphers, when it happens otherwise. Thus in the present Example, if I desired to continue the Quote no farther than to the eighth place of Decimals, when I substituted 0,0054+r for q, where four decimal places are compleated in the Quote, and as many remain to be compleated, I might have omitted the Figures in the five inferior places, which therefore I have marked or cancelled by little Lines drawn through them ; and indeed I might also have omitted the first Term r³, although its Coefficient be 0,99999. Those Figures therefore being expunged, for the following Operation there arises the Sum 0,0005416+11,162r, which by Division, continued as far as the Term prescribed, gives 0,00004852 for r, which compleats the Quote to the Period required. Then subtracting the negative part of the Quote from the affirmative part, there arises 2,09455148 for the Root of the propofed Equation. »

Vous allez maintenant refaire l'exemple de Newton.

Déclarations et affectations

Commencons par déclarer les objets utiles.

Nous allons chercher une racine approchée du polynôme y³−2y−5. Il nous faudra donc déclarer ce polynôme. Pour mettre en application les concepts appris cette semaine, je vais vous demander de bien préciser son Anneau de coefficients.

Pour rappel, lorsqu'on veut que x represente le polynôme x à coefficients dans l'anneau RR = RealField(), qui est une des implementations à virgule flottante du corps des nombres réels dans Sage, on écrit x = polygen(RR,'x'). (C'est à dire qu'ensuite x est vu comme un élément de l'anneau de polynômes RR[x].)

In [67]:
R
Out[67]:
2
In [ ]: