“Mr. Smith, could you explain to us what recursion is all about?” The professor in Introduction to Programming asked an apathetic student. “I don’t know the question, but sex, money, or both is definitely the answer, and God, justice, our values, and love are just the excuses,” I replied. “You shall not pass,” the teacher was far from amused, Apocalypse, Anawim, #justtothepoint.
Definition. A function f is a rule, relationship, or correspondence that assigns to each element of one set (x ∈ D), called the domain, exactly one element of a second set, called the range (y ∈ E).
The pair (x, y) is denoted as y = f(x). Typically, the sets D and E will be both the set of real numbers, ℝ.
A monotonic function is a mathematical function that maintains a consistent direction of change on its domain, either entirely increasing (monotonic increasing) or entirely decreasing (monotonic decreasing).
Let f be a function defined on some interval I. f increases on an interval I if f(b) >= f(a) ∀b > a, a,b ∈ I. If f(b) > f(a) ∀b > a, a, b ∈ I, the function is said to be strictly increasing on I.
Conversely, f decreases on an interval I if f(b) <= f(a) ∀b > a, a, b ∈ I. If f(b) < f(a) ∀b > a, a, b ∈ I, the function is said to be strictly decreasing. Finally, f is said to be constant on an interval I if f(a) = f(b) ∀a, b ∈ I.
Local extrema are the largest or smallest values locally, that is, on an interval around the point. More formally, they are critical points on the graph of a function where the function reaches a maximum or minimum value (a valley) within a specific neighborhood of that point.
A critical point of a function f(x) occurs where the derivative f’(x) is either zero or undefined.
Definition. Let D be the domain of a function and c ∈ D. f is said to have a local or relative maximum point at c if there exists an interval (a, b) containing c such that f(c) is the maximum value of f on (a, b) ∩ D: f(c) ≥ f(x) ∀ x in (a, b) ∩ D.
Conversely, f is said to have a local or relative minimum point at c if there exists an interval (a, b) containing c such that f(c) is the minimum value of f on (a, b) ∩ D: f(c) ≤ f(x) ∀ x in (a, b) ∩ D.
A function has a local or relative extremum at c if c is either a relative maximum or minimum, that is, a point of the graph where f changes its monotonicity within the domain. Futhermore, a point of inflection is a point where the graph of f changes its concavity.
First Derivative Test. If the derivate f’(x) changes sign from positive to negative (as we look from read from left to right at the graph) at a critical point x = c, then f(c) is a local maximum (Figure 2.a)
If the derivate f′(x) changes sign from negative to positive at a critical point x = c, then f(c) is a local minimum.
Proof.
Let’s confine ourself to the case of the minimum, the other case follows mutatis mutandis.
To the left from the point c, ∀x ∈ (c -δ, c), f’(x) < 0 ⇒[By Lagrange’s theorem, Let f be a function defined such that f: [a, b] → ℝ be a continuous function on [a, b] and differentiable on (a, b). Then, there exist some point c in this interval (a, b) such that the derivative of the function at the point c is equal to the difference of the function values at these points, divided by the difference of the point values, $f’(x_0)=\frac{f(b)-f(a)}{b-a}$] In this particular case, the difference of values of the function at the point x and c, f(x) - f(c) = f’(x0)(x -c) [x, x0 ∈ (c -δ, c) ⇒ f’(x0) < 0, (x -c) < 0] f’(x0)(x -c) > 0 ⇒ f(x) > f(c).
Analogously, ∀x ∈ (c, c + δ), f’(x) > 0 ⇒[By Lagrange’s Theorem] The difference of values of the function at the point x and c, f(x) - f(c) = f’(x0)(x -c) [x, x0 ∈ (c, c + δ) ⇒ f’(x0) > 0, (x -c) > 0] f’(x0)(x -c) > 0 ⇒ f(x) > f(c).
Second Derivative Test. If the first derivate of a function at a point c is zero (f'(c) = 0) and its exists the second derivate at this point and f''(c) > 0, then f(c) is a local minimum. Analogously, if f’(c) = 0 and f’’(c) < 0, then f(c) is a local maximum.
Proof.
Let’s confine ourself to the case of the minimum, the other case follows mutatis mutandis.
f’’(c) > 0 ⇒ The first derivate is increasing at this point c ⇒ ∃δ > 0: ∀x ∈ (c -δ, c), f’(x) < f’(c) = 0 and ∀x ∈ (c, c + δ), f’(x) > f’(c) = 0, and this is exactly the First Derivate Test.
Calculate local maximum and minimum points for y = 3x5 -20x3 (Figure 2.d).
Therefore, it has a local minimum at x = 2 and a local maximum at x = -2. The critical point x = 0 is not a local extremum; it’s a point of inflection.
In the previous example (Figure 1), f has local or relative minimum points at -6, -3, and 7, and local or relative maximum points at -5, 0, and 4. On the open interval (0, 4), the function is constant, and therefore every point is both a local or relative maximum and minimum point. Futhermore, (-4, 0), (-2, 0), (0, 6), and (4, 6) are points of inflection.