Functions and Relations Flashcards
What is a relation?
Let A and B be sets. A relation from A to B is a subset of the cartesian product A x B
i.e. A = {cities of the wold} B = {countries of the world} and R = {(a, b): a is the capital city of b} –> (Paris) R (France)
What are Domain and Co-Domain?
A relation R from A to B is a subset of A x B. The set A is called domain of R and the set of B is called its co-domain
What is a function?
A function from a set A to B is a relation with domain A and co-domain B that satisfies the two following properties:
- Every element in A is the first element of an ordered pair of F
- No two distinct ordered pairs in F have the same first element
When are two functions equal?
If F:X->Y and G:X->Y are functions, then F=G if and only if F(x) = G(X) for all x in X
What is a one to one function?(Injective)
A function whgere any distinct element in X is sent to a distinct element in Y (without two Xs being sent to the same element in Y)
When is a function onto? (surjective)
A function is onto only if any element in Y is reached by an element x (y = F(x))
What is a one to one correspondence (bijection)?
a function F:X -> Y that is both one-to-one and onto
What is an inverse function?
A function that reverses the previous function
What are the properties of a relation? (three)
- Reflexive: if for all x in A, x R x
- Symmetric: for all x and y in A, if (x, y) is part of thre relation then (y, x) has to be part of the relation as well.
- Transitive: if for all x, y, z in A if xRy and yRz then xRz