Presentation is loading. Please wait.

Presentation is loading. Please wait.

EECS 20 Chapter 21 Defining Signals and Systems Last time we Introduced mathematical notation to help define sets Learned the names of commonly used sets.

Similar presentations


Presentation on theme: "EECS 20 Chapter 21 Defining Signals and Systems Last time we Introduced mathematical notation to help define sets Learned the names of commonly used sets."— Presentation transcript:

1 EECS 20 Chapter 21 Defining Signals and Systems Last time we Introduced mathematical notation to help define sets Learned the names of commonly used sets (Reals, etc.) Created multi-dimensional sets using set product Used notation to define domain & range for common signals Saw multiple ways to define a particular set Today we will List common ways to define functions (signals or systems) Touch on declarative vs. imperative definitions Talk about domain and range of systems Consider several common ways of defining systems

2 EECS 20 Chapter 22 Defining Functions A set is a collection of elements. You can define a set by listing the elements in curly brackets: EE20Profs = {Ross, Lee, Varaiya, ElGhaoui, Henzinger} Sometimes there are too many elements to list individually. Example: Set of all real numbers between 0 and 1 You can define an interval using square & round parentheses. A square bracket includes the endpoint, round excludes. (0,1)all real numbers strictly between 0 and 1 [5, ∞)all real numbers greater than or equal to 5

3 EECS 20 Chapter 23 Famous Sets Some sets that we will use routinely include: RealsSet of all real numbers Reals + Set of all nonnegative real numbers IntegersSet of all integers Integers + Set of all nonnegative integers NaturalsSet of all positive integers {1, 2, …} Naturals 0 Set of all nonnegative integers (Integers + ) Bools{true, false} Charset of all alphanumeric characters Complexset of all complex numbers Ñ Ñ+Ñ+ Ù+Ù+ Ù Í Â

4 EECS 20 Chapter 24 Famous Symbols Set inclusion: Î “belongs to” Ï “does not belong to” 1 Î [0,1]1 Ï [0,1) Quantifiers: " “for all” $ “there exists” Logical operators: Ù “and” Ú “or” Ø “not” Logical relations: Þ “implies” Û “is equivalent to”

5 EECS 20 Chapter 25 Defining Sets Using Predicates We can define a new set NS, a subset of some set S, in the following way: We say that some general element x Î S is also a member of NS if and only if the statement Pred(x) is true for that x. Here, x is called a variable and Pred(x) is called a predicate. Using mathematical notation, we define NS: NS = {x Î S | Pred(x) } Example: Write a definition for the set of even numbers, Evens. Evens = {x Î Integers | x/2 Î Integers }

6 EECS 20 Chapter 26 Set Operations Subset Ì A Ì B means “all elements in A are also in B” Example:Naturals Ì Integers Union Ç A Ç B is the set of x for which x Î A or x Î B Example:(0,5) Ç [4,8] = Intersection È A È B is the set of x for which x Î A and x Î B Example: (0,5) È [4,8] = Subtraction \ A \ B is the set of x for which x Î A and x Ï B Example: (0,5) \ [4,8] = Empty Set Æ (0,8] [4,5) (0,4)

7 EECS 20 Chapter 27 Practice Using Mathematical Notation Define the following sets using mathematical notation: A È B = Rationals = (rational numbers, Ð ) Integers16 = (integers representable by 16 bits) {x Î A | x Î A Ù x Î B} {x Î Reals | $ p Î Integers, q Î Naturals with x = p/q} {x Î Integers | x ≥ -32768 Ù x ≤ 32767} or Integers È [-32768, 32767] or {-32768, -32767, …, 32767}

8 EECS 20 Chapter 28 Product Sets Sets we commonly refer to as “multi-dimensional” can often be expressed as a Cartesian product of two or more sets. A X B = {(a,b) | a Î A Ù b Î B} The product set A X B consists of all ordered pairs (a,b) with a being an element in set A and b being an element in set B. Example: Define the 1 st quadrant of the real plane, Reals + 2 Reals + 2 = Reals + X Reals +

9 EECS 20 Chapter 29 About Product Sets A X B = {(a,b) | a Î A Ù b Î B} B X A = {(b,a) | a Î A Ù b Î B} A X A = {(a 1, a 2 ) | a 1 Î A Ù a 2 Î A} A X A = A 2 A X A X A X … X A = A n A 1 X A 2 X A 3 X … X A n =  A i i = 1 n

10 EECS 20 Chapter 210 Product Set Examples Set of pixels on an old VGA monitor (640x480), VGAScreen VGAScreen = {1, 2, …, 640} X {1, 2, …, 480} or [1, 640] X [1, 480] È Integers 2 Set of seats in this classroom, 145DwinelleSeats 145DwinelleSeats =

11 EECS 20 Chapter 211 Signals Using Product Sets Prof. Ross’s computer desktop image is a 1024 x 768 pixel, 24-bit color image of Brett Favre. The image may be viewed as a signal. This means that each picture element (pixel) in the grid has its color described by a 24-bit (3 byte) number. What is the domain of this signal? What is the range? The 24 bits can represent color as follows: the first 8 bits represent the red intensity, the next 8 bits represent the green intensity, and the last 8 bits represent blue intensity. What is another way to represent the range? {1, 2, … 1024} X {1, 2, … 768} {1, 2, 3, …, 2 24 } = {1, 2, 3, …, 16777216} {1, 2, …, 2 8 } X {1, 2, …, 2 8 } X {1, 2, …, 2 8 } = {1, 2, …, 2 8 } 3

12 EECS 20 Chapter 212 Systems Using Products of Signal Sets Recall that systems map signals to new signals. The domain and range of a system are sets of signals. Example: Consider the system FreezeFrame. It takes a video composed of a sequence of 1024 x 768 pixel, 24-bit color images as input. It takes another input, DesiredFrame, which is an integer between 1 and MaxFrames. DesiredFrame changes over time. The system “freezes” the video on the frame DesiredFrame, and this image is the system output. The output changes over time as DesiredFrame changes. What is the domain of this system? What is the range of this system?


Download ppt "EECS 20 Chapter 21 Defining Signals and Systems Last time we Introduced mathematical notation to help define sets Learned the names of commonly used sets."

Similar presentations


Ads by Google