Documentation/Calc Functions/SERIESUM

From The Document Foundation Wiki
Jump to navigation Jump to search
This page is a translated version of the page Documentation/Calc Functions/SERIESSUM and the translation is 2% complete.
Outdated translations are marked like this.
Other languages:
English • ‎Nederlands • ‎dansk • ‎español

Template:Documentation/Calc Functions/Func Page Links/da

Funktionsnavn:

SERIESUM

Kategori:

Matematisk

Resume:

Opsummerer de første argumenter i en potensrække.

[math]\displaystyle{ \sum_{n=0}^{\infty }a_nx^n }[/math]

x is the variable and an is the coefficient of the nth term in the series.

Syntaks:

SERIESUM(X; N; M; Coefficients)

Returnerer:

Returnerer et reelt tal, som er summen af de første argumenter i den givne potensrække.

Argumenter:

X er et reelt tal eller en reference til den celle, der indeholder det tal, som er input-værdien for potensrækken.

N er et reelt tal eller en reference til den celle, der indeholder det tal, der er den første potens.

M er det reelle tal eller en reference til en celle, som indeholder det tal, som er forøgelsen af N.

Koefficienter er et reelt tal eller en reference til den celle, der indeholder det tal, som er en række af koefficienter. For hver koefficient udvides potensrækken med en sektion.

  • A simple reference to a cell range containing real numbers (for example, A1:B9).
  • The name of a named range, comprising cells containing real numbers.
  • The name of a database range, comprising cells containing real numbers.
  • An inline array of real numbers (for example, {1.2, 3.4, 5.6, 7.8}).
  • Denne funktion bruges hovedsagelig til alle heltals-argumenter.
  • Hvis X er negativ, så skal N og M være integraler; eller returnerer funktionen en værdifejl.
  • Hvis X er 0, så kan N ikke være 0, eller returnerer funktionen en værdifejl (#VALUE!).

Yderligere oplysninger:

  • A power series may be represented as:

[math]\displaystyle{ \text{f}(x)=a_{0}x^{n}+a_{1}x^{n+m}+a_{2}x^{n+2m}+a_{3}x^{n+3m}+... }[/math]

where:
  • x is the variable.
  • an is the coefficient of the nth term in the series.
  • m is the increment applied to the power for each term.
  • For example, the series expansion of ex is a common power series, with the formula:

[math]\displaystyle{ \text {e}^{x}=\sum_{n=0}^{\infty }\frac{x^n}{n!}=1+\frac{x}{1!}+\frac{x^2}{2!}+\frac{x^3}{3!}+\frac{x^4}{4!}+... }[/math]

To find the (approximate) value of ex, we could use SERIESUM and set the arguments as follows:
  • Set X to the power of e that you require.
  • Set N to 0 (the first term in the series is a constant).
  • Set M to 1 (the power of x is incremented by 1 at each term in the series).
  • Set Coefficients to the values 1, [math]\displaystyle{ \frac{1}{1!} }[/math], [math]\displaystyle{ \frac{1}{2!} }[/math], [math]\displaystyle{ \frac{1}{3!} }[/math], and [math]\displaystyle{ \frac{1}{4!} }[/math]. Using five coefficients will cause SERIESUM to calculate the first five terms of the power series.
See the #Examples: section below for more examples of this power series.
  • Another example of a common power series is that for the trigonometric sine, with the formula:

[math]\displaystyle{ \text{sin}(x)=\sum_{n=0}^{\infty }(-1)^n \frac{x^{2n+1}}{(2n+1)!}=x-\frac{x^3}{3!}+\frac{x^5}{5!}-\frac{x^7}{7!}+... }[/math]

To find the (approximate) value of sin(x), we could use SERIESUM and set the arguments as follows:
  • Set X to the angle in radians for which you wish to calculate the sine.
  • Set N to 1 (the first term in the series is an x1 term).
  • Set M to 2 (the power of x is incremented by 2 at each term in the series).
  • Set Coefficients to the values 1, [math]\displaystyle{ -\frac{1}{3!} }[/math], [math]\displaystyle{ \frac{1}{5!} }[/math], and [math]\displaystyle{ -\frac{1}{7!} }[/math]. Using four coefficients will cause SERIESUM to calculate the first four terms of the power series.
See the #Examples: section below for more examples of this power series.

Eksempler:

Basic examples

Template:Calc-Formula/da Template:Calc-Description/da Template:Calc-Returns/da
=SERIESUM(2; 0; 1; {1; 2; 3}) Here the function calculates [math]\displaystyle{ 1+2x+3x^2 }[/math], where x=2. 17
=SERIESUM(0,5; 1; 2; {1; 1; 1}) Here the function calculates [math]\displaystyle{ x+x^3+x^5 }[/math], where x=0.5. 0,65625

Calculate approximate value of ex

Using the description of the ex power series given above, set up data in your spreadsheet in accordance with the following table.

A B
1 X 1
2 N 0
3 M 1
4 Coefficient[0] 1
5 Coefficient[1] 1
6 Coefficient[2] 0,5
7 Coefficient[3] 0,166666666666667
8 Coefficient[4] 0,041666666666667
Template:Calc-Formula/da Template:Calc-Description/da Template:Calc-Returns/da
=SERIESUM(B1; B2; B3; B4:B8) where cells B1 to B8 contain the numbers listed above. Here the function calculates an approximate value for e. Using more terms of the power series would give a closer approximation to the actual value (2.7182818284…). 2,70833333333333
=SERIESUM(0.5; B2; B3; B4:B8) where cells B2 to B8 contain the numbers listed above. Here the function calculates an approximate value for the square root of e. Using more terms of the power series would give a closer approximation to the actual value (1.6487212707…). 1,6484375

Calculate approximate value of sin(x)

Using the description of the sin(x) power series given above, set up data in your spreadsheet in accordance with the following table.

A B
1 X 1,0471975511966
2 N 1
3 M 2
4 Coefficient[0] 1
5 Coefficient[1] -0,166666666666667
6 Coefficient[2] 0,008333333333333
7 Coefficient[3] -0,000198412698413
Template:Calc-Formula/da Template:Calc-Description/da Template:Calc-Returns/da
=SERIESUM(B1; B2; B3; B4:B7) where cells B1 to B7 contain the numbers listed above. Here the function calculates an approximate value for sin(π/3). Using more terms of the power series would give a closer approximation to the actual value (0.866025403784439…). 0,866021271656373
=SERIESUM(0.5; B2; B3; B4:B7) where cells B2 to B7 contain the numbers listed above. Here the function calculates an approximate value for sin(0.5). Using more terms of the power series would give a closer approximation to the actual value (0.479425538604203…). 0,479425533234127

Beslægtede LibreOffice-funktioner:

Ingen

ODF standard:

Tilsvarende Excel-funktioner:

SERIESUM