Curious Minds

Clear answers to science and history questions

Even and Odd Functions: The Simple Test

· 5 min read · Science

A function is even if f(−x) = f(x) for every x in its domain, and odd if f(−x) = −f(x). In plain terms, an even function's graph is a mirror image across the y-axis, while an odd function's graph looks the same after a 180° rotation about the origin.

Where the Names Come From

The terms “even” and “odd” refer to the parity of the exponents in a polynomial, not to the parity of the function's values. A polynomial made only of even powers of x — such as x², x⁴, or a constant — is an even function. A polynomial made only of odd powers — such as x, x³, or x⁵ — is an odd function. This connection is exact for polynomials, but the definitions apply to any function, including trigonometric, exponential, and piecewise functions.

The concept sits inside a broader idea called symmetry. Even and odd are the two simplest symmetries a graph can have with respect to the coordinate axes. Many functions have neither symmetry, and that is perfectly normal.

The Algebraic Test, Step by Step

To classify a function, substitute −x for x and simplify. The result tells you which category, if any, the function belongs to.

  1. Write the function as f(x).
  2. Replace every x with −x to get f(−x).
  3. Simplify the expression using the rules (−x)² = x², (−x)³ = −x³, and so on.
  4. Compare the simplified f(−x) with the original f(x). If they are identical, the function is even. If f(−x) equals −f(x), it is odd. If neither holds, it is neither.

For example, take f(x) = x⁴ − 3x² + 5. Substituting gives (−x)⁴ − 3(−x)² + 5 = x⁴ − 3x² + 5, which is the original expression, so the function is even. Now take g(x) = x³ − 4x. Substituting gives (−x)³ − 4(−x) = −x³ + 4x = −(x³ − 4x) = −g(x), so g is odd.

A function like h(x) = x² + x fails both tests: h(−x) = x² − x, which is neither h(x) nor −h(x). Such a function is simply neither even nor odd.

What the Graph Looks Like

The algebraic definitions have direct visual consequences.

  • Even function: the graph is symmetric about the y-axis. If the point (a, b) lies on the graph, so does (−a, b). The parabola y = x² is the classic example.
  • Odd function: the graph is symmetric about the origin. If (a, b) lies on the graph, so does (−a, −b). The line y = x and the curve y = x³ illustrate this.
  • Neither: the graph shows no such symmetry. The curve y = x² + x is an example.

A quick glance at a graph can suggest the answer, but the algebraic test is the reliable check. Graphs can be misleading near the edges of the domain or when only part of the curve is visible.

Special Cases and Common Examples

Several familiar functions fall neatly into one category or the other.

  • Even: x², x⁴, cos x, |x|, and any constant function. The constant function f(x) = c satisfies f(−x) = c = f(x).
  • Odd: x, x³, sin x, tan x, and the reciprocal function 1/x. Note that 1/x is undefined at x = 0, but the definition only requires the symmetry to hold wherever the function is defined.
  • Neither: x² + x, eˣ, ln x, and most polynomials that mix even and odd powers. The exponential function eˣ is neither because e⁻ˣ is not equal to eˣ or −eˣ.

The zero function f(x) = 0 is a special case: it is both even and odd, because 0 = −0. This is the only function that satisfies both definitions simultaneously.

Rules for Combining Functions

When even and odd functions are added, multiplied, or composed, the result often follows a predictable pattern similar to the rules for adding and multiplying even and odd integers.

  • Even + even = even; odd + odd = odd.
  • Even × even = even; odd × odd = even; even × odd = odd.
  • The composition of two even functions is even; the composition of two odd functions is odd; the composition of an even and an odd function is even.

These rules are handy for checking answers quickly, but they apply only when both functions are defined on the same symmetric domain. A function defined on an interval that is not symmetric about zero — say, [0, 5] — cannot be classified as even or odd under the standard definition, because −x may fall outside the domain.

Why the Domain Matters

The definition requires that if x is in the domain, then −x is also in the domain. This condition is easy to overlook. The function f(x) = x² on the interval [0, 3] is not even in the formal sense, even though its formula looks even, because negative inputs are not allowed. For the symmetry test to work, the domain must be symmetric about zero, as in (−∞, ∞) or [−a, a].

This is why functions like the square root, √x, are neither even nor odd: their domain is [0, ∞), which is not symmetric. The same applies to logarithms.

Frequently Asked Questions

Can a function be both even and odd?

Yes, but only one function does it: the zero function f(x) = 0. For any other function, the conditions f(−x) = f(x) and f(−x) = −f(x) would force f(x) = 0 everywhere.

Is every function either even or odd?

No. Most functions are neither. The categories even and odd describe specific symmetries, and many functions — such as x² + x or eˣ — have neither symmetry.

How do I tell if a graph is even or odd?

An even graph is unchanged when reflected across the y-axis. An odd graph is unchanged when rotated 180° about the origin. If neither reflection nor rotation leaves the graph unchanged, it is neither.

Do even and odd functions have to be polynomials?

No. The definitions apply to any function, including trigonometric, rational, and piecewise functions. Sine is odd, cosine is even, and the absolute value function is even.

What is the practical use of even and odd functions?

Symmetry simplifies calculations. Integrals of odd functions over symmetric intervals are zero, and Fourier series separate naturally into even and odd components. Engineers and physicists use these properties to reduce work when analyzing signals and systems.

Can a function be even or odd if it has a vertical asymptote?

Yes, as long as the domain is symmetric about zero. The function 1/x is odd and has a vertical asymptote at x = 0. The symmetry holds on both sides of the asymptote.

In this article
  1. Where the Names Come From
  2. The Algebraic Test, Step by Step
  3. What the Graph Looks Like
  4. Special Cases and Common Examples
  5. Rules for Combining Functions
  6. Why the Domain Matters
  7. Frequently Asked Questions