Learn

Learning preferences

Make learning more comfortable. Changes apply immediately.

Enlarges page content, including diagrams and their labels. You can also use your browser’s zoom.

Choose the colours that are easiest for you to distinguish. Applies to lesson diagrams and lab plots. Labels, shapes, hatching and line patterns also distinguish meanings. Source photographs and raw image brightness stay unchanged; mask-only views are available for image overlays.

ExampleComparisonSample link

Saved in this browser on this device. Preferences are separate from progress backups.

Lesson 2 of 12

Who chooses first?

Track how witnesses depend on universally chosen values.

Loading your saved responses…

Try

Imagine a game: one person chooses an integer n, then another must choose a greater integer m. The second player can always respond. Now reverse the order: one player must announce m before seeing n. A fixed answer cannot win against every later choice.

Predict

Predict which order allows the witness to depend on n. The symbol ∀ means “for every”; ∃ means “there exists.” A witness is an object establishing an existential assertion. In ∀n∃m, the witness may depend on the previously selected n. In ∃m∀n, one m must work for all n.

Experiment

Draw two choice sequences on paper. In the first, test n=−4,0,11 and respond with n+2. In the second, announce any fixed m and let the other player choose n=m+1. Inspect the failure, then explain why the same response defeats any fixed announcement; the finite game illustrates an argument rather than replacing it.

Understand

Worked argument: for every real x there exists a real y with y>x+1. Let x be arbitrary and choose y=x+2. This is a real number, and y−(x+1)=1>0. The witness therefore works for every permitted x.

The superficially similar claim “there exists a real y such that y>x+1 for every real x” is false. For a proposed y choose x=y. It would require y>y+1, which is impossible. An invalid proof writes y=x+2 after announcing a fixed y: it has secretly allowed y to change with x.

Apply

Before manipulating formulas, annotate which values are arbitrary and which are chosen later. In a refutation, show how to defeat every proposed fixed witness, rather than defeating just one particular number. Your written response should make the order of choices readable in ordinary sentences.

Define arithmetic properties without numeral symbols

Suppose the domain is the standard nonnegative integers. Your formula may use variables, addition, multiplication, equality, logical connectives and quantifiers. It may not contain a numeral, an order sign, division, or exponentiation unless you first define that notation as an abbreviation. This restriction concerns the formula itself, not the ordinary mathematical explanation of what it means.

Start with two properties whose intended numbers are recovered from their behavior:

Z(x)  : ⁣  ⟺    x+x=x,O(x)  : ⁣  ⟺    ∀t  (x⋅t=t).Z(x)\;:\!\iff\;x+x=x,\qquad O(x)\;:\!\iff\;\forall t\;(x\cdot t=t).

Z(x) says x is zero: cancellation in the standard naturals proves the only solution of x+x=x is zero. O(x) says x is one. Substituting the natural number one for t in the semantic proof forces x=1; conversely multiplication by one leaves every natural unchanged. Using a number in this explanation does not insert a forbidden numeral into the displayed defining formula. These are definitions in the standard arithmetic structure, not a proof of arithmetic axioms from logic alone.

Define divisibility and order by witnesses:

D(a,b)  : ⁣  ⟺    ∃k  (a⋅k=b),L(a,b)  : ⁣  ⟺    ∃s  (a+s=b).D(a,b)\;:\!\iff\;\exists k\;(a\cdot k=b),\qquad L(a,b)\;:\!\iff\;\exists s\;(a+s=b).

D(a,b) means a divides b, with the first argument the divisor. In particular every natural divides zero, including zero itself, while zero divides no positive natural. L(a,b) expresses a≤b over the chosen natural domain. If quantifiers instead range over all integers, this same L is true for every pair, since a signed difference always exists. A domain annotation is part of the specification.

A prime is neither zero nor one and admits only a unit factor in every factorization:

P(p)  : ⁣  ⟺    ¬Z(p)∧¬O(p)∧∀a ∀b  (a⋅b=p⇒O(a)∨O(b)).P(p)\;:\!\iff\;\neg Z(p)\land\neg O(p)\land\forall a\,\forall b\;\bigl(a\cdot b=p\Rightarrow O(a)\lor O(b)\bigr).

Here is that formula expanded into the permitted vocabulary, using fresh bound variables at each insertion:

¬(p+p=p)∧¬(∀t  (p⋅t=t))∧∀a ∀b  (a⋅b=p⇒(∀u  (a⋅u=u))∨(∀v  (b⋅v=v))).\neg(p+p=p)\land\neg\bigl(\forall t\;(p\cdot t=t)\bigr)\land\forall a\,\forall b\;\left(a\cdot b=p\Rightarrow \bigl(\forall u\;(a\cdot u=u)\bigr)\lor\bigl(\forall v\;(b\cdot v=v)\bigr)\right).

Parentheses control the scope of each universal quantifier. Bound names must be renamed before substituting a term containing that name. For example O(t) must expand as ∀r(t·r=r), with a fresh r, not ∀t(t·t=t): the latter captures the intended free variable and becomes a different closed assertion. Macro notation is safe only with this capture-avoiding substitution rule.

Prime powers without variable exponentiation

We choose “prime power” to mean a positive exponent: p, p², p³ and so on. Under this convention neither zero nor one qualifies. The formula can characterize prime divisors instead of trying to write a forbidden variable exponent:

Q(n)  : ⁣  ⟺    ¬Z(n)∧¬O(n)∧∃p  (P(p)∧D(p,n)∧∀q  ((P(q)∧D(q,n))⇒q=p)).Q(n)\;:\!\iff\;\neg Z(n)\land\neg O(n)\land\exists p\;\left(P(p)\land D(p,n)\land\forall q\;\bigl((P(q)\land D(q,n))\Rightarrow q=p\bigr)\right).

The named predicates abbreviate the already given constant-free formulas; expanding them with fresh bound variables leaves only the allowed symbols. The proof of meaning uses prime factorization of positive integers. If n is a positive power of prime p, uniqueness of prime factorization shows that every prime divisor of n equals p, and p divides n. Conversely, a positive integer other than one has a finite nonempty prime factorization. Q forces each prime appearing there to be the same p; hence n is a positive power of p. The prime-factorization lesson supplies this dependency; it is not replaced by a finite table. If exponent zero is intended, use O(n)∨Q(n) and explicitly include one.

The existential p and the universal q do different jobs: p supplies a prime divisor, and the universal clause rules out any different one. Observing one divisor proves only the existential part. Finding two distinct prime divisors refutes the universal clause immediately.

One observed divisor is not “only one exists”

Predict whether the number has exactly one distinct prime divisor. Inspecting only a few primes can expose a counterexample, but cannot by itself verify an unbounded universal quantifier.

Inspected primes: 2. Observed divisors: 2. Verdict from this limited inspection: one observed prime: incomplete inspection is not a universal proof.

Fifty-four bounded settings; temporary state and no automatic mastery. A cutoff that includes every possible prime divisor can be justified from the input bound, but that extra bound is a proof obligation, not a consequence of seeing one factor.

The exact finite comparison uses trial factorization: repeatedly strip an integer divisor, then move upward. A stripped divisor is prime because all smaller prime factors have already been removed. When its square exceeds the remaining number, any remaining number greater than one must be prime, since a composite has a factor no larger than its square root. This proves the finite algorithm’s completeness; it does not turn its finite execution into a proof for every natural input.

Changed specification: exactly two distinct prime factors, each used once

Use ∃p∃q(P(p)∧P(q)∧¬(p=q)∧p·q=n). Prime factorization proves it is equivalent to being squarefree with exactly two distinct prime divisors. Both properties matter: a number with two distinct prime divisors may repeat one of them. For example twelve has distinct prime divisors two and three but is not their product. One is squarefree by the usual convention but fails the two-prime requirement. The displayed formula uses no numeral or exponentiation.

The Spring2015 MIT6.042J first midterm, predicate-logic item supplies the restricted-language source requirement. The definitions, capture repair and changed transfer here address that capability with explicit domain and boundary conventions. Public solutions and finite checks do not establish independent learner proof quality.

Continue

Depth: compare ∀x∃y with ∃y∀x for the equation y=x² over real numbers. The first is true and the second is false. Compare them again when the domain of x is a one-element set. Quantifier order matters through both the predicate and its domains.

Apply · explain · revise

Practice and reasoning

Drafts save locally as you type. Reveal worked solutions when useful; the site remembers that exposure. Automatic matches check the requested answer, while written arguments require review against the rubric.

Over standard nonnegative integers, define zero, one, divisibility and ≤ using only variables, addition, multiplication, equality, logic and quantifiers, with no numeral constants. Give a fully expanded prime predicate, prove each meaning and handle zero divisibility. Explain why substituting a free variable t into the macro O(x)=∀t(x·t=t) requires renaming its bound variable. What changes in the proposed order predicate over all integers?

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

Using previously defined constant-free predicates Z, O, D, P, express that n is a prime power with positive exponent without using exponentiation in the formula. Prove both directions from prime factorization, state zero/one conventions, and change the definition to allow exponent zero. Explain why seeing only prime divisor 2 while searching through 2 does not certify n=12 is a prime power.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

Using the rule m=n+1, which witness m works when n=−7?

Integers, fractions and finite decimals are accepted. Expressions such as sqrt(2) are not parsed by this checker.

Which statement is true over integers?

Your response

Prove that for every integer n there is an integer m greater than n.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

Refute: there exists an integer m greater than every integer n.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

Reflect and continue

Before marking this lesson complete, explain one key idea without the worked solution and identify a condition that matters. Marking complete records participation, not independent mastery.