# 📝Set theory: functions

**function:**$f : A \to B$ is a function iff $\forall x \in A. \exists! y \in B \ni f(x) = y$ (i.e., it must be total)- $A$ is domain
- $B$ is codomain
**Image**of function $f$ is a set of possible values (y’s)- $y \in Image(f) \iff \exists x \in A \ni f(x) = y$

**injective function:**$f : A \to B$ is injective iff $\forall x_1, x_2 \in A. f(x) = f(y) \implies x = y$- no two x’s map to the same y

**surjective function:**$f : A \to B$ is surjective iff $\forall y \in B. \exists x \in A \ni f(x) = y$- for all y, there is an x

**bijective functions:**is a function that is both injective and surjective- bijective functions have an inverse