Function

Table of Contents

1 Definition

A function is a rule that assigns to each element from one set (domain) exactly one element from another set (range).

  • Notation : \(y = f(x)\)
  • How to determine
    • numerically : for each value of \(x\), is the value of \(y\) unique?
    • graphically : vertical line test
  • Example
    • YES
      • \(y = f(x) = 1\)
      • \(y = f(x) = x^2 - 3 + \sqrt{x+2}\)
    • NO
      • \(y^2 = x\). When \(x=1, y=\pm 1\)

2 Domain

2.1 Definition

The set of all possible values of the independent variable (\(x\)) in a function is called the domain of the function.

You should always give the domain in form of set or interval.

2.2 How to determine

  • The domain of a polynomial function \(f(x) = a_n x^n + a_{n-1} x^{n-1} + \dots + a_1 x + a_0\) is the set of all real numbers \(\mathbb{R}\).

    The domain of \(f(x) = 5x^4 + x^3 - 3x^2 + 11\) is \(\mathbb{R}\).

  • The domain of a fraction function \(f(x) = 1/g(x)\) is the set of all points such that the denominator is non-zero, ie, \(\{x : g(x) \neq 0\}\).

    The domain of \(f(x) = \frac{1}{x-3}\) is \(\mathbb{R}\setminus\{3\}\).

  • The domain of a square root function \(f(x) = \sqrt{g(x)}\) is the set of all points such that the term under the square root symbol non-negative, ie, \(\{x : g(x) \geq 0\}\).

    The domain of \(f(x) = \sqrt{x^2 - 9}\) is \((-\infty, -3] \cup [3,\infty)\)

  • The domain of a logarithmic function \(f(x) = log_a g(x), a > 0, a\neq 1\) is the set of all points such that \(g(x) > 0\), ie, \(\{x : g(x) > 0\}\)

    The domain of \(f(x) = ln (x^2 - 9)\) is \((-\infty, -3) \cup (3,\infty)\)

  • The domain of an exponential function \(f(x) = a^x, a > 0\) and \(a\neq 1\) is the set of all real numbers \(\mathbb{R}\).
  • For a composite function \((f\circ g)(x) = f(g(x))\), the domain is \(\{ \text{domain of } f(g) \text{ in term of } x \}\) \(\cap\) \(\{ \text{domain of } g \text{ in term of } x \}\).

    For example, when \(f(x)=\frac{1}{x}\) and \(g(x) = ln(x)\)

    • the domain of \(f(g)\) in term of \(x\) is \(\{x : g(x) \neq 0\} = \{x : ln(x) \neq 0\} = \{x : x\neq 1\}\) and
    • the domain of \(g(x)\) is \(\{x : x > 0\}\), so
    • the domain of \(f\circ g\) is \(\{x : x > 0\} \cap \{x : x\neq 1\} = \{x : x > 0 \text{ and } x\neq 1\}\)

3 Range

3.1 Definition

The resulting set of possible values of the dependent variable (\(y\)) is called the range.

  • The range depends on the domain. For example,
    • the range of \(y = x+1, x\in (1,2)\) is \((2,3)\), while
    • the range of \(y = x+1, x\in (0,5)\) is \((1,6)\).
  • If two functions have the same domain and the same rule, then they have the same range as well.

3.2 Example

  • \(f(x) = 1\)
  • \(f(x) = x^2\)
  • \(f(x) = \frac{1}{x+1}\)
  • \(f(x) = \frac{1}{x^2 + 1}\)
  • \(f(x) = \frac{1}{(x+1)^2}\)
  • \(f(x) = \sqrt{x}\)
  • \(f(x) = \sqrt{x}, x\in (9, 25]\)
  • \(f(x) = ln(x-1)\)
  • \(f(x) = 3^x\)

4 Operations

4.1 Arithmetic

  • Addition \(f(x) + g(x)\)
  • Subtraction \(f(x) - g(x)\)
  • Multiplication \(f(x) \cdot g(x)\)
  • Division \(f(x)/g(x)\)

4.2 Composition

4.2.1 Definition

  • \((f\circ g) (x) = f(g(x))\)
  • \((g\circ f) (x) = g(f(x))\)
  • In general, \((f\circ g) (x) \neq (g\circ f) (x)\)

4.2.2 How to find \(f\circ g\) for given \(f\) and \(g\)

  • Steps
    1. In \(f(x)\), replace variable \(x\) with variable \(g\), and
    2. Then replace variable \(g\) with the expression of \(g(x)\)
  • Examples
    • \(f(x) = 3, g(x) = 4\)

      \((f\circ g) (x) = f(g(x)) = f(4) = 3\)

    • \(f(x) = 3, g(x) = ln(x)\)

      \((f\circ g) (x) = f(g(x)) = f(ln(x)) = 3\)

    • \(f(x) = x^2 + 1, g(x) = \sqrt{x}\)

      \((f\circ g) (x) = f(g) = g^2 + 1 = [g(x)]^2 + 1 = (\sqrt{x})^2 + 1 = x + 1, x \geq 0\)

    • \(f(x) = ln(\frac{x^2}{1-x}), g(x) = 4^{x+1}\)

      \((f\circ g) (x) = f(g) = ln(\frac{g^2}{1-g}) = ln(\frac{[g(x)]^2}{1-g(x)}) = ln(\frac{[4^{x+1}]^2}{1-4^{x+1}})\)

      \((g\circ f) (x) = g(f) = 4^{f+1} = 4^{f(x) + 1} = 4^{ln(\frac{x^2}{1-x}) + 1}\)

4.2.3 How to identify \(f\) and \(g\) for a given composition

  • Steps
    • Let \(f\) be the outermost function, so the composition can be written as \(f(g)\), a function of \(g\)
    • Let \(g\) be all terms immediately inside \(f\), so \(g\) can be written as \(g(x)\), a function of \(x\)
  • Examples
    • \(h(x) = ln(3x+1)\)

      \(ln(\text{something})\) is the outermost function, so let \(f(g) = ln(g)\)

      The whole term immediately inside \(ln()\) function is \(g(x) = 3x + 1\)

      Thus \(f(x) = ln (x)\) and \(g(x)= 3x + 1\)

    • \(h(x) = (7x^2 + 3x - 2)^{100}\)

      \((\text{something})^{100}\) is the outermost function, so let \(f(g) = g^{100}\)

      The whole term immediately inside \((\cdot)^{100}\) is \(g(x) = 7x^2 + 3x - 2\)

      Thus \(f(x) = x^{100}\) and \(g(x) = 7x^2 + 3x - 2\)

    • \(h(x) = 3(x-2)^2 + 5\)

      \(3 \cdot \text{something} + 5\) is the outermost function, so let \(f(g) = 3g + 5\) and \(g(x) = (x-2)^2\)

      Or, regard \(3(\text{something})^2 + 5\) as the outermost function, so \(f(g) = 3g^2 + 5\) and \(g(x) = x-2\)

      Or, regard \(\text{something} + 5\) as the outermost function, so \(f(g) = g + 5\) and \(g(x) = 3(x-2)^2\)

5 Exponential Function

5.1 Definition

An exponential function with base \(a\) is defined as \(y = f(x) = a^x\) where \(a > 0\) and \(a\neq 1\)

5.2 Property

  • Suppose \(a > 0\) and \(a\neq 1\). Then
    • \(a^x \cdot a^y = a^{x+y}\)
    • \((a^x)^y = a^{xy}\)
    • (exponential equation) If \(a^x = a^y\), then \(x = y\).

      Example : Solve for \(x\) if \(9^x = 27\).

      • \(LHS = 9^x = (3^2)^x = 3^{2x}\) and
      • \(RHS = 27 = 3^3\), so
      • \(LHS = RHS\) implies \(2x = 3\) and thus
      • \(x=\frac{3}{2}\)
  • change-of-base from \(a\) to \(e\)

    For any \(a > 0\), \(a^x = e^{(ln a)x}\)

6 Logarithmic Function

6.1 Defintion

If \(a > 0\) and \(a\neq 1\), then the logarithmic function of base \(a\) is defined by \(y = f(x) = log_a x\) for \(x > 0\).

6.2 Properties

  • suppose \(a > 0, a\neq 1, x > 0, y > 0\), and \(r\) is any real number. Then
    • \(log_a x^r = r log_a x\)
    • \(log_a(xy) = log_a x + log_a y\)
    • \(log_a \frac{x}{y} = log_a(x\cdot y^{-1}) = log_a x + log_a y^{-1} = log_a x - log_a y\)
    • \(log_a a = 1\), and thus \(lne = 1\)
    • \(log_a 1 = 0\)
    • \(log_a a^r = r\)
    • (logarithmic equation) if \(log_a x = log_a y\), then \(x = y\)

      Example : Solve for \(x\) if \(3 ln (x) = 2 ln 8\).

      • \(LHS = 3ln(x) = ln(x^3)\) and
      • \(RHS = 2ln8 = ln8^2 = ln 64\), so
      • \(LHS=RHS\) implies \(x^3 = 64\) and thus
      • \(x=4\).
  • change-of-base from \(a\) to \(e\)

    If \(a > 0, a\neq 1, b > 0\) and \(b\neq 1\), then for any \(x > 0\), \(log_a x = \frac{log_b x}{log_b a}\).

    Letting \(b=e\), then we have \(log_a x = \frac{ln(x)}{ln(a)}\).

  • Identity

    For \(a > 0, a\neq 1\) and \(x > 0\), \(y = log_a x\) means \(a^y = x\).

    Thus we have \(y = log_a a^y\) and \(x = a^{log_a x}\) (equivalently, \(y = a^{log_a y}\)). When \(a=e\), we have \[ y = ln(e^y) = e^{lny} \]

6.3 Application of Logarithmic Properties

  • Rewrite a Log Expression

    \(ln \frac{\sqrt{x}e^x}{8x^3}\) \(= ln(\sqrt{x}e^x) - ln(8x^3)\) \(= ln(\sqrt{x}) + ln(e^x) - ln((2x)^3)\)

    \(= ln(x^{1/2}) + ln(e^x) - ln((2x)^3)\) \(= \frac{1}{2} ln(x) + x ln(e) - 3 ln(2x)\)

    \(= \frac{1}{2} ln(x) + x - 3 ln(2x)\)

7 References

  1. Lial, M. L., Greenwell, R. N., Ritchey, N. P. (2011). Calculus with Applications (10th Edition). Boston, MA : Pearson.

Yunfei Wang

2015-11-04 Wed 21:26