fbpx
Wikipedia

Finite difference

A finite difference is a mathematical expression of the form f (x + b) − f (x + a). If a finite difference is divided by ba, one gets a difference quotient. The approximation of derivatives by finite differences plays a central role in finite difference methods for the numerical solution of differential equations, especially boundary value problems.

The difference operator, commonly denoted is the operator that maps a function f to the function defined by

A difference equation is a functional equation that involves the finite difference operator in the same way as a differential equation involves derivatives. There are many similarities between difference equations and differential equations, specially in the solving methods. Certain recurrence relations can be written as difference equations by replacing iteration notation with finite differences.

In numerical analysis, finite differences are widely used for approximating derivatives, and the term "finite difference" is often used as an abbreviation of "finite difference approximation of derivatives".[1][2][3] Finite difference approximations are finite difference quotients in the terminology employed above.

Finite differences were introduced by Brook Taylor in 1715 and have also been studied as abstract self-standing mathematical objects in works by George Boole (1860), L. M. Milne-Thomson (1933), and Károly Jordan [de] (1939). Finite differences trace their origins back to one of Jost Bürgi's algorithms (c. 1592) and work by others including Isaac Newton. The formal calculus of finite differences can be viewed as an alternative to the calculus of infinitesimals.[4]

Basic types edit

 
The three types of the finite differences. The central difference about x gives the best approximation of the derivative of the function at x.

Three basic types are commonly considered: forward, backward, and central finite differences.[1][2][3]

A forward difference, denoted   of a function f is a function defined as

 

Depending on the application, the spacing h may be variable or constant. When omitted, h is taken to be 1; that is,

 

A backward difference uses the function values at x and xh, instead of the values at x + h and x:

 

Finally, the central difference is given by

 

Relation with derivatives edit

Finite difference is often used as an approximation of the derivative, typically in numerical differentiation.

The derivative of a function f at a point x is defined by the limit

 

If h has a fixed (non-zero) value instead of approaching zero, then the right-hand side of the above equation would be written

 

Hence, the forward difference divided by h approximates the derivative when h is small. The error in this approximation can be derived from Taylor's theorem. Assuming that f is twice differentiable, we have

 

The same formula holds for the backward difference:

 

However, the central (also called centered) difference yields a more accurate approximation. If f is three times differentiable,

 

The main problem[citation needed] with the central difference method, however, is that oscillating functions can yield zero derivative. If f (nh) = 1 for n odd, and f (nh) = 2 for n even, then f ′(nh) = 0 if it is calculated with the central difference scheme. This is particularly troublesome if the domain of f is discrete. See also Symmetric derivative.

Authors for whom finite differences mean finite difference approximations define the forward/backward/central differences as the quotients given in this section (instead of employing the definitions given in the previous section).[1][2][3]

Higher-order differences edit

In an analogous way, one can obtain finite difference approximations to higher order derivatives and differential operators. For example, by using the above central difference formula for f ′(x + h/2) and f ′(xh/2) and applying a central difference formula for the derivative of f ′ at x, we obtain the central difference approximation of the second derivative of f:

Second-order central
 

Similarly we can apply other differencing formulas in a recursive manner.

Second order forward
 
Second order backward
 

More generally, the n-th order forward, backward, and central differences are given by, respectively,

Forward
 
Backward
 
Central
 

These equations use binomial coefficients after the summation sign shown as (n
i
)
. Each row of Pascal's triangle provides the coefficient for each value of i.

Note that the central difference will, for odd n, have h multiplied by non-integers. This is often a problem because it amounts to changing the interval of discretization. The problem may be remedied taking the average of δn[ f ](xh/2) and δn[ f ](x + h/2).

Forward differences applied to a sequence are sometimes called the binomial transform of the sequence, and have a number of interesting combinatorial properties. Forward differences may be evaluated using the Nörlund–Rice integral. The integral representation for these types of series is interesting, because the integral can often be evaluated using asymptotic expansion or saddle-point techniques; by contrast, the forward difference series can be extremely hard to evaluate numerically, because the binomial coefficients grow rapidly for large n.

The relationship of these higher-order differences with the respective derivatives is straightforward,

 

Higher-order differences can also be used to construct better approximations. As mentioned above, the first-order difference approximates the first-order derivative up to a term of order h. However, the combination

 
approximates f ′(x) up to a term of order h2. This can be proven by expanding the above expression in Taylor series, or by using the calculus of finite differences, explained below.

If necessary, the finite difference can be centered about any point by mixing forward, backward, and central differences.

Polynomials edit

For a given polynomial of degree n ≥ 1, expressed in the function P(x), with real numbers a ≠ 0 and b and lower order terms (if any) marked as l.o.t.:

 

After n pairwise differences, the following result can be achieved, where h ≠ 0 is a real number marking the arithmetic difference:[5]

 

Only the coefficient of the highest-order term remains. As this result is constant with respect to x, any further pairwise differences will have the value 0.

Inductive proof edit

Base case edit

Let Q(x) be a polynomial of degree 1:

 

This proves it for the base case.

Inductive step edit

Let R(x) be a polynomial of degree m − 1 where m ≥ 2 and the coefficient of the highest-order term be a ≠ 0. Assuming the following holds true for all polynomials of degree m − 1:

 

Let S(x) be a polynomial of degree m. With one pairwise difference:

 

As ahm ≠ 0, this results in a polynomial T(x) of degree m − 1, with ahm as the coefficient of the highest-order term. Given the assumption above and m − 1 pairwise differences (resulting in a total of m pairwise differences for S(x)), it can be found that:

 

This completes the proof.

Application edit

This identity can be used to find the lowest-degree polynomial that intercepts a number of points (x, y) where the difference on the x-axis from one point to the next is a constant h ≠ 0. For example, given the following points:

x y
1 4
4 109
7 772
10 2641
13 6364

We can use a differences table, where for all cells to the right of the first y, the following relation to the cells in the column immediately to the left exists for a cell (a + 1, b + 1), with the top-leftmost cell being at coordinate (0, 0):

 

To find the first term, the following table can be used:

x y Δy Δ2y Δ3y
1 4
4 109 105
7 772 663 558
10 2641 1869 1206 648
13 6364 3723 1854 648

This arrives at a constant 648. The arithmetic difference is h = 3, as established above. Given the number of pairwise differences needed to reach the constant, it can be surmised this is a polynomial of degree 3. Thus, using the identity above:

 

Solving for a, it can be found to have the value 4. Thus, the first term of the polynomial is 4x3.

Then, subtracting out the first term, which lowers the polynomial's degree, and finding the finite difference again:

x y Δy Δ2y
1 4 − 4(1)3 = 4 − 4 = 0
4 109 − 4(4)3 = 109 − 256 = −147 −147
7 772 − 4(7)3 = 772 − 1372 = −600 −453 −306
10 2641 − 4(10)3 = 2641 − 4000 = −1359 −759 −306
13 6364 − 4(13)3 = 6364 − 8788 = −2424 −1065 −306

Here, the constant is achieved after only two pairwise differences, thus the following result:

 

Solving for a, which is −17, the polynomial's second term is −17x2.

Moving on to the next term, by subtracting out the second term:

x y Δy
1 0 − (−17(1)2) = 0 + 17 = 17
4 −147 − (−17(4)2) = −147 + 272 = 125 108
7 −600 − (−17(7)2) = −600 + 833 = 233 108
10 −1359 − (−17(10)2) = −1359 + 1700 = 341 108
13 −2424 − (−17(13)2) = −2424 + 2873 = 449 108

Thus the constant is achieved after only one pairwise difference:

 

It can be found that a = 36 and thus the third term of the polynomial is 36x. Subtracting out the third term:

x y
1 17 − 36(1) = 17 − 36 = −19
4 125 − 36(4) = 125 − 144 = −19
7 233 − 36(7) = 233 − 252 = −19
10 341 − 36(10) = 341 − 360 = −19
13 449 − 36(13) = 449 − 468 = −19

Without any pairwise differences, it is found that the 4th and final term of the polynomial is the constant −19. Thus, the lowest-degree polynomial intercepting all the points in the first table is found:

 

Arbitrarily sized kernels edit

Using linear algebra one can construct finite difference approximations which utilize an arbitrary number of points to the left and a (possibly different) number of points to the right of the evaluation point, for any order derivative. This involves solving a linear system such that the Taylor expansion of the sum of those points around the evaluation point best approximates the Taylor expansion of the desired derivative. Such formulas can be represented graphically on a hexagonal or diamond-shaped grid.[6] This is useful for differentiating a function on a grid, where, as one approaches the edge of the grid, one must sample fewer and fewer points on one side.[7] Finite difference approximations for non-standard (and even non-integer) stencils given an arbitrary stencil and a desired derivative order may be constructed.[8]

Properties edit

  • For all positive k and n
     
  • Leibniz rule:
     

In differential equations edit

An important application of finite differences is in numerical analysis, especially in numerical differential equations, which aim at the numerical solution of ordinary and partial differential equations. The idea is to replace the derivatives appearing in the differential equation by finite differences that approximate them. The resulting methods are called finite difference methods.

Common applications of the finite difference method are in computational science and engineering disciplines, such as thermal engineering, fluid mechanics, etc.

Newton's series edit

The Newton series consists of the terms of the Newton forward difference equation, named after Isaac Newton; in essence, it is the Gregory–Newton interpolation formula[9] (named after Isaac Newton and James Gregory), first published in his Principia Mathematica in 1687,[10][11] namely the discrete analog of the continuous Taylor expansion,

 

which holds for any polynomial function f and for many (but not all) analytic functions. (It does not hold when f is exponential type  . This is easily seen, as the sine function vanishes at integer multiples of  ; the corresponding Newton series is identically zero, as all finite differences are zero in this case. Yet clearly, the sine function is not zero.) Here, the expression

 
is the binomial coefficient, and
 
is the "falling factorial" or "lower factorial", while the empty product (x)0 is defined to be 1. In this particular case, there is an assumption of unit steps for the changes in the values of x, h = 1 of the generalization below.

Note the formal correspondence of this result to Taylor's theorem. Historically, this, as well as the Chu–Vandermonde identity,

 
(following from it, and corresponding to the binomial theorem), are included in the observations that matured to the system of umbral calculus.

Newton series expansions can be superior to Taylor series expansions when applied to discrete quantities like quantum spins (see Holstein–Primakoff transformation), bosonic operator functions or discrete counting statistics.[12]

To illustrate how one may use Newton's formula in actual practice, consider the first few terms of doubling the Fibonacci sequence f = 2, 2, 4, ... One can find a polynomial that reproduces these values, by first computing a difference table, and then substituting the differences that correspond to x0 (underlined) into the formula as follows,

 

For the case of nonuniform steps in the values of x, Newton computes the divided differences,

 
the series of products,
 
and the resulting polynomial is the scalar product,[13]
 

In analysis with p-adic numbers, Mahler's theorem states that the assumption that f is a polynomial function can be weakened all the way to the assumption that f is merely continuous.

Carlson's theorem provides necessary and sufficient conditions for a Newton series to be unique, if it exists. However, a Newton series does not, in general, exist.

The Newton series, together with the Stirling series and the Selberg series, is a special case of the general difference series, all of which are defined in terms of suitably scaled forward differences.

In a compressed and slightly more general form and equidistant nodes the formula reads

 

Calculus of finite differences edit

The forward difference can be considered as an operator, called the difference operator, which maps the function f to Δh[ f ].[14][15] This operator amounts to

 
where Th is the shift operator with step h, defined by Th[ f ](x) = f (x + h), and I is the identity operator.

The finite difference of higher orders can be defined in recursive manner as Δn
h
≡ Δhn − 1
h
)
. Another equivalent definition is Δn
h
= [ThI]n
.

The difference operator Δh is a linear operator, as such it satisfies Δh[αf + βg](x) = α Δh[ f ](x) + β Δh[g](x).

It also satisfies a special Leibniz rule indicated above, Δh(f (x)g(x)) = (Δhf (x)) g(x+h) + f (x) (Δhg(x)). Similar statements hold for the backward and central differences.

Formally applying the Taylor series with respect to h, yields the formula

 
where D denotes the continuum derivative operator, mapping f to its derivative f ′. The expansion is valid when both sides act on analytic functions, for sufficiently small h. Thus, Th = ehD, and formally inverting the exponential yields
 
This formula holds in the sense that both operators give the same result when applied to a polynomial.

Even for analytic functions, the series on the right is not guaranteed to converge; it may be an asymptotic series. However, it can be used to obtain more accurate approximations for the derivative. For instance, retaining the first two terms of the series yields the second-order approximation to f ′(x) mentioned at the end of the section § Higher-order differences.

The analogous formulas for the backward and central difference operators are

 

The calculus of finite differences is related to the umbral calculus of combinatorics. This remarkably systematic correspondence is due to the identity of the commutators of the umbral quantities to their continuum analogs (h → 0 limits),

 

A large number of formal differential relations of standard calculus involving functions f (x) thus map systematically to umbral finite-difference analogs involving f (xT−1
h
)
.

For instance, the umbral analog of a monomial xn is a generalization of the above falling factorial (Pochhammer k-symbol),

 
so that
 
hence the above Newton interpolation formula (by matching coefficients in the expansion of an arbitrary function f (x) in such symbols), and so on.

For example, the umbral sine is

 

As in the continuum limit, the eigenfunction of Δh/h also happens to be an exponential,

 

and hence Fourier sums of continuum functions are readily mapped to umbral Fourier sums faithfully, i.e., involving the same Fourier coefficients multiplying these umbral basis exponentials.[16] This umbral exponential thus amounts to the exponential generating function of the Pochhammer symbols.

Thus, for instance, the Dirac delta function maps to its umbral correspondent, the cardinal sine function,

 
and so forth.[17] Difference equations can often be solved with techniques very similar to those for solving differential equations.

The inverse operator of the forward difference operator, so then the umbral integral, is the indefinite sum or antidifference operator.

Rules for calculus of finite difference operators edit

Analogous to rules for finding the derivative, we have:

  • Constant rule: If c is a constant, then
     
  • Linearity: if a and b are constants,
     

All of the above rules apply equally well to any difference operator as to Δ, including δ and .

  • Product rule:
     
  • Quotient rule:
     
    or
     
  • Summation rules:
     

See references.[18][19][20][21]

Generalizations edit

  • A generalized finite difference is usually defined as
     
    where μ = (μ0, …, μN) is its coefficient vector. An infinite difference is a further generalization, where the finite sum above is replaced by an infinite series. Another way of generalization is making coefficients μk depend on point x: μk = μk(x), thus considering weighted finite difference. Also one may make the step h depend on point x: h = h(x). Such generalizations are useful for constructing different modulus of continuity.
  • The generalized difference can be seen as the polynomial rings R[Th]. It leads to difference algebras.
  • Difference operator generalizes to Möbius inversion over a partially ordered set.
  • As a convolution operator: Via the formalism of incidence algebras, difference operators and other Möbius inversion can be represented by convolution with a function on the poset, called the Möbius function μ; for the difference operator, μ is the sequence (1, −1, 0, 0, 0, …).

Multivariate finite differences edit

Finite differences can be considered in more than one variable. They are analogous to partial derivatives in several variables.

Some partial derivative approximations are:

 

Alternatively, for applications in which the computation of f is the most costly step, and both first and second derivatives must be computed, a more efficient formula for the last case is

 
since the only values to compute that are not already needed for the previous four equations are f (x + h, y + k) and f (xh, yk).

See also edit

References edit

  1. ^ a b c Paul Wilmott; Sam Howison; Jeff Dewynne (1995). The Mathematics of Financial Derivatives: A Student Introduction. Cambridge University Press. p. 137. ISBN 978-0-521-49789-3.
  2. ^ a b c Peter Olver (2013). Introduction to Partial Differential Equations. Springer Science & Business Media. p. 182. ISBN 978-3-319-02099-0.
  3. ^ a b c M Hanif Chaudhry (2007). Open-Channel Flow. Springer. p. 369. ISBN 978-0-387-68648-6.
  4. ^ Jordán, op. cit., p. 1 and Milne-Thomson, p. xxi. Milne-Thomson, Louis Melville (2000): The Calculus of Finite Differences (Chelsea Pub Co, 2000) ISBN 978-0821821077
  5. ^ "Finite differences of polynomials". February 13, 2018.
  6. ^ Fraser, Duncan C. (January 1, 1909). "On the Graphic Delineation of Interpolation Formulæ". Journal of the Institute of Actuaries. 43 (2): 235–241. doi:10.1017/S002026810002494X. Retrieved April 17, 2017.
  7. ^ notes
  8. ^ Finite Difference Coefficients Calculator
  9. ^ Burkard Polster/Mathologer (2021). " Why don't they teach Newton's calculus of 'What comes next?' " on YouTube
  10. ^ Newton, Isaac, (1687). Principia, Book III, Lemma V, Case 1
  11. ^ Iaroslav V. Blagouchine (2018). "Three notes on Ser's and Hasse's representations for the zeta-functions" (PDF). Integers (Electronic Journal of Combinatorial Number Theory). 18A: 1–45. arXiv:1606.02044.
  12. ^ König, Jürgen; Hucht, Fred (2021). "Newton series expansion of bosonic operator functions". SciPost Physics. 10 (1): 007. arXiv:2008.11139. Bibcode:2021ScPP...10....7K. doi:10.21468/SciPostPhys.10.1.007. S2CID 221293056.
  13. ^ Richtmeyer, D. and Morton, K.W., (1967). Difference Methods for Initial Value Problems, 2nd ed., Wiley, New York.
  14. ^ Boole, George, (1872). A Treatise On The Calculus of Finite Differences, 2nd ed., Macmillan and Company. On line. Also, [Dover edition 1960]
  15. ^ Jordan, Charles, (1939/1965). "Calculus of Finite Differences", Chelsea Publishing. On-line: [1]
  16. ^ Zachos, C. (2008). "Umbral Deformations on Discrete Space-Time". International Journal of Modern Physics A. 23 (13): 2005–2014. arXiv:0710.2306. Bibcode:2008IJMPA..23.2005Z. doi:10.1142/S0217751X08040548. S2CID 16797959.
  17. ^ Curtright, T. L.; Zachos, C. K. (2013). "Umbral Vade Mecum". Frontiers in Physics. 1: 15. arXiv:1304.0429. Bibcode:2013FrP.....1...15C. doi:10.3389/fphy.2013.00015. S2CID 14106142.
  18. ^ Levy, H.; Lessman, F. (1992). Finite Difference Equations. Dover. ISBN 0-486-67260-3.
  19. ^ Ames, W.F. (1977). Numerical Methods for Partial Differential Equations. New York, NY: Academic Press. Section 1.6. ISBN 0-12-056760-1.
  20. ^ Hildebrand, F.B. (1968). Finite-Difference Equations and Simulations. Englewood Cliffs, NJ: Prentice-Hall. Section 2.2.
  21. ^ Flajolet, Philippe; Sedgewick, Robert (1995). "Mellin transforms and asymptotics: Finite differences and Rice's integrals" (PDF). Theoretical Computer Science. 144 (1–2): 101–124. doi:10.1016/0304-3975(94)00281-M.
  • Richardson, C. H. (1954): An Introduction to the Calculus of Finite Differences (Van Nostrand (1954) online copy
  • Mickens, R. E. (1991): Difference Equations: Theory and Applications (Chapman and Hall/CRC) ISBN 978-0442001360

External links edit

  • "Finite-difference calculus", Encyclopedia of Mathematics, EMS Press, 2001 [1994]
  • Table of useful finite difference formula generated using Mathematica
  • D. Gleich (2005),
  • Discrete Second Derivative from Unevenly Spaced Points

finite, difference, finite, difference, mathematical, expression, form, finite, difference, divided, gets, difference, quotient, approximation, derivatives, finite, differences, plays, central, role, finite, difference, methods, numerical, solution, differenti. A finite difference is a mathematical expression of the form f x b f x a If a finite difference is divided by b a one gets a difference quotient The approximation of derivatives by finite differences plays a central role in finite difference methods for the numerical solution of differential equations especially boundary value problems The difference operator commonly denoted D displaystyle Delta is the operator that maps a function f to the function D f displaystyle Delta f defined byD f x f x 1 f x displaystyle Delta f x f x 1 f x A difference equation is a functional equation that involves the finite difference operator in the same way as a differential equation involves derivatives There are many similarities between difference equations and differential equations specially in the solving methods Certain recurrence relations can be written as difference equations by replacing iteration notation with finite differences In numerical analysis finite differences are widely used for approximating derivatives and the term finite difference is often used as an abbreviation of finite difference approximation of derivatives 1 2 3 Finite difference approximations are finite difference quotients in the terminology employed above Finite differences were introduced by Brook Taylor in 1715 and have also been studied as abstract self standing mathematical objects in works by George Boole 1860 L M Milne Thomson 1933 and Karoly Jordan de 1939 Finite differences trace their origins back to one of Jost Burgi s algorithms c 1592 and work by others including Isaac Newton The formal calculus of finite differences can be viewed as an alternative to the calculus of infinitesimals 4 Contents 1 Basic types 2 Relation with derivatives 3 Higher order differences 4 Polynomials 4 1 Inductive proof 4 1 1 Base case 4 1 2 Inductive step 4 2 Application 5 Arbitrarily sized kernels 5 1 Properties 6 In differential equations 7 Newton s series 8 Calculus of finite differences 8 1 Rules for calculus of finite difference operators 9 Generalizations 10 Multivariate finite differences 11 See also 12 References 13 External linksBasic types edit nbsp The three types of the finite differences The central difference about x gives the best approximation of the derivative of the function at x Three basic types are commonly considered forward backward and central finite differences 1 2 3 A forward difference denoted D h f displaystyle Delta h f nbsp of a function f is a function defined asD h f x f x h f x displaystyle Delta h f x f x h f x nbsp Depending on the application the spacing h may be variable or constant When omitted h is taken to be 1 that is D f x D 1 f x f x 1 f x displaystyle Delta f x Delta 1 f x f x 1 f x nbsp A backward difference uses the function values at x and x h instead of the values at x h and x h f x f x f x h D h f x h displaystyle nabla h f x f x f x h Delta h f x h nbsp Finally the central difference is given byd h f x f x h 2 f x h 2 D h 2 f x h 2 f x displaystyle delta h f x f x tfrac h 2 f x tfrac h 2 Delta h 2 f x nabla h 2 f x nbsp Relation with derivatives editFinite difference is often used as an approximation of the derivative typically in numerical differentiation The derivative of a function f at a point x is defined by the limitf x lim h 0 f x h f x h displaystyle f x lim h to 0 frac f x h f x h nbsp If h has a fixed non zero value instead of approaching zero then the right hand side of the above equation would be writtenf x h f x h D h f x h displaystyle frac f x h f x h frac Delta h f x h nbsp Hence the forward difference divided by h approximates the derivative when h is small The error in this approximation can be derived from Taylor s theorem Assuming that f is twice differentiable we haveD h f x h f x o h 0 as h 0 displaystyle frac Delta h f x h f x o h to 0 quad text as h to 0 nbsp The same formula holds for the backward difference h f x h f x o h 0 as h 0 displaystyle frac nabla h f x h f x o h to 0 quad text as h to 0 nbsp However the central also called centered difference yields a more accurate approximation If f is three times differentiable d h f x h f x o h 2 displaystyle frac delta h f x h f x o left h 2 right nbsp The main problem citation needed with the central difference method however is that oscillating functions can yield zero derivative If f nh 1 for n odd and f nh 2 for n even then f nh 0 if it is calculated with the central difference scheme This is particularly troublesome if the domain of f is discrete See also Symmetric derivative Authors for whom finite differences mean finite difference approximations define the forward backward central differences as the quotients given in this section instead of employing the definitions given in the previous section 1 2 3 Higher order differences editThis section needs additional citations for verification Please help improve this article by adding citations to reliable sources in this section Unsourced material may be challenged and removed Find sources Finite difference news newspapers books scholar JSTOR July 2018 Learn how and when to remove this message In an analogous way one can obtain finite difference approximations to higher order derivatives and differential operators For example by using the above central difference formula for f x h 2 and f x h 2 and applying a central difference formula for the derivative of f at x we obtain the central difference approximation of the second derivative of f Second order central f x d h 2 f x h 2 f x h f x h f x f x h h h f x h 2 f x f x h h 2 displaystyle f x approx frac delta h 2 f x h 2 frac frac f x h f x h frac f x f x h h h frac f x h 2f x f x h h 2 nbsp Similarly we can apply other differencing formulas in a recursive manner Second order forward f x D h 2 f x h 2 f x 2 h f x h h f x h f x h h f x 2 h 2 f x h f x h 2 displaystyle f x approx frac Delta h 2 f x h 2 frac frac f x 2h f x h h frac f x h f x h h frac f x 2h 2f x h f x h 2 nbsp Second order backward f x h 2 f x h 2 f x f x h h f x h f x 2 h h h f x 2 f x h f x 2 h h 2 displaystyle f x approx frac nabla h 2 f x h 2 frac frac f x f x h h frac f x h f x 2h h h frac f x 2f x h f x 2h h 2 nbsp More generally the n th order forward backward and central differences are given by respectively Forward D h n f x i 0 n 1 n i n i f x i h displaystyle Delta h n f x sum i 0 n 1 n i binom n i f bigl x ih bigr nbsp Backward h n f x i 0 n 1 i n i f x i h displaystyle nabla h n f x sum i 0 n 1 i binom n i f x ih nbsp Central d h n f x i 0 n 1 i n i f x n 2 i h displaystyle delta h n f x sum i 0 n 1 i binom n i f left x left frac n 2 i right h right nbsp These equations use binomial coefficients after the summation sign shown as ni Each row of Pascal s triangle provides the coefficient for each value of i Note that the central difference will for odd n have h multiplied by non integers This is often a problem because it amounts to changing the interval of discretization The problem may be remedied taking the average of dn f x h 2 and dn f x h 2 Forward differences applied to a sequence are sometimes called the binomial transform of the sequence and have a number of interesting combinatorial properties Forward differences may be evaluated using the Norlund Rice integral The integral representation for these types of series is interesting because the integral can often be evaluated using asymptotic expansion or saddle point techniques by contrast the forward difference series can be extremely hard to evaluate numerically because the binomial coefficients grow rapidly for large n The relationship of these higher order differences with the respective derivatives is straightforward d n f d x n x D h n f x h n o h h n f x h n o h d h n f x h n o h 2 displaystyle frac d n f dx n x frac Delta h n f x h n o h frac nabla h n f x h n o h frac delta h n f x h n o left h 2 right nbsp Higher order differences can also be used to construct better approximations As mentioned above the first order difference approximates the first order derivative up to a term of order h However the combinationD h f x 1 2 D h 2 f x h f x 2 h 4 f x h 3 f x 2 h displaystyle frac Delta h f x frac 1 2 Delta h 2 f x h frac f x 2h 4f x h 3f x 2h nbsp approximates f x up to a term of order h2 This can be proven by expanding the above expression in Taylor series or by using the calculus of finite differences explained below If necessary the finite difference can be centered about any point by mixing forward backward and central differences Polynomials editFor a given polynomial of degree n 1 expressed in the function P x with real numbers a 0 and b and lower order terms if any marked as l o t P x a x n b x n 1 l o t displaystyle P x ax n bx n 1 l o t nbsp After n pairwise differences the following result can be achieved where h 0 is a real number marking the arithmetic difference 5 D h n P x a h n n displaystyle Delta h n P x ah n n nbsp Only the coefficient of the highest order term remains As this result is constant with respect to x any further pairwise differences will have the value 0 Inductive proof edit Base case edit Let Q x be a polynomial of degree 1 D h Q x Q x h Q x a x h b a x b a h a h 1 1 displaystyle Delta h Q x Q x h Q x a x h b ax b ah ah 1 1 nbsp This proves it for the base case Inductive step edit Let R x be a polynomial of degree m 1 where m 2 and the coefficient of the highest order term be a 0 Assuming the following holds true for all polynomials of degree m 1 D h m 1 R x a h m 1 m 1 displaystyle Delta h m 1 R x ah m 1 m 1 nbsp Let S x be a polynomial of degree m With one pairwise difference D h S x a x h m b x h m 1 l o t a x m b x m 1 l o t a h m x m 1 l o t T x displaystyle Delta h S x a x h m b x h m 1 text l o t ax m bx m 1 text l o t ahmx m 1 text l o t T x nbsp As ahm 0 this results in a polynomial T x of degree m 1 with ahm as the coefficient of the highest order term Given the assumption above and m 1 pairwise differences resulting in a total of m pairwise differences for S x it can be found that D h m 1 T x a h m h m 1 m 1 a h m m displaystyle Delta h m 1 T x ahm cdot h m 1 m 1 ah m m nbsp This completes the proof Application edit This identity can be used to find the lowest degree polynomial that intercepts a number of points x y where the difference on the x axis from one point to the next is a constant h 0 For example given the following points x y 1 4 4 109 7 772 10 2641 13 6364 We can use a differences table where for all cells to the right of the first y the following relation to the cells in the column immediately to the left exists for a cell a 1 b 1 with the top leftmost cell being at coordinate 0 0 a 1 b 1 a b 1 a b displaystyle a 1 b 1 a b 1 a b nbsp To find the first term the following table can be used x y Dy D2y D3y 1 4 4 109 105 7 772 663 558 10 2641 1869 1206 648 13 6364 3723 1854 648 This arrives at a constant 648 The arithmetic difference is h 3 as established above Given the number of pairwise differences needed to reach the constant it can be surmised this is a polynomial of degree 3 Thus using the identity above 648 a 3 3 3 a 27 6 a 162 displaystyle 648 a cdot 3 3 cdot 3 a cdot 27 cdot 6 a cdot 162 nbsp Solving for a it can be found to have the value 4 Thus the first term of the polynomial is 4x3 Then subtracting out the first term which lowers the polynomial s degree and finding the finite difference again x y Dy D2y 1 4 4 1 3 4 4 0 4 109 4 4 3 109 256 147 147 7 772 4 7 3 772 1372 600 453 306 10 2641 4 10 3 2641 4000 1359 759 306 13 6364 4 13 3 6364 8788 2424 1065 306 Here the constant is achieved after only two pairwise differences thus the following result 306 a 3 2 2 a 18 displaystyle 306 a cdot 3 2 cdot 2 a cdot 18 nbsp Solving for a which is 17 the polynomial s second term is 17x2 Moving on to the next term by subtracting out the second term x y Dy 1 0 17 1 2 0 17 17 4 147 17 4 2 147 272 125 108 7 600 17 7 2 600 833 233 108 10 1359 17 10 2 1359 1700 341 108 13 2424 17 13 2 2424 2873 449 108 Thus the constant is achieved after only one pairwise difference 108 a 3 1 1 a 3 displaystyle 108 a cdot 3 1 cdot 1 a cdot 3 nbsp It can be found that a 36 and thus the third term of the polynomial is 36x Subtracting out the third term x y 1 17 36 1 17 36 19 4 125 36 4 125 144 19 7 233 36 7 233 252 19 10 341 36 10 341 360 19 13 449 36 13 449 468 19 Without any pairwise differences it is found that the 4th and final term of the polynomial is the constant 19 Thus the lowest degree polynomial intercepting all the points in the first table is found 4 x 3 17 x 2 36 x 19 displaystyle 4x 3 17x 2 36x 19 nbsp Arbitrarily sized kernels editMain article Finite difference coefficient Further information Five point stencil Using linear algebra one can construct finite difference approximations which utilize an arbitrary number of points to the left and a possibly different number of points to the right of the evaluation point for any order derivative This involves solving a linear system such that the Taylor expansion of the sum of those points around the evaluation point best approximates the Taylor expansion of the desired derivative Such formulas can be represented graphically on a hexagonal or diamond shaped grid 6 This is useful for differentiating a function on a grid where as one approaches the edge of the grid one must sample fewer and fewer points on one side 7 Finite difference approximations for non standard and even non integer stencils given an arbitrary stencil and a desired derivative order may be constructed 8 Properties edit For all positive k and n D k h n f x i 1 0 k 1 i 2 0 k 1 i n 0 k 1 D h n f x i 1 h i 2 h i n h displaystyle Delta kh n f x sum limits i 1 0 k 1 sum limits i 2 0 k 1 cdots sum limits i n 0 k 1 Delta h n left f x i 1 h i 2 h cdots i n h right nbsp Leibniz rule D h n f g x k 0 n n k D h k f x D h n k g x k h displaystyle Delta h n fg x sum limits k 0 n binom n k Delta h k f x Delta h n k g x kh nbsp In differential equations editMain article Finite difference method An important application of finite differences is in numerical analysis especially in numerical differential equations which aim at the numerical solution of ordinary and partial differential equations The idea is to replace the derivatives appearing in the differential equation by finite differences that approximate them The resulting methods are called finite difference methods Common applications of the finite difference method are in computational science and engineering disciplines such as thermal engineering fluid mechanics etc Newton s series editThe Newton series consists of the terms of the Newton forward difference equation named after Isaac Newton in essence it is the Gregory Newton interpolation formula 9 named after Isaac Newton and James Gregory first published in his Principia Mathematica in 1687 10 11 namely the discrete analog of the continuous Taylor expansion f x k 0 D k f a k x a k k 0 x a k D k f a displaystyle f x sum k 0 infty frac Delta k f a k x a k sum k 0 infty binom x a k Delta k f a nbsp which holds for any polynomial function f and for many but not all analytic functions It does not hold when f is exponential type p displaystyle pi nbsp This is easily seen as the sine function vanishes at integer multiples of p displaystyle pi nbsp the corresponding Newton series is identically zero as all finite differences are zero in this case Yet clearly the sine function is not zero Here the expression x k x k k displaystyle binom x k frac x k k nbsp is the binomial coefficient and x k x x 1 x 2 x k 1 displaystyle x k x x 1 x 2 cdots x k 1 nbsp is the falling factorial or lower factorial while the empty product x 0 is defined to be 1 In this particular case there is an assumption of unit steps for the changes in the values of x h 1 of the generalization below Note the formal correspondence of this result to Taylor s theorem Historically this as well as the Chu Vandermonde identity x y n k 0 n n k x n k y k displaystyle x y n sum k 0 n binom n k x n k y k nbsp following from it and corresponding to the binomial theorem are included in the observations that matured to the system of umbral calculus Newton series expansions can be superior to Taylor series expansions when applied to discrete quantities like quantum spins see Holstein Primakoff transformation bosonic operator functions or discrete counting statistics 12 To illustrate how one may use Newton s formula in actual practice consider the first few terms of doubling the Fibonacci sequence f 2 2 4 One can find a polynomial that reproduces these values by first computing a difference table and then substituting the differences that correspond to x0 underlined into the formula as follows x f D 0 D 1 D 2 1 2 0 2 2 2 2 3 4 f x D 0 1 D 1 x x 0 1 1 D 2 x x 0 2 2 x 0 1 2 1 0 x 1 1 2 x 1 x 2 2 2 x 1 x 2 displaystyle begin matrix begin array c c c c hline x amp f Delta 0 amp Delta 1 amp Delta 2 hline 1 amp underline 2 amp amp amp amp underline 0 amp 2 amp 2 amp amp underline 2 amp amp 2 amp 3 amp 4 amp amp hline end array amp quad begin aligned f x amp Delta 0 cdot 1 Delta 1 cdot dfrac x x 0 1 1 Delta 2 cdot dfrac x x 0 2 2 quad x 0 1 amp 2 cdot 1 0 cdot dfrac x 1 1 2 cdot dfrac x 1 x 2 2 amp 2 x 1 x 2 end aligned end matrix nbsp For the case of nonuniform steps in the values of x Newton computes the divided differences D j 0 y j D j k D j 1 k 1 D j k 1 x j k x j k gt 0 j max j k D 0 k D 0 k displaystyle Delta j 0 y j qquad Delta j k frac Delta j 1 k 1 Delta j k 1 x j k x j quad ni quad left k gt 0 j leq max left j right k right qquad Delta 0 k Delta 0 k nbsp the series of products P 0 1 P k 1 P k 3 x k displaystyle P 0 1 quad quad P k 1 P k cdot left xi x k right nbsp and the resulting polynomial is the scalar product 13 f 3 D 0 P 3 displaystyle f xi Delta 0 cdot P left xi right nbsp In analysis with p adic numbers Mahler s theorem states that the assumption that f is a polynomial function can be weakened all the way to the assumption that f is merely continuous Carlson s theorem provides necessary and sufficient conditions for a Newton series to be unique if it exists However a Newton series does not in general exist The Newton series together with the Stirling series and the Selberg series is a special case of the general difference series all of which are defined in terms of suitably scaled forward differences In a compressed and slightly more general form and equidistant nodes the formula readsf x k 0 x a h k j 0 k 1 k j k j f a j h displaystyle f x sum k 0 binom frac x a h k sum j 0 k 1 k j binom k j f a jh nbsp Calculus of finite differences editThe forward difference can be considered as an operator called the difference operator which maps the function f to Dh f 14 15 This operator amounts toD h T h I displaystyle Delta h T h I nbsp where Th is the shift operator with step h defined by Th f x f x h and I is the identity operator The finite difference of higher orders can be defined in recursive manner as Dnh Dh Dn 1h Another equivalent definition is Dnh Th I n The difference operator Dh is a linear operator as such it satisfies Dh af bg x a Dh f x b Dh g x It also satisfies a special Leibniz rule indicated above Dh f x g x Dhf x g x h f x Dhg x Similar statements hold for the backward and central differences Formally applying the Taylor series with respect to h yields the formulaD h h D 1 2 h 2 D 2 1 3 h 3 D 3 e h D I displaystyle Delta h hD frac 1 2 h 2 D 2 frac 1 3 h 3 D 3 cdots e hD I nbsp where D denotes the continuum derivative operator mapping f to its derivative f The expansion is valid when both sides act on analytic functions for sufficiently small h Thus Th ehD and formally inverting the exponential yields h D ln 1 D h D h 1 2 D h 2 1 3 D h 3 displaystyle hD ln 1 Delta h Delta h tfrac 1 2 Delta h 2 tfrac 1 3 Delta h 3 cdots nbsp This formula holds in the sense that both operators give the same result when applied to a polynomial Even for analytic functions the series on the right is not guaranteed to converge it may be an asymptotic series However it can be used to obtain more accurate approximations for the derivative For instance retaining the first two terms of the series yields the second order approximation to f x mentioned at the end of the section Higher order differences The analogous formulas for the backward and central difference operators areh D ln 1 h and h D 2 arsinh 1 2 d h displaystyle hD ln 1 nabla h quad text and quad hD 2 operatorname arsinh left tfrac 1 2 delta h right nbsp The calculus of finite differences is related to the umbral calculus of combinatorics This remarkably systematic correspondence is due to the identity of the commutators of the umbral quantities to their continuum analogs h 0 limits D h h x T h 1 D x I displaystyle left frac Delta h h x T h 1 right D x I nbsp A large number of formal differential relations of standard calculus involving functions f x thus map systematically to umbral finite difference analogs involving f xT 1h For instance the umbral analog of a monomial xn is a generalization of the above falling factorial Pochhammer k symbol x n x T h 1 n x x h x 2 h x n 1 h displaystyle x n equiv left xT h 1 right n x x h x 2h cdots bigl x n 1 h bigr nbsp so that D h h x n n x n 1 displaystyle frac Delta h h x n n x n 1 nbsp hence the above Newton interpolation formula by matching coefficients in the expansion of an arbitrary function f x in such symbols and so on For example the umbral sine issin x T h 1 x x 3 3 x 5 5 x 7 7 displaystyle sin left x T h 1 right x frac x 3 3 frac x 5 5 frac x 7 7 cdots nbsp As in the continuum limit the eigenfunction of Dh h also happens to be an exponential D h h 1 l h x h D h h e ln 1 l h x h l e ln 1 l h x h displaystyle frac Delta h h 1 lambda h frac x h frac Delta h h e ln 1 lambda h frac x h lambda e ln 1 lambda h frac x h nbsp and hence Fourier sums of continuum functions are readily mapped to umbral Fourier sums faithfully i e involving the same Fourier coefficients multiplying these umbral basis exponentials 16 This umbral exponential thus amounts to the exponential generating function of the Pochhammer symbols Thus for instance the Dirac delta function maps to its umbral correspondent the cardinal sine function d x sin p 2 1 x h p x h displaystyle delta x mapsto frac sin left frac pi 2 left 1 frac x h right right pi x h nbsp and so forth 17 Difference equations can often be solved with techniques very similar to those for solving differential equations The inverse operator of the forward difference operator so then the umbral integral is the indefinite sum or antidifference operator Rules for calculus of finite difference operators edit Analogous to rules for finding the derivative we have Constant rule If c is a constant then D c 0 displaystyle Delta c 0 nbsp Linearity if a and b are constants D a f b g a D f b D g displaystyle Delta a f b g a Delta f b Delta g nbsp All of the above rules apply equally well to any difference operator as to D including d and Product rule D f g f D g g D f D f D g f g f g g f f g displaystyle begin aligned Delta fg amp f Delta g g Delta f Delta f Delta g 4pt nabla fg amp f nabla g g nabla f nabla f nabla g end aligned nbsp Quotient rule f g det f g f g g det g g 1 1 displaystyle nabla left frac f g right left left det begin bmatrix nabla f amp nabla g f amp g end bmatrix right right left g cdot det begin bmatrix g amp nabla g 1 amp 1 end bmatrix right nbsp or f g g f f g g g g displaystyle nabla left frac f g right frac g nabla f f nabla g g cdot g nabla g nbsp Summation rules n a b D f n f b 1 f a n a b f n f b f a 1 displaystyle begin aligned sum n a b Delta f n amp f b 1 f a sum n a b nabla f n amp f b f a 1 end aligned nbsp See references 18 19 20 21 Generalizations editA generalized finite difference is usually defined as D h m f x k 0 N m k f x k h displaystyle Delta h mu f x sum k 0 N mu k f x kh nbsp where m m0 mN is its coefficient vector An infinite difference is a further generalization where the finite sum above is replaced by an infinite series Another way of generalization is making coefficients mk depend on point x mk mk x thus considering weighted finite difference Also one may make the step h depend on point x h h x Such generalizations are useful for constructing different modulus of continuity The generalized difference can be seen as the polynomial rings R Th It leads to difference algebras Difference operator generalizes to Mobius inversion over a partially ordered set As a convolution operator Via the formalism of incidence algebras difference operators and other Mobius inversion can be represented by convolution with a function on the poset called the Mobius function m for the difference operator m is the sequence 1 1 0 0 0 Multivariate finite differences editFinite differences can be considered in more than one variable They are analogous to partial derivatives in several variables Some partial derivative approximations are f x x y f x h y f x h y 2 h f y x y f x y k f x y k 2 k f x x x y f x h y 2 f x y f x h y h 2 f y y x y f x y k 2 f x y f x y k k 2 f x y x y f x h y k f x h y k f x h y k f x h y k 4 h k displaystyle begin aligned f x x y amp approx frac f x h y f x h y 2h f y x y amp approx frac f x y k f x y k 2k f xx x y amp approx frac f x h y 2f x y f x h y h 2 f yy x y amp approx frac f x y k 2f x y f x y k k 2 f xy x y amp approx frac f x h y k f x h y k f x h y k f x h y k 4hk end aligned nbsp Alternatively for applications in which the computation of f is the most costly step and both first and second derivatives must be computed a more efficient formula for the last case isf x y x y f x h y k f x h y f x y k 2 f x y f x h y f x y k f x h y k 2 h k displaystyle f xy x y approx frac f x h y k f x h y f x y k 2f x y f x h y f x y k f x h y k 2hk nbsp since the only values to compute that are not already needed for the previous four equations are f x h y k and f x h y k See also editDiscrete calculus Divided differences Finite difference time domain method FDTD Finite volume method FTCS scheme Gilbreath s conjecture Sheffer sequence Summation by parts Time scale calculus Upwind differencing scheme for convectionReferences edit a b c Paul Wilmott Sam Howison Jeff Dewynne 1995 The Mathematics of Financial Derivatives A Student Introduction Cambridge University Press p 137 ISBN 978 0 521 49789 3 a b c Peter Olver 2013 Introduction to Partial Differential Equations Springer Science amp Business Media p 182 ISBN 978 3 319 02099 0 a b c M Hanif Chaudhry 2007 Open Channel Flow Springer p 369 ISBN 978 0 387 68648 6 Jordan op cit p 1 and Milne Thomson p xxi Milne Thomson Louis Melville 2000 The Calculus of Finite Differences Chelsea Pub Co 2000 ISBN 978 0821821077 Finite differences of polynomials February 13 2018 Fraser Duncan C January 1 1909 On the Graphic Delineation of Interpolation Formulae Journal of the Institute of Actuaries 43 2 235 241 doi 10 1017 S002026810002494X Retrieved April 17 2017 notes Finite Difference Coefficients Calculator Burkard Polster Mathologer 2021 Why don t they teach Newton s calculus of What comes next on YouTube Newton Isaac 1687 Principia Book III Lemma V Case 1 Iaroslav V Blagouchine 2018 Three notes on Ser s and Hasse s representations for the zeta functions PDF Integers Electronic Journal of Combinatorial Number Theory 18A 1 45 arXiv 1606 02044 Konig Jurgen Hucht Fred 2021 Newton series expansion of bosonic operator functions SciPost Physics 10 1 007 arXiv 2008 11139 Bibcode 2021ScPP 10 7K doi 10 21468 SciPostPhys 10 1 007 S2CID 221293056 Richtmeyer D and Morton K W 1967 Difference Methods for Initial Value Problems 2nd ed Wiley New York Boole George 1872 A Treatise On The Calculus of Finite Differences 2nd ed Macmillan and Company On line Also Dover edition 1960 Jordan Charles 1939 1965 Calculus of Finite Differences Chelsea Publishing On line 1 Zachos C 2008 Umbral Deformations on Discrete Space Time International Journal of Modern Physics A 23 13 2005 2014 arXiv 0710 2306 Bibcode 2008IJMPA 23 2005Z doi 10 1142 S0217751X08040548 S2CID 16797959 Curtright T L Zachos C K 2013 Umbral Vade Mecum Frontiers in Physics 1 15 arXiv 1304 0429 Bibcode 2013FrP 1 15C doi 10 3389 fphy 2013 00015 S2CID 14106142 Levy H Lessman F 1992 Finite Difference Equations Dover ISBN 0 486 67260 3 Ames W F 1977 Numerical Methods for Partial Differential Equations New York NY Academic Press Section 1 6 ISBN 0 12 056760 1 Hildebrand F B 1968 Finite Difference Equations and Simulations Englewood Cliffs NJ Prentice Hall Section 2 2 Flajolet Philippe Sedgewick Robert 1995 Mellin transforms and asymptotics Finite differences and Rice s integrals PDF Theoretical Computer Science 144 1 2 101 124 doi 10 1016 0304 3975 94 00281 M Richardson C H 1954 An Introduction to the Calculus of Finite Differences Van Nostrand 1954 online copy Mickens R E 1991 Difference Equations Theory and Applications Chapman and Hall CRC ISBN 978 0442001360External links edit Finite difference calculus Encyclopedia of Mathematics EMS Press 2001 1994 Table of useful finite difference formula generated using Mathematica D Gleich 2005 Finite Calculus A Tutorial for Solving Nasty Sums Discrete Second Derivative from Unevenly Spaced Points Retrieved from https en wikipedia org w index php title Finite difference amp oldid 1220817436, wikipedia, wiki, book, books, library,

article

, read, download, free, free download, mp3, video, mp4, 3gp, jpg, jpeg, gif, png, picture, music, song, movie, book, game, games.