Definition. A relation f⊆A×B is a function f:A→B if (i) every a∈A has some image b∈B with (a,b)∈f, and (ii) that image is unique: (a,b),(a,c)∈f⇒b=c. Then f(a)=b; b is the image of a, a is a pre-image of b. The range {b:(a,b)∈f for some a} is always ⊆ co-domain B. Only the domain side is required to be fully, uniquely covered -- how many pre-images a co-domain point has, or whether it has any, are separate questions (injectivity/surjectivity below).
Representing a function: tabularly (a list of argument/value pairs), graphically (plot with the Vertical Line Test: a curve is a function's graph iff every vertical line meets it at exactly one point), or analytically (a formula, whose natural domain is wherever that formula is actually defined -- found by excluding zero denominators, requiring even-root radicands ≥0, etc., often via a sign-chart over intervals cut out by the critical points). Functions may also be piecewise (different formula on different sub-intervals).
Named elementary functions: identity (f(x)=x), constant (and the zero function as its special case), modulus ∣x∣, signum x/∣x∣ (with 0↦0), floor ⌊x⌋ (always rounds down, even for negatives) and ceiling ⌈x⌉ (always rounds up) -- the last two are "step functions". …