Skip to main content

Someone wanted to learn this too, so Grasp built them a personal learning path.

You can keep exploring this one or create your own

Constructive Proofs in Mathematics

Hello! Welcome to your next lesson in our journey through the foundations of mathematics.

In our last lesson, we analyzed the deep philosophical differences between classical and intuitionistic logic. We saw that the intuitionist's rejection of the Law of the Excluded Middle isn't just a technicality; it stems from an anti-realist philosophy that equates truth with constructive provability. This led us to the distinction between non-constructive proofs, which merely show existence, and constructive proofs, which must provide a method for finding the object in question.

Today, we will move from theory to practice. Your learning outcome for this lesson is to apply constructive reasoning to a simple mathematical proof. We'll see how the philosophical principles we discussed translate into a specific style of mathematical argumentation, one that you'll find is closely related to the design of algorithms.

1. What Makes a Proof "Constructive"?

At its core, constructive reasoning demands that proofs of existence be effective.

  • To prove a statement of the form "There exists an such that is true," a constructive proof must exhibit a specific example of such an or provide a method for finding one.
  • To prove a statement of the form " or ," a constructive proof must either prove or prove .

This is a direct departure from classical logic, where you can prove existence by contradiction (showing that non-existence is impossible) or prove a disjunction using the Law of the Excluded Middle without committing to either disjunct.

Recitation 7: Existence Proofs and Mathematical Induction

To start with a clear definition, let's look at a short note from a math course that draws this distinction.

Please read the first three paragraphs, up to 'Exercise 1'. Focus on the distinction made between a constructive and a non-constructive proof.

The key idea is that a constructive proof contains more information than a classical one. It doesn't just convince you that something is true; it shows you how it's true by providing a concrete witness. This "witness" is often the result of an algorithm.

The video below explains this "constructive" demand in the context of disjunctions, which follows the same principle as existence claims.

Natural Deduction for Intuitionistic Logic | Attic Philosophy

The 'Natural Deduction for Intuitionistic Logic' video from Attic Philosophy explains a key feature of constructive reasoning known as the Disjunction Property.

Please watch from 14:45 to 16:20. The speaker explains that to prove a disjunction (A or B) in intuitionistic logic, you must be able to construct a proof for one of the disjuncts. This is the constructive demand in action.

2. An Example: From a Non-Constructive to a Constructive Proof

Let's see this distinction play out in a core result from number theory. You know that for any two positive integers and , their greatest common divisor (GCD) can be expressed as a linear combination of them, i.e., for some integers and .

A classical proof can establish the existence of and non-constructively. The following paper provides an excellent, rigorous treatment of this topic suitable for your background.

Classical and constructive logic

The paper 'Classical and constructive logic' by Jeremy Avigad, a prominent logician and mathematician, contains a perfect example for our purposes. It first gives a classical, non-constructive proof for a property of the GCD and then shows how to make it constructive.

Please read Section 2, 'Examples from number theory'. First, focus on the non-constructive proof of Theorem 2.3. Pay close attention to the step where the author defines the set B and invokes its 'smallest element,' d. This is the non-constructive leap.

The classical proof you just read is elegant, but from a constructive viewpoint, it's unsatisfying. It defines a set B = {au + bv | u, v ∈ ℤ and au + bv > 0} and then asserts that because B is a non-empty set of positive integers, it must have a smallest element, d. This relies on the Well-Ordering Principle. While classically valid, this step gives us no procedure for finding d, nor the corresponding x and y. It proves that x and y exist without constructing them.

3. The Algorithm as Proof: Euclid's Method

How would we make this proof constructive? We need an explicit procedure—an algorithm—that takes a and b as input and produces d, x, and y as output. As Avigad's paper notes, this procedure is precisely the Euclidean algorithm.

A constructive proof is not just the algorithm itself, but also the arguments that prove the algorithm works as intended. This includes:

  1. A proof that the algorithm always terminates.
  2. A proof that upon termination, it produces the correct output.

The following lecture explains this beautifully, framing Euclid's algorithm as a paradigm of constructive mathematics.

Constructive Mathematics: Introduction to algorithms: Euclid's method - 1st Year Student Lecture

This lecture from the University of Oxford introduces constructive mathematics by diving deep into Euclid's algorithm. It demonstrates not only the algorithm but also the constructive proofs of its termination and correctness.

Please watch the following segments: 27:35 - 33:34: The presenter walks through Euclid's algorithm with concrete examples and formalizes it. 37:59 - 39:05: A constructive proof that the algorithm always terminates. 39:05 - 44:17: A constructive proof that the algorithm correctly computes the GCD.

The proof of termination in the video is constructive because it relies on the property of a strictly decreasing sequence of natural numbers, which must eventually reach zero in a finite number of steps. The proof of correctness is constructive because it demonstrates step-by-step how the property of being the GCD is maintained through each iteration of the algorithm.

4. Your Turn: Applying Constructive Reasoning

Now it's time to apply these concepts yourself. The learning outcome is not just to understand but to apply.

Exercise 1: Re-interpreting a Classical Proof

Euclid's proof of the infinitude of primes is often presented as a proof by contradiction, which can have a non-constructive flavor. However, as Avigad's paper mentions, it contains the kernel of an algorithm.

Your task:
Read the two proofs of Theorem 2.2 ("There are infinitely many prime numbers") in Section 2 of Avigad's paper (LINK).

  1. Describe the algorithm implicit in the second, re-worded proof for finding a prime number larger than a given number M.
  2. Is this a good algorithm? (Think about computational efficiency).
Show answer
  1. The Algorithm:

    • Input: A natural number M.
    • Step 1: Generate a list of all prime numbers less than or equal to M: p1, p2, ..., pk.
    • Step 2: Calculate the number N = (p1 * p2 * ... * pk) + 1.
    • Step 3: Find any prime factor of N. (This requires a separate factorization algorithm).
    • Output: That prime factor q. The proof guarantees q will be larger than M.
  2. Efficiency: This is not a very efficient algorithm. Step 1 requires finding all primes up to M, which can be computationally intensive. Step 2 involves calculating N, which can become astronomically large very quickly. Step 3, factoring this massive number N, is computationally very hard. So while it's a valid constructive proof (it specifies a procedure), it's not a practical one for finding large primes.

Exercise 2: A Concrete Application

Let's use the constructive method we studied to solve a concrete problem.

Your task:
Let a = 288 and b = 168 (one of the examples from the Oxford video).

  1. Use the Euclidean algorithm to find the greatest common divisor, d.
  2. Now, perform the more advanced constructive task: find integers x and y such that 288x + 168y = d. To do this, work backward through the steps of your algorithm, substituting the expression for the remainder from each previous line.
Show answer
  1. Finding the GCD:

    • 288 = 1 * 168 + 120
    • 168 = 1 * 120 + 48
    • 120 = 2 * 48 + 24
    • 48 = 2 * 24 + 0
      The last non-zero remainder is 24, so d = 24.
  2. Finding x and y (Extended Euclidean Algorithm):
    We start from the second-to-last line and work our way back up, isolating the remainder at each step.

    • From 120 = 2 * 48 + 24, we get:
      24 = 120 - 2 * 48
    • Now substitute the expression for the previous remainder, 48, from the line 168 = 1 * 120 + 48:
      24 = 120 - 2 * (168 - 1 * 120)
      24 = 120 - 2 * 168 + 2 * 120
      24 = 3 * 120 - 2 * 168
    • Finally, substitute the expression for 120 from the first line, 288 = 1 * 168 + 120:
      24 = 3 * (288 - 1 * 168) - 2 * 168
      24 = 3 * 288 - 3 * 168 - 2 * 168
      24 = 3 * 288 - 5 * 168
    • So, we have the form d = ax + by: 24 = 288(3) + 168(-5).
    • Our constructed integers are x = 3 and y = -5.

Conclusion

In this lesson, we bridged the gap between the philosophy of intuitionism and the practice of constructive mathematics. You have seen that applying constructive reasoning means thinking algorithmically—insisting that a proof not only demonstrates existence but provides a clear recipe for construction.

Here are the key takeaways:

  • A constructive proof of existence must provide a method for finding the object whose existence it asserts.
  • This principle is embodied in procedures like the Euclidean algorithm, which serves as a proof that is also a computation.
  • A complete constructive proof includes not just the algorithm, but also constructive arguments for its termination and correctness.
  • We can often re-read classical proofs to extract their implicit constructive content, turning them into explicit algorithms.

Preview of the Next Lesson:
We have now examined three competing foundational programs: Logicism, Formalism, and Intuitionism, focusing on their logical and philosophical underpinnings. We are now prepared to move into the second module on mathematical foundations, which deals with the framework that ultimately became dominant in modern mathematics. In our next lesson, we will begin this by exploring the world of set theory. The learning outcome will be to describe the iterative conception of the set-theoretic universe underlying ZFC. We will be shifting our focus from the rules of reasoning to the fundamental objects that mathematicians reason about.

Can't find a good explanation? Sign up and we'll make it for you

Sign up