Shawn Zhong

Shawn Zhong

钟万祥
  • Tutorials
  • Mathematics
    • Math 240
    • Math 375
    • Math 431
    • Math 514
    • Math 521
    • Math 541
    • Math 632
    • Abstract Algebra
    • Linear Algebra
    • Category Theory
  • Computer Sciences
    • CS/ECE 252
    • CS/ECE 352
    • Learn Haskell
  • AP Notes
    • AP Microecon
    • AP Macroecon
    • AP Statistics
    • AP Chemistry
    • AP Physics E&M
    • AP Physics Mech
    • CLEP Psycho

Shawn Zhong

钟万祥
  • Tutorials
  • Mathematics
    • Math 240
    • Math 375
    • Math 431
    • Math 514
    • Math 521
    • Math 541
    • Math 632
    • Abstract Algebra
    • Linear Algebra
    • Category Theory
  • Computer Sciences
    • CS/ECE 252
    • CS/ECE 352
    • Learn Haskell
  • AP Notes
    • AP Microecon
    • AP Macroecon
    • AP Statistics
    • AP Chemistry
    • AP Physics E&M
    • AP Physics Mech
    • CLEP Psycho

Home / 2018 / April / 18

Math 541 – 4/16

  • Apr 18, 2018
  • Shawn
  • Math 541
  • No comments yet
Ring • Example 1 ○ The trivial group, equipped with the trivial multiplication, is a ring ○ It
Read More >>

Math 541 – 4/11

  • Apr 18, 2018
  • Shawn
  • Math 541
  • No comments yet
Ring • Definition ○ A ring is a set R equipped with two operations § +:R×R→R § ⋅:R×R→R ○ such that § (R,+) is an abelian group § ⋅ is associative § ∃1∈R s.t. 1⋅r=r=r⋅1 § Distributive property: □ ∀a,b,c∈R □ a⋅(b+c)=a⋅b+a⋅c □ (a+b)⋅c=a⋅c+b⋅c • Notes ○ 1 is called the multiplicative identity ○ Dummit-Foote don t require the multiplicative identity ○ ⋅ is not necessarily commutative ○ R is not a group under ⋅, because inverses may not exist ○ We will typically denote multiplication of r,s∈R by rs ○ Typically 1 will denote the multiplicative identity ○ And 0 will denote the identity of (R,+)
Read More >>

9.1 Relations and Their Properties

  • Apr 18, 2018
  • Shawn
  • Math 240
  • No comments yet
Binary Relations • Definition ○ A binary relation R from a set A to a set B is a subset R⊆A×B. • Example ○ Let A={0,1,2} and B={a,b} ○ {(0, a), (0, b), (1, a), (2, b)} is a relation from A to B. ○ We can represent this relation graphically or using a table: • Note ○ Relations are more general than functions ○ A function is a relation where exactly one element of B is related to each element of A Binary Relation on a Set • Definition ○ A binary relation R on a set A is a subset of A×A or a relation from A to A. • Example 1 ○ Suppose that A={a,b,c} ○ Then R={(a,a),(a,b), (a,c)} is a relation on A • Example 2 ○ Let A={1, 2, 3, 4} ○ The ordered pairs in the relation R={(a,b)│a divides b} are ○ {(1,1), (1, 2), (1,3), (1, 4), (2, 2), (2, 4), (3, 3),(4,4)} • Question: How many relations are there on a set A? ○ Because a relation on A is the same thing as a subset of A×A ○ We count the subsets of A×A. ○ Since A×A has n^2 elements when A has n elements ○ And a set with m elements has 2^m subsets ○ There are 2^(|A|^2 ) subsets of A×A. ○ Therefore, there are 2^(|A|^2 ) relations on a set A. • Example 3 ○ Consider these relations on the set of integers: § R_1={(a,b)│a≤b} § R_2={(a,b)│a b} § R_3={(a,b)│a=b or a=−b} § R_4={(a,b)│a=b} § R_5={(a,b)│a=b+1} § R_6={(a,b)│a+b≤3} ○ Note § These relations are on an infinite set and each of these relations is an infinite set § R_5 can be viewed as a function § Our definition of a function f:A→B is a subset of A×B § Therefore every function is a relation ○ Which of these relations contain each of the pairs § (1,1), (1, 2), (2, 1), (1, −1), and (2, 2)? ○ Solution § (1,1) is in R_1, R_3, R_4, and R_6 § (1,2) is in R_1 and R_6 § (2,1) is in R_2, R_5, and R_6 § (1, −1) is in R_2, R_3, and R_6 § (2,2) is in R_1, R_3, and R_4 Reflexive Relations • Definition ○ R is reflexive if and only if (a,a)∈R for every element a∈A ○ Written symbolically, R is reflexive if and only if ○ ∀x[x∈U→(x,x)∈R] • Note ○ If A = ∅ then the empty relation is reflexive vacuously. ○ That is the empty relation on an empty set is reflexive! • Example ○ The following relations on the integers are reflexive: § R_1={(a,b)│a≤b} § R_3={(a,b)│a=b or a=−b} § R_4={(a,b)│a=b} ○ The following relations are not reflexive: § R_2={(a,b)│a b} (note that 3 ≯ 3) § R_5={(a,b)│a=b+1} (note that 3 ≠ 3 + 1) § R_6={(a,b)│a+b≤3} (note that 4+4≰3) Antireflexive Relations • Definition ○ R is antireflexive if and only if (a,a)∉R for every element a∈A ○ Written symbolically, R is antireflexive if and only if ○ ∀x[x∈U→(x,x)∉R] • Note ○ Antireflexive is different from not reflexive • Example ○ The following relations on the integers are antireflexive § R_2={(a,b)│a b} § R_5={(a,b)│a=b+1} ○ R_6={(a,b)│a+b≤3} is neither reflexive nor antireflexive Symmetric Relations • Definition ○ R is symmetric if and only if (b,a)∈R whenever (a,b)∈R,∀a,b∈A ○ Written symbolically, R is symmetric if and only if ○ ∀x∀y[(x,y)∈R→(y,x)∈R] • Example ○ The following relations on the integers are symmetric: § R_3={(a,b)│a=b or a=−b} § R_4={(a,b)│a=b} § R_6={(a,b)│a+b≤3} ○ The following are not symmetric: § R_1={(a,b)│a≤b} (note that 3 ≤ 4, but 4 ≰ 3) § R_2={(a,b)│a b} (note that 4 3, but 3 ≯ 4) § R_5={(a,b)│a=b+1} (note that 4 = 3 + 1, but 3 ≠ 4 + 1) Antisymmetric Relations • Definition ○ R is antisymmetric if and only if a=b whenever (a,b),(b,a)∈R,∀a,b∈A ○ Written symbolically, R is antisymmetric if and only if ○ ∀x∀y[(x,y)∈R∧(y,x)∈R→x=y] • Note ○ For any integer, if a≥b and a≤b, then a=b • Example ○ The following relations on the integers are antisymmetric: § R_1={(a,b)│a≤b} § R_2={(a,b)│a b} § R_4={(a,b)│a=b} § R_5={(a,b)│a=b+1} ○ The following relations are not antisymmetric: § R_3={(a,b)│a=b or a=−b} (note that (1,−1),(−1,1)∈R_3) § R_6={(a,b)│a+b≤3} (note that (1,2),(2,1)∈R_6) Transitive Relations • Definition ○ R is transitive if and only if (a,c)∈R whenever (a,b),(b,c)∈R, ∀a,b,c∈A ○ Written symbolically, R is transitive if and only if ○ ∀x∀y∀z[(x,y)∈R∧(y,z)∈R→(x,z)∈R] • Note ○ For every integer, a≤b and b≤c, then b≤c • Example ○ The following relations on the integers are transitive: § R_1={(a,b)│a≤b} § R_2={(a,b)│a b} § R_3={(a,b)│a=b or a=−b} § R_4={(a,b)│a=b} ○ The following are not transitive: § R_5={(a,b)│a=b+1} (note that (3,2),(4,3)∈R_5, but (3,3)∉R_5), § R_6={(a,b)│a+b≤3} (note that (2,1),(1,2)∈R_6, but (2,2)∉R_6). Combining Relations • Given two relations R_1 and R_2 • We can combine them using basic set operations to form new relations • Example ○ Let A={1,2,3} and B={1,2,3,4} ○ The relations R_1 = {(1,1),(2,2),(3,3)} and R_2 = {(1,1),(1,2),(1,3),(1,4)} can be combined using basic set operations to form new relations: ○ R_1 ∪ R_2 ={(1,1),(1,2),(1,3),(1,4),(2,2),(3,3)} ○ R_1 ∩ R_2 ={(1,1)} ○ R_1 − R_2 ={(2,2),(3,3)} ○ R_2 − R_1 ={(1,2),(1,3),(1,4)} Inverse • Definition ○ Let R be a relation from A to B ○ The inverse of R is the relation § R^(−1)={(a,b)│(b,a)∈R} • Proposition ○ R is symmetric if and only if R=R^(−1) Composition • Definition ○ Suppose § R_1 is a relation from a set A to a set B. § R_2 is a relation from B to a set C ○ Then the composition of R_2 with R_1 is a relation from A to C where § if (x,y) is a member of R_1 § and (y,z) is a member of R_2 § then (x,z) is a member of R_2∘R_1 • Example ○ R_2∘R_1={(b,x),(b,z)} Powers of a Relation • Definition ○ Let R be a binary relation on A ○ Then the powers R_n of the relation R can be defined inductively by: ○ Basis Step: R_1=R ○ Inductive Step: R_(n+1)=R_n∘R • The powers of a transitive relation are subsets of the relation • This is established by the following theorem: • Theorem 1 ○ The relation R on a set A is transitive iff R_n⊆R for n = 1,2,3… ○ (see the text for a proof via mathematical induction)
Read More >>

7.1 An Introduction to Discrete Probability

  • Apr 18, 2018
  • Shawn
  • Math 240
  • No comments yet
Probability of an Event • Introduction ○ We first study Pierre-Simon Laplace’s classical theory of probability ○ which he introduced in the 18th century, when he analyzed games of chance. • Experiment ○ A procedure that yields one of a given set of possible outcomes. • Sample space ○ The sample space of the experiment is the set of possible outcomes. • Event ○ An event is a subset of the sample space. • Probability ○ If S is a finite sample space of equally likely outcomes and E is an event ○ Then the probability of E is p(E)=|E|/|S| ○ For every event E, we have 0≤p(E)≤1 ○ This follows directly from the definition because ○ 0≤p(E)=|E|/|S| ≤|S|/|S| ≤1, since 0≤|E|≤|S| Applying Laplace’s Definition • Example 1 ○ An urn contains four blue balls and five red balls. ○ What is the probability that a ball chosen from the urn is blue? ○ The probability that the ball is chosen is 4/9 ○ since there are nine possible outcomes, and four of these produce a blue ball. • Example 2 ○ What is the probability that when two dice are rolled, the sum of the numbers on the two dice is 7? ○ By the product rule there are 62 = 36 possible outcomes. ○ Six of these sum to 7. ○ Hence, the probability of obtaining a 7 is 6/36 = 1/6. • Example 3 ○ In a lottery, a player wins a large prize when they pick four digits that match, in correct order, four digits selected by a random mechanical process. ○ What is the probability that a player wins the prize? ○ By the product rule there are 104 = 10,000 ways to pick four digits. ○ Since there is only 1 way to pick the correct digits, ○ the probability of winning the large prize is 1/10,000 = 0.0001. • Example 4 ○ A smaller prize is won if only three digits are matched. ○ What is the probability that a player wins the small prize? ○ If exactly three digits are matched, one of the four digits must be incorrect and the other three digits must be correct. ○ For the digit that is incorrect, there are 9 possible choices. ○ Hence, by the sum rule, there a total of 36 possible ways to choose four digits that match exactly three of the winning four digits. ○ The probability of winning the small price is § 36/10,000 = 9/2500 = 0.0036 • Example 5 ○ There are many lotteries that award prizes to people who correctly choose a set of six numbers out of the first n positive integers, where n is usually between 30 and 60. ○ What is the probability that a person picks the correct six numbers out of 40? ○ The number of ways to choose six numbers out of 40 is § C(40,6) = 40!/(34!6!) = 3,838,380. ○ Hence, the probability of picking a winning combination is § 1/ 3,838,380 ≈ 0.00000026. • Example 6 ○ What is the probability that the numbers 11, 4, 17, 39, and 23 are drawn in that order from a bin with 50 balls labeled with the numbers 1,2, …, 50 if ○ The ball selected is not returned to the bin. § Sampling without replacement: § The probability is 1/254,251,200 since there are § 50 ∙49 ∙47 ∙46 ∙45 = 254,251,200 ways to choose the five balls. ○ The ball selected is returned to the bin before the next ball is selected. § Sampling with replacement: § The probability is 1/〖50〗^5 = 1/312,500,000 since 〖50〗^5 = 312,500,000. The Probability of Complements and Unions of Events • Theorem 1 ○ Let E be an event in sample space S. ○ The probability of the complementary event of E:E ̅ = S − E is given by ○ p(E ̅ )=1−p(E) • Proof ○ Using the fact that |E ̅ |=|S|−|E| ○ p(E ̅ )=(|S|−|E|)/|S| =1−|E|/|S| =1−p(E) • Example ○ A sequence of 10 bits is chosen randomly. ○ What is the probability that at least one of these bits is 0? ○ Let E be the event that at least one of the 10 bits is 0. ○ Then E ̅ is the event that all of the bits are 1s. ○ The size of the sample space S is 210. Hence, ○ p(E)=1−p(E ̅ )=1−|E ̅ |/|S| =1−1/2^10 =1−1/1024=1023/1024 • Theorem 2 ○ Let E_1 and E_2 be events in the sample space S. Then ○ p(E_1∪E_2 )=p(E_1 )+p(E_2 )−p(E_1∩E_2 ) • Proof ○ Given the inclusion-exclusion formula from Section 2.2 ○ |A ∪ B| = |A| + |B| − |A ∩ B|, it follows that § p(E_1∪E_2 )=|E_1∪E_2 |/|S| § =(|E_1 |+|E_2 |−|E_1∩E_2 |)/|S| § =|E_1 |/|S| +|E_2 |/|S| −|E_1∩E_2 |/|S| § =p(E_1 )+p(E_2 )−p(E_1∩E_2 ) • Example ○ What is the probability that a positive integer selected at random from the set of positive integers not exceeding 100 is divisible by either 2 or 5? ○ Let E_1 be the event that the integer is divisible by 2 ○ Let E_2 be the event that it is divisible 5. ○ Then the event that the integer is divisible by 2 or 5 is E_1∪E_2 ○ And E_1∩E_2 is the event that it is divisible by 2 and 5. ○ It follows that: ○ p(E_1∪E_2 )=p(E_1 )+p(E_2 )−p(E_1∩E_2 )=50/100+20/100−10/100=3/5 Monty Hall Puzzle • You are asked to select one of the three doors to open. • There is a large prize behind one of the doors and if you select that door, you win the prize. • After you select a door, the game show host opens one of the other doors (which he knows is not the winning door). • The prize is not behind the door and he gives you the opportunity to switch your selection. • Should you switch? • You should switch. • The probability that your initial pick is correct is 1/3. • This is the same whether or not you switch doors. • But since the game show host always opens a door that does not have the prize, • If you switch the probability of winning will be 2/3 • Because you win if your initial pick was not the correct door • And the probability your initial pick was wrong is 2/3.
Read More >>

Search

  • Home Page
  • Tutorials
  • Mathematics
    • Math 240 – Discrete Math
    • Math 375 – Linear Algebra
    • Math 431 – Intro to Probability
    • Math 514 – Numerical Analysis
    • Math 521 – Analysis I
    • Math 541 – Abstract Algebra
    • Math 632 – Stochastic Processes
    • Abstract Algebra @ 万门大学
    • Linear Algebra @ 万门大学
    • Category Theory
  • Computer Sciences
    • CS/ECE 252 – Intro to Computer Engr.
    • CS/ECE 352 – Digital System Fund.
    • Learn Haskell
  • Course Notes
    • AP Macroeconomics
    • AP Microeconomics
    • AP Chemistry
    • AP Statistics
    • AP Physics C: E&M
    • AP Physics C: Mechanics
    • CLEP Psychology
  • 2048 Game
  • HiMCM 2016
  • 登峰杯 MCM

WeChat Account

Categories

  • Notes (418)
    • AP (115)
      • AP Macroeconomics (20)
      • AP Microeconomics (23)
      • AP Physics C E&M (25)
      • AP Physics C Mechanics (28)
      • AP Statistics (19)
    • Computer Sciences (2)
    • Mathematics (300)
      • Abstract Algebra (29)
      • Category Theory (7)
      • Linear Algebra (29)
      • Math 240 (42)
      • Math 375 (71)
      • Math 514 (18)
      • Math 521 (39)
      • Math 541 (39)
      • Math 632 (26)
  • Projects (2)
  • Tutorials (11)

Archives

  • October 2019
  • May 2019
  • April 2019
  • March 2019
  • February 2019
  • December 2018
  • November 2018
  • October 2018
  • September 2018
  • July 2018
  • May 2018
  • April 2018
  • March 2018
  • February 2018
  • January 2018
  • December 2017
  • November 2017
  • October 2017
  • September 2017
  • August 2017
  • July 2017
  • June 2017

WeChat Account

Links

RobeZH's thoughts on Algorithms - Ziyi Zhang
Copyright © 2018.      
TOP