[previous] [up] [next]     [index]
Next: Geometric Sequences and Series Up: Mathematical Examples Previous: Sequences and Series

Arithmetic Sequences and Series

In an arithmetic sequence

displaymath72382

each successor term tex2html_wrap_inline72384 is the result of adding a fixed constant to tex2html_wrap_inline72386 . Here is a concrete example, matched up with the natural numbers:

displaymath72388

Here the starting point is 3 and the constant is 5. From these two facts, called starting point and summand, respectively, all other terms in the sequence can be determined.


Exercises

Exercise 23.2.1

Develop the recursive function a-fives, which consumes a natural number and recursively determines the corresponding term in the above series. Solution

Exercise 23.2.2

Develop the non-recursive function a-fives-closed. It consumes a natural number and determines the corresponding term in the above series. A non-recursive function is sometimes called a closed formSolution

Exercise 23.2.3

Use series to determine the sum of the a-fives sequence for the bounds 3, 7, and 88. Can an infinite arithmetic series have a sum? Solution

Exercise 23.2.4

Develop the function seq-a-fives, which consumes a natural number n and creates the sequence of the first n terms according to a-fives or a-fives-closed. Hint: Use build-listSolution

Exercise 23.2.5

Develop arithmetic-series. The function consumes two numbers: start and s. Its result is a function that represents the arithmetic series whose starting point is start and whose summand is s. For example, (arithmetic-series 3 5) yields a-fives (or a-fives-closed). Similarly, (arithmetic-series 0 2) produces a function that represents the series of even numbers. Solution




PLT