Set
We begin our formal development with basic notions of set theory. Our most primitive notion is that of a set. This notion is so fundamental that we do not attempt to give a precise definition. We think of a set as a collection of distinct objects with a precise description that provides a way of deciding (in principle) whether a given object is in it.
The objects in a set are its elements or members. When is an element of , we write and say ” belongs to ”. When is not in , we write . If every element of belongs to , then is a subset of , and contains ; we write or .
By convention, we use the special characters , , , to name the sets of natural numbers, integers, rational numbers, and real numbers, respectively. Each set in this list is contained in the next, so we write .
Sets Could be expressed in different ways. For sets with limited and few elements, we simply list all the elements in a pair of bracket, such as . For sets with more elements, we can also define a set by description: . For example:
The rational number set could be expressed as:
Sets and are equal, written , if they have the same elements. The empty set, written , is the unique set with no elements. A proper subset of a set is a subset of that is not itself. The power set of a set is the set of all subsets of . In other words, the complement of includes everything that is not in .
Intersection, union and exclusion.
-
the intersection of and ,
-
the union of and ,
-
the set difference, but not ,
The set is sometimes called the “relative complement” of in .
When , sets and are said to be disjoint.
The complement of a set , often denoted as , or , is defined with respect to a universal set , which contains all objects under consideration. The complement consists of all elements in that are not in . Formally, if we have a universal set and a subset , then the complement of is given by:
Intervals. When with , the closed interval is the set . The open interval is the set .
Properties of Sets with Proofs
Commutative Laws
Union: Proof: The union of sets and includes all elements that are in , in , or in both. Since the notion of “being in” does not depend on the order, and represent the same set.
Intersection:
Proof: The intersection of sets and includes all elements that are both in and in . The order of and does not affect the elements that are shared between them, hence the equality.
Associative Laws
Union: Proof: When we take the union of sets, we combine their elements. Grouping does not affect the outcome of the union, thus the union operation is associative.
Intersection: Proof: The intersection operation finds common elements. The grouping of sets does not affect the commonality of elements, so the intersection operation is associative.
Distributive Laws
Intersection distributes over union: Proof: An element in is in and either or . This is the same as the element being in both and , or in both and .
Union distributes over intersection: Proof: An element in is in , in both and , or in all. This is equivalent to the element being in or , and in or .
De Morgan’s Laws
Complement of the union: Proof: An element not in is neither in nor in , which means it is in both and .
Complement of the intersection: Proof: An element not in is not in both and , which means it is either in or in .
Properties of Complements
Union with complement: Proof: The set together with all elements not in constitutes the entire universe .
Intersection with complement: Proof: No element can be both in set and not in set at the same time, hence the intersection is the empty set.
If and are sets, we say is a subset of if every element of is also an element of . This is denoted as
Note that for every set, it is a subset to itself.
If , then is a proper subset of .
For instance, consider the set and the set . In this case, , because every element of is in , but contains an additional element that is not in .
The empty set is a unique set that contains no elements. It is denoted as . This set is important in set theory because it serves as the identity element for the union operation and has properties that are fundamental to the construction of other sets. For example, every set, including the empty set itself, contains the empty set as a subset:
for any set . Furthermore, the intersection of any set with the empty set is the empty set itself:
This highlights the empty set’s role in set operations.
If is any set, the power set of , // the set of all subsets of
For example, if then
The number of elements in a set is called the cardinality of and denoted by . When this is a finite number, then , and when , we’ll say that is an -set.
Each element of is in exactly one of the sets , , and . More generally,
subsets of form a partition of means every element of belongs to exactly one of the sets .
The sets , and form a partition of . In general, because each is a subset of . because each element of is in some subset . Therefore, .
The subsets in a partition are mutually disjoint; that is, any two are disjoint sets.
If , because no element of belongs to more than one .
When forms a partition of , then
For any pair of sets,
and when and are disjoint,
Furthermore, we always have
The Cartesian product of sets and , named for René Descartes (1596—1650), is
where denotes an ordered pair of objects; there is a first entry and a second entry in each ordered pair. Parentheses indicate that order matters.
If and , then
Exercises
Indicate whether each statement is true or false:
What is ?
Let and . Evaluate each of the following expressions:
Is a partition of ? Justify your answer.
Consider the set . Construct 3 different partitions of this set.
Hint: Each partition satisfies the definition: the subsets are non-empty, they cover the entire original set, and they are mutually exclusive (no element is repeated in the subsets of any given partition).
Partition 1:
Partition 2:
Partition 3:
Proof that
To prove the lemma, we will show that the left-hand side (LHS) is a subset of the right-hand side (RHS) and vice versa.
Using De Morgan’s laws:
Distributing the intersection over the union: \begin{aligned} (A \cap B) \cap (\sim A \cup \sim C) &= (A \cap B \cap \sim A) \cup (A \cap B \cap \sim C) \\ &= \varnothing \cup (A \cap B \cap \sim C) \quad \text{(since \( A \cap \sim A = \varnothing ))} \\ &= A \cap B \cap \sim C \end{aligned}
Simplifying further: \begin{aligned} A \cap B \cap \sim C &= A \cap (B \cap \sim C) \\ &= A \cap (B - C) \quad \text{(since \( B \cap \sim C = B - C ))} \end{aligned}
The original statement is proven, as both the LHS and RHS equal .
Prove that .
We start by applying De Morgan’s laws:
Next, we distribute the intersection over the union:
Hence, the original statement is proven.
Define the set , and let .
Prove that .
Proof:
Let , then , so ;
Now let , then ,
so ; thus, by definition, .
Function: a perspective from Set Theory
This section discusses function from a perspective of set. We clarify this by the relation between sets.
Function and Operation on Function
Let and be nonempty sets. A function from to is an assignment of exactly one element of to each element of . We write if is the unique element of assigned by the function to the element of . If is a function from to , we write .
Mapping and transformation are equivalent to function in some context. If is a function from to , we say that is the domain of and is the codomain of . If , we say that is the image of and is a preimage of . The range, or image, of is the set of all images of elements of . Also, if is a function from to , we say that maps to .
When we say that two functions are equal, they share the same domain, codomain, and the mapping from the domain to the same codomain.
Think about this problem:
Is equal to ?
Even with limited algebraic background, one can see that although may be written using the same symbol , it defines a different function from the identity function . The first has domain , while the latter has domain , so their domains and codomains differ.
Here is an example that helps to distinguish codomain and domain:
Let assign the square of an integer to this integer. Then, , where the domain of is the set of all integers, the codomain of is the set of all integers, and the range of is the set of all integers that are perfect squares, namely, .
Let and be functions from to . Then and are also functions from to defined for all by
Let and be functions from to such that and . What are the functions and ?
Sometimes we may use the output of one function as the input of another function, we call that Composition of Function
Let and be two functions. The composition of and is the function defined by for all . The function is read as “g composed with f” or “g of f”.
Elementary Functions and More on Cartesian Product
As a new undergrad, most of the functions that we have seen so far are actually categorized under only The Basic Elementary Functions.
The basic elementary functions are a set of fundamental functions that are widely used in various branches of mathematics and science. These functions can be defined as follows:
- Power Functions:
-
, where is a positive integer.
-
, where is a positive integer. This is the -th root of .
-
, where is any real number.
-
Exponential Function: , where is the base of the natural logarithm.
-
Logarithmic Functions:
-
, the logarithm of with base , where and .
-
, the natural logarithm of , which is the logarithm with base .
-
Trigonometric Functions: , , , , , .
-
Inverse Trigonometric Functions: , , , , , .
Function Expression
Power functions , , Exponential function Logarithmic functions , Trigonometric functions , , , , , Inverse trigonometric functions , , , , ,
: Basic Elementary Functions
All these functions have on thing in common: they are all defined as . Now we can consider functions with more variables, or we just say, the output of function is affected by more than one variable. Let’s look at a simple example.
The function is a function with two independent variables. How can we write a reflection, or mapping in notation?
Solution: It could be a little complex to consider two variables in the same time, and for beginners, it is pretty hard to imagine how the graph of function looks like. Now we introduce a new method called Function Slicing.
Definition: Let be an -variable real-valued function. A function slice of is a function obtained by fixing one or more variables to specific values, thus reducing the number of variables in the function.
Formally, let be a vector of fixed values, where . Let be a subset of indices. The function slice of with respect to and is the function defined by:
where
Remark: In other words, function slicing is the process of fixing some variables of a multivariate function to specific values, thus creating a new function with fewer variables. This technique is useful for simplifying and visualizing the behavior of multivariate functions under specific conditions.
We apply this technique straightaway in this example, since we want to make this function more easy to analyze, we can fix to 0. So we can reduce it to a univariate function. With this as a prerequisite, the bivariate function is equivalent to a basic linear function with gradient 1. For , we can know without any doubt that it is defined by . But how does this help us to find out how to express of mapping of ? The mapping is always from one set to the other set, so for multivariable functions, the mapping must also be from one set to another set. Obviously, the image is , and the tricky part is the preimage. Let’s recap on what we have covered in the set theory. We have actually already know how to deal with multiple elements from one set, like in this case, we have . How can we describe a set consisted of and ? The fact is that we can take them as Cartesian product. We know that the Cartesian product of two number set will produce a set of ordered pairs with two elements, so we have infinitely many pairs of , where , which can be denoted by , or by convention. Therefore, we have for . The complete graph of this function is shown below.
Figure pending: f(x, y) = x + y
Let’s see how the bivariate function is related to the univariate functions and .
When we fix the value of , say , the function becomes a univariate function in : . This is essentially a vertical translation of the function by a distance of . In the 3D graph, this is represented by a line parallel to the -plane. Similarly, when we fix the value of , say , the function becomes a univariate function in : . This is a vertical translation of the function by a distance of . In the 3D graph, this is represented by a line parallel to the -plane. When , , which is the graph of the function . In the 3D graph, this is a line on the -plane. When , , which is the graph of the function . In the 3D graph, this is also a line on the -plane. The graphs of the functions and intersect on the -plane at the point , which corresponds to the point in the 3D graph. You can imagine that the graph of the function is composed of countless lines parallel to the -plane and -plane, which correspond to the translations of and respectively. These lines form a plane in the 3D space.
This plane can be seen as the result of translating along the -axis, or translating along the -axis. The combination of these two univariate functions in the 3D space forms the graph of the bivariate function .
Do not mix it up with function addition and multiplication earlier, because for the cases earlier, all functions are with respect to , the same variable, while in this case a new variable is introduced.
We have worked out this example, however, here I’d like to give some extra knowledge on Cartesian product, especially its geometrical meaning. We just mentioned that two number set will produce a set of ordered pairs with two elements, and in this case, we denote the set formed by Cartesian product of the same real number set as . Nevertheless, ordered pairs’ elements are not always in pairs. We can even define an ordered pair of one single real number , where , or even three or more elements. We first examine and , it is clear that is just the set of real number that is already defined, while the ordered pair represents some . Now we introduce another to form ordered pair , and we have concluded that . The process of developing to , is just creating a Cartesian product of real number set to itself. To visualize this process, we need to find a suitable carrier for real number. We know that a real number could be infinitely huge or infinitely small, as there is no biggest or smallest real number (even though we haven’t proven this, we just take it as common sense). We take some real number as example. We can see that this interval is actually defined by a line on the Cartesian plane (or the Cartesian Coordinates). Since real number are infinite, so the whole set ordered pair , are defined in a line extending to both left and right-hand-side of the plane, giving us a whole line that extents forever.
Figure pending: Visualization of and
Now we consider , where both elements are from , so for the Cartesian products, we will get all possible combination of any . In this way, we can get a plane, just as shown in the graph. This is why call this system “Cartesian Coordinate”. Naturally, we can also conclude that is a solid cubic in the 3D space.
Figure pending: Visualization of
But what about functions whose preimage are above ? Sadly, there is no easy way to plot a function that are in 4D space, even though we can still use many techniques to analyze these high dimension functions, including function slicing. We will discuss further in linear algebra and multivariable calculus.
Just now, we have somewhat shown another law about dimension or graphical representation of function.
For any n-variable function with variables , for function , (), whose mapping is . we need dimensions to plot a complete graph for the function.
Additionally, is defined as The n-dimensional Euclidean Space.
The n-dimensional Euclidean Space can be defined as the set of all real-valued functions defined on the index set .
where each function assigns a real number to each element of the index set . We can represent these functions as n-tuples or vectors:
where for . Thus, each point in can be identified with an n-tuple of real numbers .
The set is equipped with various algebraic and geometric structures, such as vector addition, scalar multiplication, and an inner product, which make it a real vector space of dimension . Don’t worry if you are confused by this, we will explore this topic further in linear algebra and other topics.
Partial and Total Function
Now we will introduce some ways to categorize functions. Earlier, we have discussed many functions where , but functions cannot always have a domain in a complete set. So we first introduce the idea of partial function.
A partial function from a set to a set is a function that satisfies the following conditions:
-
The domain of , denoted by , is a subset of , i.e., .
-
For each , there is a unique such that .
In other words, a partial function is a function that may not be defined for all elements of its source set. Partial functions allow some input values to have no corresponding output values.
Consider the function defined as: This function is a partial function because it is not defined for . The domain of is the set of all real numbers except zero, i.e., .
By analogy, we can define total function as follows.
A total function from a set to a set is a function that satisfies the following conditions:
-
The domain of , denoted by , is equal to , i.e., .
-
For each , there is a unique such that .
In other words, a total function is a function that is defined for all elements of its source set. Every input value of a total function has a unique corresponding output value.
Consider the function defined as:
This function is a total function because it is defined for all real numbers. The domain of is the entire set of real numbers, i.e., . For any input value , the function assigns the unique output value .
A total function is a special case of a partial function where the domain is equal to the source set.
Another thing that worth discussing is that, earlier, we introduced function slicing that reduce the number of variable of a function. Function slicing has much to do with partial function.
Function slicing is a technique that involves restricting the domain of a function to a specific subset. Given a function and a subset , the slice of over , denoted by , is defined as: The function has the same output values as for inputs in , but it is undefined for inputs not in .
If the original function is a total function, then the slice is a partial function, unless . In the case where , the slice is the same as the original function and remains a total function.
On the other hand, if the original function is already a partial function, then the slice is also a partial function, regardless of the choice of .
Injective, Surjective, and Bijective Function
We have known that functions are actually reflection from one set to the other set. We will look into several special mapping.
A function is called injective (or one-to-one) if every element of the codomain is mapped by at most one element of the domain . For example, the function from to is injective because each value of is produced by exactly one value of .
A function is surjective (or onto) if every element of the codomain is mapped by at least one element of the domain . For instance, the function from to is surjective because every value in is the sine of some real number .
A function is bijective if it is both injective and surjective, which means there is a perfect “pairing” between the sets: every element of is paired with a unique element of , and every element of is paired with a unique element of . An example of a bijective function is the identity function from to .
Figure pending: Examples of Special Mappings
Examine Figure 1.4, where one example of each type of function is shown. Fundamentally, when we define these functions, only two properties are involved:
-
A: It the mapping retrievable? (for every value in the image, we can find where it is from without any confusion.
-
B: Is the mapping is full comparing to the preimage?(Whether every value in the preimage has a mapping to the image)
If A is satisfied, we call it injective function.
If B is satisfied, we call it surjective function.
If both A and B are satisfied, we say the function is bijective.
Using , , and to denote the set of injective, surjective, and bijective function respectively, it is therefore that :
Which means that if a function is injective and surjective in the same time, it is bijective.
Additionally, we need to distinguish bijective function with well-defined function.
A function is said to be well-defined if for every element in the domain , there is a unique element in the codomain such that . This means that the function assigns exactly one output to each input. A well-defined function does not assign multiple outputs to a single input, and every input for which the function is defined has an output.
While all bijective functions are well-defined, not all well-defined functions are bijective. Being well-defined is a minimal requirement for being a function at all. A well-defined function may fail to be bijective if it is not injective, allowing different inputs to have the same output, or if it is not surjective, meaning that some elements in the codomain do not correspond to any input from the domain. Thus, while bijectivity implies a specific one-to-one correspondence between the entire domain and codomain, well-definedness merely ensures that the function is consistently defined across its domain.
And these will be all we need to know about function for now, since the rest of the properties will be discussed in single-variable calculus. This section aims only introduce the idea of injectivity, surjectivity, and bijectivity.
Exercises
Let be a function. Which of the following correctly gives an example of an element from its domain and an element from its codomain?
-
is an element of the domain and is an element of the codomain.
-
is an element of the domain and is an element of the codomain.
-
is an element of the domain and is an element of the codomain.
-
is an element of the domain and is an element of the codomain.
Let’s break down the domain and codomain of the function :
-
The domain of is , which means it consists of ordered pairs , where is either or , and is a subset of the set of integers .
-
The codomain of is , which is the set of natural numbers.
Now, let’s examine each choice:
-
is not an element of the domain because , and is not a subset of . is a subset of , but not an element of .
-
is an element of , but not an element of . is a subset of , but not an element of .
-
is not an element of because it is not an ordered pair. is an element of .
-
is an element of because and . is an element of .
Therefore, the correct answer is 4.
Determine whether the rules below define functions from to .
You only need to check whether the domain covers the whole .
Determine the images of the functions defined as follows:
-
.
-
.
We analyze the function :
-
This function is defined for all .
-
For , .
-
For , is always positive.
-
As approaches infinity, approaches 1.
Thus, the image of is .
We analyze the function :
-
This function is defined for all .
-
For , as increases, approaches 1.
-
For , as decreases, approaches -1.
Thus, the image of is .
Let be the function defined by where is the set of positive integers and is the greatest common divisor of and . Is this a one-to-one (bijective) function? What is the image of the function?
Take and . Both and are elements of the domain .
Now, let’s calculate and :
As we can see, , even though . This demonstrates that is not one-to-one, as there exist distinct elements in the domain that map to the same element in the codomain.
Now, let’s determine the image of . The image of a function is the set of all elements in the codomain that are mapped to by at least one element in the domain.
Observe that for any :
, because the greatest common divisor of two positive integers is always a positive integer. , because is a positive integer. Therefore, .
This means that the smallest possible value of is 2, and there is no upper limit on the value of as can be arbitrarily large.
Thus, the image of is the set , which is the set of all integers greater than or equal to 2.
In conclusion, is not a one-to-one function, and its image is .
Considering and . How to define a total function ? How many are there? List all the total functions. Also try to find the way to calculate the number of total functions obtained by and with respect to .
To obtain a total function, we must make sure that the preimage is exactly , so we can pick which ever combinations of members of , so we have , , , , , , , . There are 8 total functions from to . The number of total functions can be calculated using the formula , which in this case is .
Let and be the following functions.\ defined by .
defined by . Discuss the existence of . If any of them exists, give a example.
1. : exists for all because the codomain of is the same as its domain. This means that for any , , so is well-defined.
Example: Let . Then:
2. : does not exist because the codomain of is , which is not a subset of the domain of , . Therefore, is not a valid input for .
3. : exists for all because the codomain of is , which is the domain of . This means that for any , , so is well-defined.
Example: Let . Then:
4. : does not exist because the codomain of is , which is not a subset of the domain of , . Therefore, is not a valid input for .
In summary, and exist for all , while and do not exist.
We have discussed to in this section. Try to postulate that whether exists? If it exists, can it be defined by Cartesian Product. Try to prove your conclusion by deduction, and explain how can we visualize it, and is it necessary to visualize it in Cartesian Coordinate system.
Remark: Deduction is also known as “inverse induction”.
First, let’s recall the definition of the Cartesian product for a finite collection of sets :
Now, consider the case where . We have an empty collection of sets, denoted by . The Cartesian product of an empty collection of sets is defined as:
This is a singleton set containing the empty tuple . The empty tuple is a tuple with no components and is denoted by .
By definition, is the Cartesian product of copies of :
When , we have:
Therefore, exists and is equal to the singleton set containing the empty tuple .
Visualization: As mentioned earlier, visualizing is not necessary, as it is a singleton set containing only the empty tuple. However, if we were to visualize it, it would be represented by a single point in a 0-dimensional space.
In the Cartesian coordinate system, is represented by a line, by a plane, and by a 3-dimensional space. As the dimension increases, the visualization becomes more complex. For , there are no axes to represent it in the Cartesian coordinate system, as it is a 0-dimensional space.
Conclusion: exists and can be defined as the Cartesian product of zero copies of , resulting in a singleton set containing the empty tuple . While it is not necessary to visualize in the Cartesian coordinate system, it can be thought of as a single point in a 0-dimensional space.
If and are bijections (both injections and surjections), prove that is also a bijection.
We aim to prove that the composition of two bijective functions is also a bijection.
Let and be bijections. We need to show that is both an injection and a surjection.
Assume and . Since is an injection, if then for any , which implies . Furthermore, since is also an injection, . Hence, is an injection.
Let . Since is a surjection, there exists such that . Similarly, since is a surjection, there exists such that . Therefore, for , there exists such that . Thus, is a surjection.
Combining both, we conclude that is a bijection.
is the inverse proposition of last statement true, if so prove it.
We can use proof by contradiction here.\ Suppose that and so that . We will prove that if is one-to-one, then is also one-to-one, so not only is the answer to the question “yes”. Suppose that were not one-to-one. By definition this means that there are distinct elements and in such that Then certainly , which is the same statement as By definition this means that is not one-to-one, and our proof is complete.
Let be a function with domain and for any subset of . Suppose and are subsets of .
-
Prove that .
-
Give an example where equality does not hold in part (a).
Below is solution for a).
Proof: Take any element . By definition of , there exists an such that . Since is in the union , must be in either or . If , then . Similarly, if , then . Therefore, in either case, , proving that .
Below is an example that the inequality holds. The equality does not hold when the function f is not injective, meaning that it maps distinct elements in the domain to the same element in the codomain.
Determine whether is onto if
-
This is clearly onto, since for every integer .
-
This is not onto, since, for example, is not in the range. To see this, if , then and must have the same parity (both even or both odd). In either case, both and are then even, so this expression is divisible by 4 and hence cannot equal 2.
-
This is clearly onto, since for every integer .
-
This is onto. To achieve negative values we set , and to achieve nonnegative values we set .
-
This is not onto, for the same reason as in part (b). In fact, the range here is clearly a subset of the range in that part.
Let be a function from the set to the set . Let and be subsets of . Show that
-
.
-
.
- We need to show two inclusions:
-
Suppose . This implies for some . Thus, or , and consequently, or . Hence, .
-
Conversely, assume . Then either or , which means there exists an or such that . Thus, and .
This shows that , completing the proof.
- To prove the subset relation:
- Let . Then for some . This means and , hence and . Therefore, .
This establishes that , as desired.
Show that a partial function from to can be viewed as a function from to , where is not an element of and
To show that a partial function from to can be extended to a total function from to , we need to verify that for every element in , the function assigns exactly one element in .
Consider any element in . There are two possibilities:
-
If is in the domain of definition of , then by the definition of , there is an associated element in . In this case, we define . Since is an element of , and is a subset of , is an element of .
-
If is not in the domain of , which means is undefined at , we assign a special element that is not in to . Specifically, we define . By the choice of , we ensure that is in .
In both cases, is a well-defined element of . Furthermore, the definition of is such that each in is associated with exactly one element in , making a total function. Therefore, satisfies the definition of a function and extends to the entire set by assigning where is undefined.
Thus, every partial function can indeed be considered a total function with the addition of a special element to handle the undefined cases in .
The extension of a partial function to a total function relates closely to the concept of function slicing presented in Proposition 2.2 of the book. Function slicing involves restricting the domain of a function to a subset , whereas extending a partial function involves expanding the codomain to include an element that handles undefined cases.
In essence, slicing a total function can create a partial function which is only defined for inputs in subset . Extending a partial function to can be viewed as reversing this process, by adding an element to the codomain for the undefined cases, thereby making it total.
The slice has the same output values as for inputs in , and is undefined for inputs not in . Similarly, maintains the output values of for inputs where is defined and assigns the value for inputs where is not defined. Both processes --- slicing and extending --- are techniques to manipulate the domain and codomain of functions to achieve desired properties of partiality or totality.
Summation
Before we move on to the most important part of this chapter, sequence, we use this section to introduce a prerequisite for studying its properties. We introduce the Sigma sign.
In earlier chapters, we have seen exercises such as finding the expression of the sum of the first nth positive integer: From now on, we will use the sigma notation to deal with the summation of numbers. Such as:
Sigma Notation
Where is quite similar to iterator, or sometimes we also call counter in programming languages, and refers to the condition of termination. The expression right after the sigma sign is called summand.
Actually, this is not the only way to express summation, it is also equivalent to:
Also, like what we do for set, we can also write sigma notation using description, such as:
is odd
Properties and Techniques of Sigma Notation
This part of the section shows how we can handle summation expressions. One of the greatest convenience of sigma notation is that every expression is adjustable, we can change the variable as what we prefer as in the following example.
This technique has a significant effect to some mathematical proofs. Another points to keep in mind is that: always make the expression simple in terms of upper and lower boundary.
Examine this expression: The sum when k equals to 0, 1, and is 0. In this case we cannot say it is a good expression, as what we want is the sum it self, while 0 does not matter for us. Therefore, we just fine-tune it to: This makes it concise and clear.
Manipulation of Sigma Notation
For a set , the following summation properties hold. Let be a constant, and , be sequences indexed by :
The proof is attached below.
Proof of Constant Factor Law:
Let be a constant and be a sequence indexed by a finite set . We want to show that .
By the definition of summation and the distributive property of multiplication over addition, we have: This concludes the proof of the constant factor law.
Proof of Summation of Sums Law:
Let and be sequences indexed by a finite set . We want to show that .
By the definition of summation and the associative and commutative properties of addition, we have: \begin{split} \sum_{k \in K} (a_k + b_k) &= (a_1 + b_1) + (a_2 + b_2) + \ldots + (a_n + b_n) \\ &= (a_1 + a_2 + \ldots + a_n) + (b_1 + b_2 + \ldots + b_n) \\ &= \sum_{k \in K} a_k + \sum_{k \in K} b_k \end{split} This concludes the proof of the summation of sums law.
Proof of Permutation Invariance Law:
Let be a sequence indexed by a finite set . Let be a bijection, which means permutes the indices. We want to show that .
By the definition of summation and the fact that addition is commutative (the order does not matter), we have: This concludes the proof of the permutation invariance law.
Multiple Sums
Sometimes we use sigma notation with multiple variables, just like what we can do to write loops in programming languages.
In the context of summation, we often encounter a situation where a sum is taken over a set of pairs. Specifically, let be a property involving the indices and , and be elements corresponding to these indices. The summation over all pairs satisfying property is equivalent to summing over all indices separately:
This notation serves as a shorthand for expressing the sum over a subset of indices determined by the property . There are also cases where we must use two sigma notation in the same time.
When considering a double sum over a set of pairs, we often come across the following identity:
where is an Iverson bracket which equals 1 if the property holds for the pair and 0 otherwise.
By interchanging the order of summation, we observe that:
This property allows us to switch the order of summation without changing the result, which can be particularly useful in various mathematical analyzes.
Double summation could also be used to simplify a given summation. Considering the expression at the beginning of this section:
To explicit: In the situation where we perform the same range of summation over each variable, the first two lines’ triple summation is: Utilizing the distributive property to combine the summation operations into one involving , since and each for are independent, yields (as in the third line):
Consider a double sum over two independent indices, if the indices are independent, the summation of the product can be split into the product of two summations. For instance, the sum of products of and over in and in can be expressed as: . This can be generalized to an expression:
which is known as the general distributive law.
If you are an agile reader, you must have noticed that this expression is a kind of representation of Cartesian sets in algebra. The general distributive law allows the sum over a function of elements from the Cartesian product of two sets to be expressed as the product of sums over each set if the function is separable into independent factors.
Exercises
Express the triple sum as a three-fold summation (with three ‘s),
-
summing first on , then , then ;
-
summing first on , then , then .
Also write your triple sums out in full without the -notation, using parentheses to show what is being added together first.
Solution:
(a)
(b)
Demonstrate your understanding of -notation by writing out the sums in full. (Watch out---the second sum is a bit tricky.)
Solution:
The first sum is:
The second sum, , therefore:
The general rule for summation by parts is equivalent to
Prove this formula by using the distributive, associative, and commutative laws.
Hint: Use Associative Law to LHS, try to make the indices of the two sums as similar as possible.
Is the following expression correct or not? Give your reason.
Solution:
Consider the expression given by: and its expansion into a double sum:
It is claimed that this is equal to:
However, this claim overlooks the fact that the double sum includes terms where , which are not necessarily equal to 1. Only when does the term simplify to 1, contributing to the count of .
Hence, the proper expansion of the double sum should be written as: where the first sum on the right-hand side counts the instances where , and the second sum accounts for the instances where .
The claim would only be true if all are equal, which is a special case, not the general case. In the general case, the expression evaluates to something different from due to the presence of terms where .
Therefore, the original statement is incorrect unless the condition that all are equal is specified.
Consider the following double summation where . Is there anything special about these expressions? Manage to find all the equivalent expressions of the sum of squares in sigma notation. Also consider, if the order of summand increases to infinity, whether these properties still exist?
Solutions:
For
-
It could be seen that the sums are actually symmetrical. When , .
-
If you list several of the first nth term, the term with indices will be canceled by term, since
We can visualize it in a matrix with .
Figure pending: Visualization of
With this image, we expand it until n; we can still cancel all elements symmetrical by the diagonal on by one. As the sum on the diagonal is 0, we conclude that
Now consider the summation of squares. still holds for , but what about the symmetrical pairs and ? We can figure it out by analysis by expanding the square of sum. By associative property of summation, we rearrange it as: When , each pair of and . The sum of symmetric pair is Rearrange it as: Still, as the sum of terms where is 0. We can ignore the diagonal. Hence, we have pairs of . This could be written as: Notice that, due to the diagonal symmetry of the summation as illustrated in the graph. We are adding the same term twice. Hence, we have: We can further simplify it by rule out the terms where , as the summand is 0 in those cases. We rewrite the sum as: or in single summation, we have:
For , the symmetric property of summand still exists. However we cannot prove it for now, as we need to use polynomial theorem to be introduced in Combinatorics.
Sequence
If everything so far is not a problem for you, congratulations, because you have known everything you need to know sequence. Sequence is an important concept that will be used throughout your journey of learning math. A Sequence is defined as:
A sequence is a function , where is the set of natural numbers and is the set of real numbers. The value is the -th term of the sequence, often denoted as . Therefore, a sequence can be represented as for an infinite sequence or for a finite sequence of length .
Introduction
Sequences could be either infinite or finite. A sequence is defined to be a function whose domain is a nonempty interval of integers. is an infinite sequence if has the form .
is a finite sequence if has the form where . When , we will say that is an . We will take the domain of an to be the set .
The (natural) ordering of the domain of a sequence gives a natural ordering to the ordered pairs in the set . If is a 5-sequence, then
Suppose , and we define the function on by
Then is a finite interval of integers, and so is the sequence denoted by
If is a finite sequence of numbers, the corresponding series is the sum of the entries in is:
Special Sequences
This section introduces common sequences as well as their properties.
Algorithmic Sequence
Algorithmic sequences are a fundamental concept in both computer science and mathematics, forming the backbone of algorithm design and analysis. These sequences are typically defined as an ordered set of steps or instructions, aimed at solving a specific problem or accomplishing a particular computation.
An arithmetic sequence of the form where the initial term and the common difference are real numbers.
Usually, the notation is used to express the nth term of a sequence (starting from 0). For the example in the definition, we have and . We also have: for , : These formula shows the linking between consecutive terms in an arithmetic sequence. We know that the sum of the sequence is: The sum is expressed in infinite terms, and it is called open form equation. Accordingly, there are also closed form equations.
An open form or non-closed form expression, on the other hand, does not have a finite standard representation and often requires recursive or iterative methods for evaluation. It may involve summations, integrals, or other operations that are not easily simplified into a finite number of operations.
A closed form expression is a mathematical expression that can be evaluated in a finite number of standard operations. It typically involves constants, variables, and operations from algebra, calculus, and other areas of mathematics that can be computed in a finite number of steps. A closed form expression provides a direct way to compute the term of a sequence without the need for recursion.
Is the open form good for calculating the sum of a sequence? Suppose now I want to know (The sum of the first 100th terms), with the open form, I still have to calculate 99 terms using the definition of this sequence. So is there a way to make it possible that we get the sum in one step? Think about closed form. The closed form allows us to calculate the sum directly. But is it possible to transform an open expression to closed form? If possible, how?
You may already notice that the open form has a property of infinity, and each step is somewhat related. Isn’t it a perfect problem to be solved by mathematical induction? We will leave this proof as a exercise, and here we provide another direct proof by the symmetry of arithmetic sequence.
For arithmetic sequence , where each term can be expressed as and is the common difference. The sum of the first nth terms is: or where
We are trying to find the sum of the first n terms, and the first term is , so the last term is .
Consider an arithmetic sequence , where each term can be expressed as and is the common difference.
Write the sum of the sequence in order:
Write the sum of the sequence in reverse order:
Add these two equations together, every pair of terms within the brackets forms:
Since each term appears in a pair, there are such pairs.
The resulting equation is .
Solving for gives us or , where .
Geometric Sequence
Geometric sequence is the other important and common sequence that involved in problem-solving of computer Science. A geometric sequence, also known as a geometric progression, is a sequence of numbers where each term after the first is found by multiplying the previous term by a fixed, non-zero number called the common ratio. Mathematically, a geometric sequence is defined as follows:
Given the first term (also referred to as in some texts) and the common ratio , the -th term of a geometric sequence can be expressed as: where is a non-negative integer representing the position of the term in the sequence.
The common ratio can be any real number. If , the terms of the sequence will get progressively smaller and approach zero. If , the terms will grow progressively larger. If , the sequence is constant, and if , the sequence will alternate between two values.
We can deduce the sum of a specific geometric sequence by direct proof.
Consider a geometric sequence with the first term and the common ratio where . The sequence is given by:
The sum of the first terms of the sequence, denoted by , is:
To find a formula for , multiply the entire sequence by :
Subtract the original sum from this new sum to get a telescoping series:
Solving for gives us:
This is the sum formula for the first terms of a geometric sequence when . If , the sequence is constant, and the sum of the first terms is simply times the first term .
characteristic Sequence
Suppose that is some given -set whose elements have been indexed (listed in a certain order) so that . If is a subset of , the characteristic sequence of is the function whose domain is defined by
If is the set of the first 10 odd positive integers, is the subset of primes in , and is the set of multiples of 3 in , then
Characteristic sequences may be used as an implementation model for subsets of any given indexed set . The set operations may be done on these sequences:
If then and
Exercises
Find the sum of arithmetic sequence using mathematical induction. Try NOT use the conclusion in this section.
Hint: Consider the sum of the first nth positive integer. Try to make assumption by taking it as an arithmetic sequence.
Let denote the sum of the first terms of an arithmetic sequence with the first term and common difference .
-
Base Case (): The sum of the sequence with only the first term is the first term itself, .
-
Inductive Step: Assume that the sum of the first terms is given by a certain formula. We want to show that the sum of the first terms can be expressed using the same formula.
For the base case, we can easily see that: As , which could be taken as an arithmetic sequence with and . By this, assume that the sum of the first terms is: equivalent to
To prove the inductive step for , consider:
Substituting the inductive hypothesis into the above equation yields:
After simplifying, we aim to show that:
This will complete the proof if we can establish that the simplified version of matches the form of the inductive hypothesis.
Prove the sum of geometric sequence is using mathematical induction.
We want to prove that the sum of the first terms of a geometric sequence with the first term and common ratio (where ) is given by:
Base Case (n=1):
The sum of the first term is simply the term itself:
which agrees with the formula.
Inductive Step:
Assume the formula holds for , that is,
We need to prove that it also holds for :
Starting with the inductive hypothesis for and adding the -th term to both sides, we have:
Simplifying, we obtain:
which is the same as the formula for , thus completing the proof.
Given a sequence and a series .
-
Find the general term ;
-
Is the sequence an arithmetic sequence?
Hint: How can we get the value of a term from the sum of a sequence? Solution:
- For , \ ,
Therefore, for , ,\ and the general term is
-
Since , can be simplified to , which is constant and equals when . This implies is an arithmetic sequence with common difference , provided are constants and .
Note: From we can deduce when . Since , the sequence (for ) and is the first term. The sequence is an arithmetic sequence.
Therefore, the general term can be expressed as:
Given the series with and , the first differences form an arithmetic sequence with common difference .
Given constants , , , consider the sum , where .
For , we have , thus . For , we have , thus . For , .\ From these equations, we find that:
Solving the system, we get , , . For , the sum can be expressed as: thus, .
For a general term , . Therefore,
Hence, by induction, we can show that for the sum is valid.
Finally, with , , , we confirm that the given sequence is indeed a second-order arithmetic sequence.
Evaluate:
- \
Solution:
(1) Given the series , we can write:
This simplifies to:
Hence, the series sum is:
(2) Considering the series , we proceed similarly:
The terms form a geometric series, so we get:
Applying the formula for the sum of a geometric series, we find:
Simplifying, we obtain:
Further simplification gives us:
Comments