The Concept of a Function

A function captures the idea that one quantity is uniquely determined by another. This section introduces functions informally through real-world examples and establishes the notation $y = f(x)$ that will be used throughout all of mathematics and science.

Quick Reference

Concept Description
Function A rule that assigns exactly one output to each input
Independent variable The input; the variable we choose freely
Dependent variable The output; its value depends on the input
Function notation $y = f(x)$; read "y equals f of x"
Explicit function $y$ is isolated: $y = f(x)$
Implicit function $x$ and $y$ are mixed in an equation: $f(x,y) = 0$

What Is a Function?

We intuitively say that a variable is a function of a second variable when its value depends on the value of the second variable and can be uniquely calculated by some rule when the value of the second variable is given. The first variable is the dependent variable and the second is the independent variable.

Examples of functions from science and everyday life.

  • The temperature at which pure water boils is a function of altitude above sea level.
  • The area of a circle $A$ is a function of its radius $r$: given $r$, we compute $A = \pi r^2$ uniquely. Conversely, the radius is also a function of the area: $r = \sqrt{A/\pi}$. In this example, either variable can serve as the independent one.
  • In a triangle, if the lengths $a$ and $b$ of two sides are fixed, then the length of the third side $c$ is determined once the included angle $\gamma$ is chosen: $c = \sqrt{a^2 + b^2 - 2ab\cos\gamma}.$ Here $c$ is a function of $\gamma$ (with $a$ and $b$ treated as parameters).
  • The federal income tax rate for a single person is a function of taxable income: different income brackets map to specific rates.

A variable can be a function of more than one other variable. For example, the volume of a circular cylinder $V$ depends on both the base radius $r$ and the height $h$:

$V = \pi r^2 h.$

We will study multivariable functions separately.

The Uniqueness Requirement

The word uniquely is crucial. Consider the equation

$y = \sqrt{x}.$

For each $x \geq 0$, this gives exactly one value of $y$, so $y$ is a function of $x$. But

$y = x^2$

defines $y$ as a function of $x$ (each $x$ gives one $y$), yet $x$ is not a function of $y$: if $y = 4$, then $x = +2$ or $x = -2$, which are two different values. Since one input ($y = 4$) produces two outputs for $x$, $x$ is not a function of $y$ in this case.

Function Notation

In mathematics, we often wish to refer to a generic function without specifying any particular formula, table, or graph. To say that $y$ is a function of $x$, we write

$y = f(x),$

read as "$y$ is equal to $f$ of $x$." Here $f$ represents the function itself, that is, the rule or procedure associating values of $x$ with values of $y$.

Other common notations include $g(x)$, $\phi(x)$, $F(x)$, $f'(x)$, $s(x)$, and so on. When more than one function appears in a problem, we use different letters to distinguish them: $f_1(x)$, $f_2(x)$, $f_3(x)$, etc.

A function can also be thought of as a machine or computer program: for each allowable input, it returns exactly one output.

A conceptual diagram of a function as a machine processing input x to output f(x)
A function can be thought of as a machine: for each allowable input $x$, it produces exactly one output $f(x)$.

The map notation $x \mapsto x^2$ is a compact way to say "the function that sends each $x$ to its square."

If $f(x) = 4x^2 - 5x + 1$, find $f(-1)$, $f(0)$, $f(t)$, $f(u)$, $f(b+1)$, and $f(x+h)$.

Solution We simply replace $x$ with whatever appears inside the parentheses: $f(-1) = 4(-1)^2 - 5(-1) + 1 = 4 + 5 + 1 = 10.$ $f(0) = 4(0)^2 - 5(0) + 1 = 1.$ Because the name of the variable does not matter: $f(t) = 4t^2 - 5t + 1, \qquad f(u) = 4u^2 - 5u + 1.$ $f(b+1) = 4(b+1)^2 - 5(b+1) + 1 = 4b^2 + 8b + 4 - 5b - 5 + 1 = 4b^2 + 3b.$ $ \begin{aligned} f(x+h) &= 4(x+h)^2 - 5(x+h) + 1 \\ &= 4(x^2 + 2xh + h^2) - 5x - 5h + 1 \\ &= \underbrace{4x^2 - 5x + 1}_{f(x)} + 8xh - 5h + 4h^2. \end{aligned} $

Arrow Diagrams

Another way to picture a function is with an arrow diagram. Each element $x$ in set $A$ (the domain) is connected by an arrow to its unique image $f(x)$ in set $B$ (the codomain).

An arrow diagram mapping elements from domain set A to codomain set B, representing a valid function.
$f$ is a function: each element in $A$ maps to exactly one element in $B$. Two elements may share the same image (as the two elements mapping to the heart show), but that is still a valid function.
An arrow diagram of a relation where one input maps to two outputs, illustrating why it is not a function.
$g$ is not a function: one element $\star$ in $A$ maps to two different elements in $B$, violating the uniqueness requirement.

Explicit and Implicit Functions

An explicit function expresses the dependent variable directly in terms of the independent variable, for example $y = f(x)$. The form $y = x^2 + 3$ is explicit because $y$ is isolated.

An implicit function involves an equation where the dependent and independent variables are intermixed and the dependent variable is not isolated. For example, $x^2 + y^2 = 1$ and $x^3 - 3xy + y^3 = 0$ define $y$ implicitly in terms of $x$. The notation $f(x, y) = 0$ indicates that $x$ and $y$ are implicit functions of each other.

In this course, we almost always work with explicit functions. Implicit functions are encountered occasionally in calculus.

Frequently Asked Questions

What does "uniquely determined" mean for a function? It means that for each input there is exactly one output. If two different outputs could correspond to the same input, the relationship would not be a function. For example, $y^2 = x$ is not a function because $x = 4$ gives both $y = 2$ and $y = -2$.

Is $f(x)$ the same as $f$? Not technically. $f$ is the function (the rule), while $f(x)$ is the value of that function at the specific input $x$. We often say "the function $f(x)$" informally, but rigorously $f$ is the function and $f(x)$ is a number.

Can a function have more than one input variable? Yes. For example, the formula for the volume of a cylinder, $V = \pi r^2 h$, expresses the volume $V$ as a function of two variables: its radius $r$ and its height $h$. Such functions are called multivariable functions and are studied in more advanced courses.

What is the difference between explicit and implicit functions? In an explicit function, the dependent variable is solved for directly: $y = x^2 + 3$. In an implicit function, the relationship is expressed as an equation involving both variables without isolating one: $x^2 + y^2 = 1$. Every explicit function can be written implicitly ($y - x^2 - 3 = 0$), but not every implicit equation can easily be solved explicitly.

Why is $y = \sqrt{x}$ a function but $y^2 = x$ is not? $y = \sqrt{x}$ gives exactly one nonnegative value for each $x \geq 0$, so it is a function. But $y^2 = x$ gives two values of $y$ for each positive $x$ (one positive and one negative), violating the uniqueness requirement for functions.