Invariants Examples in Math

Start with the recap, study the fully worked examples, then use the practice problems to check your understanding of Invariants.

This page combines explanation, solved examples, and follow-up practice so you can move from recognition to confident problem-solving in Math.

Concept Recap

Quantities or properties that remain unchanged during a process, operation, or transformation—values that stay the same no matter how the system is rearranged or acted upon.

Rearranging an equation keeps both sides equal—equality is the invariant.

Read the full concept explanation →

How to Use These Examples

  • Read the first worked example with the solution open so the structure is clear.
  • Try the practice problems before revealing each solution.
  • Use the related concepts and background knowledge badges if you feel stuck.

What to Focus On

Core idea: Finding what doesn't change helps solve problems and prove theorems.

Common stuck point: Identifying which properties are invariant under which transformations.

Sense of Study hint: Ask yourself: what stays the same before and after the transformation? Write it down and verify with a specific case.

Worked Examples

Example 1

medium
A sequence starts at 1 and each term is 3 times the previous minus 2: \(a_{n+1} = 3a_n - 2\). Show that the quantity \(a_n - 1\) grows by a factor of 3 each step (i.e., \(a_n - 1 = 3^{n-1}(a_1 - 1)\) is an invariant structure).

Solution

  1. 1
    Define \(b_n = a_n - 1\). Then \(b_{n+1} = a_{n+1} - 1 = (3a_n - 2) - 1 = 3a_n - 3 = 3(a_n-1) = 3b_n\).
  2. 2
    So \(b_n\) forms a geometric sequence: \(b_n = b_1 \cdot 3^{n-1}\).
  3. 3
    With \(a_1=1\): \(b_1 = 0\), so \(b_n = 0\) for all \(n\), meaning \(a_n = 1\) for all \(n\).
  4. 4
    Invariant: if \(a_1=1\), the fixed point \(a=1\) is preserved.

Answer

\(a_n = 1\) for all \(n\); fixed point is an invariant
An invariant is a quantity that doesn't change under the transformation. Here \(a_n = 1\) is a fixed point of the recurrence — once there, the sequence stays.

Example 2

hard
In a game, you can add 3 or subtract 5 from a number. Starting at 0, can you reach 1? Use an invariant (parity or modular) argument.

Practice Problems

Try these problems on your own first, then open the solution to compare your method.

Example 1

medium
Show that for any right triangle with legs \(a, b\) and hypotenuse \(c\), the quantity \(a^2 + b^2 - c^2 = 0\) is an invariant (Pythagorean theorem).

Example 2

hard
A 2×n grid of squares is colored with 2 colors. You repeatedly flip all colors in any row or column. Show that the parity of the number of black squares is an invariant.

Related Concepts

Background Knowledge

These ideas may be useful before you work through the harder examples.

equal