1 / 18

Basic Structure : Sets, Functions, Sequences, and Sums

Basic Structure : Sets, Functions, Sequences, and Sums. Sequences and Summations. 1. S: 2 4 6 8 10 …. Sequences. Sequences represent ordered lists of elements.

mercury
Download Presentation

Basic Structure : Sets, Functions, Sequences, and Sums

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Basic Structure : Sets, Functions, Sequences, and Sums Sequences and Summations 1

  2. S: 2 4 6 8 10 … Sequences • Sequences represent ordered listsof elements. • A sequence is defined as a function from a subset of N( either {0,1,2,…} or {1,2,3,…} to a set S. We use the notation an to denote the image of the integer n. We call an a term of the sequence. • Example: • subset of N: 1 2 3 4 5 …

  3. Sequences • We use the notation {an} to describe a sequence. • Important: Do not confuse this with the {} used in set notation. • It is convenient to describe a sequence with aformula. • For example, the sequence on the previous slide can be specified as {an}, where an = 2n.

  4. Sequences • Example: • Consider the sequence {an}, where an=1/n • The list of the term of this sequence , beginning with a1, namely a1,a2,… • Starts with 1,1/2,1/3,…

  5. The Formula Game What are the formulas that describe the following sequences a1, a2, a3, … ? 1, 3, 5, 7, 9, … an = 2n - 1 3, 5, 9, 17, 33, … an = 2n+ 1 0.25, 0.5, 0.75, 1, 1.25 … an = 0.25n 3, 9, 27, 81, … an = 3n

  6. Sequences • A geometric progression is a sequence of the form a, ar, ar2, ar3, …, arn, …. • Where the initial term a and the common ration r are real numbers • For example :

  7. Sequences • An arithmetic progression is a sequence of the form a, a+d, a+2d, a+3d, …, a+nd, …. • Where the initial term a and the common difference d are real numbers • For example :

  8. The Formula Game What are the formulas, and find what kind of progression ? 1, 1/2, 1/4, 1/8, 1/16,… an = 1/2n n=0,1,2,… geometric progression a= 1 r=1/2 1,3,5,7,…. an = 2n+1 n=0,1,2,… arithmetic progression a= 1 d=2

  9. Some useful Sequences

  10. Strings • Finite sequences are also called strings, denoted by a1a2a3…an. • The length of a string S is the number of terms that it consists of. • The empty stringcontains no terms at all. It has length zero.

  11. What does stand for? Summations • It represents the sum am + am+1 + am+2 + … + an. • The variable j is called the index of summation, running from its lower limitm to its upper limitn. We could as well have used any other letter to denote this index.

  12. We write it as . What is the value of ? What is the value of ? Summations It is 1 + 2 + 3 + 4 + 5 + 6 = 21. How can we express the sum of the first 1000 terms of the sequence {an} with an=n2 for n = 1, 2, 3, … ? It is 1 + 4 + 9 + 16 + 25 = 55.

  13. Summations • Sometimes it is useful to shift the index of summation in a sum, suppose: • We want the index to run from 0 to 4 rather than 1 to 5 • Let k = j – 1 , then j2 = (k+1)2

  14. Useful Summations formula • The following formula: When you have such a formula, the result of any summation can be calculated much more easily, for example:

  15. Geometric Series • If a and r are real numbers and r≠0, then If r≠1 (n+1)a If r=1 • Proof: • Let S = and continue…

  16. Useful Series • 1. • 2. • 3.

  17. Double Summations • Corresponding to nested loops in C or Java, there is also double (or triple etc.) summation: • Example:

  18. Summations • Example :Find • = • + • - • = • = n(n+1)(2n+1)/6 from formula 2 • = 100*101*201 – 49*50*99 = 338,350 – 40,425 • 6 6

More Related