KnowledgeInSight
What Mathematicians Do
0% of Course 5 complete

Module 1 · Lesson 2

Logic and Set Theory: Gödel's incompleteness, the continuum hypothesis, and logic in circuits and databases

You'll see how Boole's algebra of logic became the circuitry of every computer and how set theory became the language of databases. You'll also meet Gödel's proof that any consistent system of rules for arithmetic leaves some true statements unprovable within it, and a question about infinity that mathematics has shown it cannot settle.

What you will be able to do

  • Explain what Gödel's incompleteness theorems show, and describe how logic is used in computing.

0% of this lesson · 10 items · 1h 33m total · 1h 18m without the optional journal

Contents of this lesson10 items
  1. ReadingYour Phone Is Made of Logic3 min
  2. ReadingLogic Gates and Digital Circuits4 min
  3. ReadingSets and Logic in Databases4 min
  4. ReadingGödel's Incompleteness Theorems4 min
  5. ReadingThe Continuum Hypothesis and What Mathematics Can't Decide4 min
  6. Guided ReadingGuided Walkthrough: Building an Adding Circuit from Logic Gates7 min
  7. Guided ConversationWhat Does It Mean That Some Truths Can't Be Proved?12 min
  8. Journal · optionalWhen a True Statement Can't Be Proved15 min
  9. Knowledge CheckGödel's incompleteness, the continuum hypothesis, and logic in circuits and databases10 min
  10. Graded QuizLogic and Set Theory30 min

Report an issue on this page

Reading 3 min Done

Your Phone Is Made of Logic

The phone or computer you're reading this on contains billions of tiny electronic switches. Each one is either on or off, and nothing else. Yet together they display text, play video, and recognize your face. How do on and off add up to all that?

Part of the answer is a piece of 19th-century mathematics. In 1854, George Boole published An Investigation of the Laws of Thought, which treated logic as a kind of algebra (O'Connor and Robertson 2004). In Boole's algebra, a statement is either true or false, and statements combine through "and," "or," and "not." "It is raining and it is cold" is true only when both parts are true. "It is raining or it is cold" is true when at least one part is. "Not raining" flips true to false and false to true.

Now read "true" as "on" and "false" as "off." Two switches wired one after the other let current through only when both are on: that's "and." Two switches wired side by side let current through when either is on: that's "or." A switch that opens when its control is on, and closes when it's off, behaves like "not."

In 1938, Claude Shannon published a paper making this connection precise for relay circuits, which are built from electrically controlled switches. He showed that Boole's algebra could describe networks of relay switches, so a circuit could be designed and simplified on paper, by algebra, before anyone built it (Shannon 1938). His paper even worked out a circuit that adds numbers written in base two, using nothing but switches.

Modern chips use transistors instead of relays, and they are vastly smaller and faster. The design idea is the same. Engineers build small units called logic gates, each of which computes "and," "or," or "not" on signals that stand for true and false. They combine gates into circuits that add, compare, and store numbers, and combine those circuits into processors.

So when your phone checks whether a passcode matches, the check comes down to Boolean logic in hardware: is this digit equal to that one, and the next, and the next? When it adds two numbers, it does so with circuits built from the same three operations Boole wrote down.

That is one thing logic offers. Its rules are precise enough to be built into machines, which then follow them at enormous speed. It also raises a question that logic itself has answered: if machines can carry out any rule-following reasoning, are there truths that no system of rules can reach?

This content reflects the field as of October 2026.

References

  • O'Connor, J. J., and E. F. Robertson. 2004. "George Boole." MacTutor History of Mathematics Archive, University of St Andrews. Last updated June 2004.
  • Shannon, Claude E. 1938. "A Symbolic Analysis of Relay and Switching Circuits." Transactions of the American Institute of Electrical Engineers 57: 713–723.
    • Free: None confirmed
    • Free companion: O'Connor and Robertson 2004

Reading 4 min Done

Logic Gates and Digital Circuits

Introduction

Every digital device, from a microwave timer to a data center, computes with combinations of the same three logical operations: "and," "or," and "not." What turns those operations into hardware is a translation from true and false to electrical signals. This reading explains bits, logic gates, the 1938 paper that connected logic to circuits, and how gates combine to add, compare, and store.

True and False as 1 and 0

A bit is a single unit of information with exactly two possible values, written 1 and 0. In a circuit, a bit is a signal: a higher voltage for 1 and a lower one for 0, for example. In logic, the same two values can stand for true and false.

That double reading is the whole trick. If 1 means true and 0 means false, then any rule of logic about true and false becomes a rule about signals. And any whole number can be written in base two, using only the digits 1 and 0, so the same signals can carry numbers too.

Gates Are Truth Tables in Hardware

A truth table lists every combination of true and false for the inputs of a logical operation, and the result for each. A logic gate is a small electronic component that takes one or more bits as input and produces an output bit according to a fixed truth table.

Input AInput BAND gateOR gate
0000
0101
1001
1111

An AND gate outputs 1 only when both inputs are 1. An OR gate outputs 1 when at least one input is 1, including when both are. A NOT gate has one input and flips it: 0 becomes 1, and 1 becomes 0. Each gate is the hardware version of one of logic's connectives.

Shannon's Connection

The algebra behind these tables is Boolean algebra: the algebra of the two values true and false (or 1 and 0) and the operations "and," "or," and "not." It takes its name from George Boole, whose 1854 Laws of Thought reduced logic to a simple algebra (O'Connor and Robertson 2004).

In 1938, Claude Shannon published "A Symbolic Analysis of Relay and Switching Circuits." Relays are switches that open or close under electrical control. Shannon showed that networks of relays obey the same algebra as statements in logic (Shannon 1938). In terms of whether current gets through, switches in series act like "and," and switches in parallel act like "or." That meant an engineer could write a circuit as an algebraic expression, simplify the expression, and build the simpler circuit that does the same job. Shannon's examples included a circuit that adds two numbers in base two (Shannon 1938).

Combining Gates

A circuit, in this sense, is a network of logic gates connected so that the outputs of some gates feed the inputs of others. Three kinds of circuit show how far the three operations reach:

  • Adding. To add two one-digit binary numbers, you need a sum digit and a carry digit. The carry is the AND of the inputs. The sum is 1 when exactly one input is 1, which takes a few gates to build. Chaining such adders adds numbers of any length.
  • Comparing. Two bits are equal when both are 1 or both are 0. That's (A AND B) OR (NOT A AND NOT B). Repeat it for every pair of digits and combine the results with AND, and the circuit checks whether two whole numbers match.
  • Storing. Wire two gates so that each one's output feeds back into the other's input, and the pair settles into one of two stable states. It holds a 1 or a 0 until a new signal changes it. Some kinds of computer memory are built from huge numbers of such circuits.

Today's chips use transistors rather than relays as their switches, and they pack in billions of them. The logical design is still written in Boolean algebra.

Conclusion

Digital circuits work because one pair of values can be read three ways: true and false, 1 and 0, on and off. Logic gates compute "and," "or," and "not" on those values, and Shannon's 1938 paper showed that the algebra of logic describes switching circuits. Adding, comparing, and storing all come from combining the same few gates.

This content reflects the field as of October 2026.

Key Terms

  • Bit: A single unit of information with exactly two possible values, written 1 and 0, which can also stand for true and false.
  • Logic gate: A small electronic component that takes one or more bits as input and produces an output bit according to a fixed truth table.
  • Boolean algebra: The algebra of the two values true and false (or 1 and 0) and the operations "and," "or," and "not."
  • Circuit: A network of logic gates connected so that the outputs of some gates feed the inputs of others.

References

  • O'Connor, J. J., and E. F. Robertson. 2004. "George Boole." MacTutor History of Mathematics Archive, University of St Andrews. Last updated June 2004.
  • Shannon, Claude E. 1938. "A Symbolic Analysis of Relay and Switching Circuits." Transactions of the American Institute of Electrical Engineers 57: 713–723.
    • Free: None confirmed
    • Free companion: O'Connor and Robertson 2004

Reading 4 min Done

Sets and Logic in Databases

Introduction

When you filter an online store for shoes that are waterproof and under a certain price, you're asking a logical question about a set. Behind many such searches sits a database designed around set theory and logic. This reading explains the relational model of data, how a query works as a logical condition, and the set operations that answer it.

Codd's Relational Model

In 1970, Edgar F. Codd, working at IBM's research laboratory in San Jose, California, published "A Relational Model of Data for Large Shared Data Banks." His starting point was a complaint about how data systems were organized. Programs had to know how the data was laid out inside the machine, so a change in storage could break them. Codd argued that future users of large data banks "must be protected from having to know how the data is organized in the machine" (Codd 1970).

His proposal was to describe all data in terms of mathematical relations. A relational database is a collection of data organized as tables, in which each table is treated as a set of rows. A table has named columns, and each row records one item, such as one customer or one order. Codd defined a relation as a set of rows of values and noted that the order of the rows doesn't matter, just as the order of members doesn't matter in a set (Codd 1970).

CustomerProduct
AnaTent
BenTent
BenStove
ChenTent
DevTent
DevStove
EliStove

A Query Is a Logical Condition

A query is a request for the rows of a database that satisfy a stated condition. The condition is a statement in logic, built from simple tests joined by "and," "or," and "not." Codd proposed a query language based on predicate calculus, the part of formal logic that handles conditions together with words such as "all" and "some" (Codd 1970).

Take the table of orders above. Let T be the set of customers who ordered a tent: Ana, Ben, Chen, and Dev. Let S be the set who ordered a stove: Ben, Dev, and Eli. Many questions about these customers become combinations of the two sets.

Set Operations as Everyday Searches

Because tables are sets, the usual operations of set theory apply to them (Codd 1970). Three do most of the work.

QuestionLogical conditionSet operationAnswer
Who ordered a tent and a stove?in T and in SIntersectionBen, Dev
Who ordered a tent or a stove?in T or in SUnionAna, Ben, Chen, Dev, Eli
Who ordered a tent and not a stove?in T and not in SDifferenceAna, Chen

The intersection of two sets is the set of members that belong to both. The union of two sets is the set of members that belong to at least one of them. The difference is the set of members of the first that are not in the second. Each operation matches a connective from logic: "and" gives intersection, "or" gives union, and "and not" gives difference.

The match isn't a coincidence. A set can be described by the condition its members satisfy, so combining conditions with connectives and combining sets with operations are two views of the same act. A search filter on a website is a query of this kind, even when you never see the logic written out.

Why the Design Spread

Codd's model separated the logical question from the physical storage. A query says which rows are wanted, in terms of logic, not how to find them on disk. The system works out the how. That means the storage can be reorganized, or a faster search method added, without changing the questions people ask (Codd 1970).

Databases built on the relational model became widespread in business and government in the decades after 1970, and they remain in wide use alongside newer designs.

Conclusion

Relational databases treat tables as sets of rows and answer questions with logical conditions. Intersection, union, and difference correspond to "and," "or," and "and not." Codd's 1970 model made answers depend on logic rather than on how the data happens to be stored.

This content reflects the field as of October 2026.

Key Terms

  • Relational database: A collection of data organized as tables, in which each table is treated as a set of rows.
  • Table: In a relational database, a set of rows under named columns, each row recording one item.
  • Query: A request for the rows of a database that satisfy a stated logical condition.
  • Intersection: The set of members that belong to both of two sets, matching "and" in logic.
  • Union: The set of members that belong to at least one of two sets, matching "or" in logic.

References

Reading 4 min Done

Gödel's Incompleteness Theorems

Introduction

Mathematics has a reputation as the one place where every question has an answer and every true statement can be proved. In 1931, Kurt Gödel showed that this reputation needs a careful correction. This reading explains the hope his theorems answered, what the two theorems say, the idea behind the proof, and what they don't mean.

Hilbert's Hope

By the 1920s, logic had given mathematics a way to write proofs as formal systems. A formal system is a precise language together with a list of starting statements, called axioms, and exact rules for deriving new statements from them, so that whether a proof is correct can be checked mechanically.

The mathematician David Hilbert led an effort, now called Hilbert's program, to put all of mathematics into such systems and then prove, by safe and elementary means, that they would never lead to a contradiction (Raatikainen 2025). A system is consistent if it never proves both a statement and its opposite. Hilbert also expected every mathematical question to have a definite answer (Horsten 2022). The hope had grounds. Formal systems had made proofs checkable by rule, so it seemed reasonable that one well-chosen system could settle every question and certify its own reliability.

A system is complete if, for every statement in its language, it proves either the statement or its opposite.

The First Theorem

Gödel first described his results to colleagues in 1930 and published them in January 1931 (Raatikainen 2025). The first incompleteness theorem says, in plain words: any consistent formal system in which a certain amount of basic arithmetic can be carried out is incomplete (Raatikainen 2025). There are statements in its language that it can neither prove nor disprove.

A statement of that kind is an undecidable statement for that system: the system's axioms and rules settle it neither way. The theorem applies to any system that meets its conditions, not just to one particular choice of axioms. Adding the undecidable statement as a new axiom doesn't help, because the stronger system has undecidable statements of its own.

The Second Theorem

The second incompleteness theorem says that such a system, if it is consistent, can't prove its own consistency (Raatikainen 2025). The system can't certify itself. Any proof that it is free of contradiction has to use assumptions that go beyond it.

Together, the two theorems are generally taken to show that Hilbert's program, in its original form, can't succeed (Horsten 2022; Raatikainen 2025).

The Idea in Outline

Gödel's key step was to make arithmetic talk about itself. He assigned a number to every symbol, statement, and proof in the system, so that statements about proofs became statements about numbers. Then he built a statement that says, in effect, "this statement is not provable in this system."

Suppose the system could prove that statement. Then it would prove something false, since the statement says it can't be proved. Assuming the system doesn't prove falsehoods, it can't prove the statement, and so the statement is true. Experts caution that "says of itself" is a loose description of a precise mathematical construction, but it captures the shape of the argument (Raatikainen 2025).

What It Doesn't Mean

The theorems are often stretched far beyond what they show. Gödel did not prove that mathematics is unreliable, that nothing can be known for certain, or that anything goes. The theorems concern what particular formal systems can derive. A common misunderstanding is to read the first theorem as saying that some truths can't be proved by any means at all; a statement unprovable in one system may be provable in a stronger one (Raatikainen 2025).

The theorems also say nothing against the thousands of results that mathematicians have proved. They mark limits on what a single fixed set of rules can capture.

Conclusion

Gödel showed that any consistent formal system strong enough for basic arithmetic leaves some statements undecided, and can't prove its own consistency. Mathematics still proves theorems with full rigor. What it can't do is fit all of arithmetic's truths into one complete, self-certifying system of rules.

This content reflects the field as of October 2026.

Key Terms

  • Formal system: A precise language together with axioms and exact rules for deriving new statements, so that whether a proof is correct can be checked mechanically.
  • Consistent: Describes a formal system that never proves both a statement and its opposite.
  • Complete: Describes a formal system that, for every statement in its language, proves either the statement or its opposite.
  • Incompleteness theorem: Either of Gödel's 1931 theorems: a consistent formal system that can carry out basic arithmetic leaves some statements undecided (the first), and can't prove its own consistency (the second).
  • Undecidable statement: A statement that a given formal system can neither prove nor disprove.

References

  • Horsten, Leon. 2022. "Philosophy of Mathematics." Stanford Encyclopedia of Philosophy. First published 2007; substantive revision January 25, 2022.
  • Raatikainen, Panu. 2025. "Gödel's Incompleteness Theorems." Stanford Encyclopedia of Philosophy. First published 2013; substantive revision October 8, 2025.

Reading 4 min Done

The Continuum Hypothesis and What Mathematics Can't Decide

Introduction

Georg Cantor proved that the real numbers form a larger infinity than the whole numbers. He then asked whether any infinity lies between the two, and he never managed to answer. This reading explains his question, what Gödel and Cohen proved about it, what independence means, and why mathematicians and philosophers still disagree about it.

Cantor's Question

Two sets have the same size, or cardinality, when their members can be paired off one to one with none left over. The whole numbers 1, 2, 3, … have the smallest infinite size. The real numbers, all the numbers with decimal expansions, are larger: no list can contain them all.

The continuum hypothesis is the claim that no set has a size strictly between the two: every infinite set of real numbers can be paired off either with the whole numbers or with all the real numbers. "The continuum" is an old name for the real number line. Cantor stated a first form of the hypothesis in 1878 (Ferreirós 2025). He proved it for some kinds of sets but never for all, and in 1900 David Hilbert put it first on his famous list of open problems (Ferreirós 2025).

Gödel and Cohen

Most of modern mathematics can be built on a standard list of axioms for sets, known as ZFC (after Zermelo and Fraenkel, with the axiom of choice). An axiom is a statement accepted without proof as a starting point from which other results are proved.

In 1940, Kurt Gödel showed that the continuum hypothesis is consistent with ZFC: adding it to the axioms produces no contradiction, provided the axioms are consistent to begin with (Horsten 2022). So the standard axioms can't disprove it.

In 1963, Paul Cohen showed the other half: adding the denial of the continuum hypothesis also produces no contradiction (Horsten 2022; O'Connor and Robertson 2010). So the standard axioms can't prove it either. Cohen's method, called forcing, is a technique for building new models of set theory in which chosen statements come out true or false. It showed that the axiom of choice is independent of the other axioms too. Cohen received the Fields Medal in Moscow in 1966 for this work on the foundations of set theory (O'Connor and Robertson 2010).

What Independence Means

A statement is in a state of independence from a set of axioms when those axioms can neither prove it nor disprove it. The continuum hypothesis is independent of ZFC. That doesn't mean it is false or meaningless. It means the standard axioms are silent on it.

One response is to look for new axioms. Gödel hoped that axioms asserting the existence of very large infinities would settle the question, but the continuum hypothesis stays independent even with them, and the search for principles that might decide it continues (Horsten 2022). Whether any proposed axiom deserves acceptance is debated.

Is There a True Answer?

Here mathematics meets philosophy, and the disagreement is real. Two positions show the range.

PositionCore claimWhat it suggests about the continuum hypothesis
PlatonismMathematics describes abstract objects that exist independently of usSuggests the hypothesis is true or false and current axioms haven't captured which, though some Platonists doubt this for statements like it
FormalismThe higher parts of mathematics are a formal game with symbols, played by rulesSuggests that beyond what chosen axioms derive, there may be no further fact to find

Platonism holds that mathematics is about abstract entities that exist outside space and time, independently of us (Horsten 2022). Formalism, in Hilbert's version, treats the higher parts of mathematics as a formal game played with symbols according to rules (Horsten 2022). Other views exist. Some mathematicians hold that there are many equally legitimate universes of sets, in some of which the continuum hypothesis is true and in others false (Horsten 2022). None of these positions is settled.

Conclusion

Cantor's question about the sizes of infinity has been shown to be independent of the standard axioms: Gödel showed in 1940 that they can't disprove it, and Cohen in 1963 that they can't prove it. Whether it has a true answer that new axioms might reach, or no answer at all, remains contested.

This content reflects the field as of October 2026.

Key Terms

  • Continuum hypothesis: Cantor's claim that no set has a size strictly between the size of the whole numbers and the size of the real numbers.
  • Axiom: A statement accepted without proof as a starting point from which other results are proved.
  • Forcing: Cohen's technique for building new models of set theory in which chosen statements come out true or false.
  • Independence: The state of a statement that a given set of axioms can neither prove nor disprove.
  • Platonism: The position that mathematics is about abstract entities that exist outside space and time, independently of us.
  • Formalism: The position, in Hilbert's version, that the higher parts of mathematics are a formal game played with symbols according to rules.

References

  • Ferreirós, José. 2025. "The Early Development of Set Theory." Stanford Encyclopedia of Philosophy. First published 2007; substantive revision December 3, 2025.
  • Horsten, Leon. 2022. "Philosophy of Mathematics." Stanford Encyclopedia of Philosophy. First published 2007; substantive revision January 25, 2022.
  • O'Connor, J. J., and E. F. Robertson. 2010. "Paul Joseph Cohen." MacTutor History of Mathematics Archive, University of St Andrews. Last updated May 2010.

Guided Reading 7 min Done

Guided Walkthrough: Building an Adding Circuit from Logic Gates

Introduction

Computers add numbers with circuits built from additions of single binary digits. The circuit that does one of those additions uses nothing but "and," "or," and "not." This reading builds it from a truth table, then shows how copies of it chain together to add longer numbers.

The Starting Point

You have two one-digit binary numbers, A and B. A binary number is written in base two, using only the digits 0 and 1. Each of A and B is therefore either 0 or 1. The task is to design a circuit whose outputs give A + B.

The building blocks are logic gates: small components that take bits (values of 1 or 0) as inputs and produce an output bit by a fixed rule.

  • An AND gate outputs 1 only when both inputs are 1.
  • An OR gate outputs 1 when at least one input is 1, including when both are.
  • A NOT gate flips its single input: 0 becomes 1 and 1 becomes 0.

These rules come from Boolean algebra, the algebra of true and false named after George Boole, who treated logic as algebra in 1854 (O'Connor and Robertson 2004). Reading 1 as true and 0 as false turns every logical rule into a rule about bits. In 1938, Claude Shannon showed that switching circuits follow this algebra, and among his examples was a circuit that adds numbers in base two (Shannon 1938).

Walking Through the Circuit Design

Step 1: List all four cases

Two inputs, each 0 or 1, give four cases. Write each one out in ordinary arithmetic first:

  • 0 + 0 = 0
  • 0 + 1 = 1
  • 1 + 0 = 1
  • 1 + 1 = 2

Listing every case is the same move as writing a truth table: if the circuit gets all four right, it's right for every possible input. There's nothing else it could be asked.

Step 2: Separate the answer into a sum digit and a carry digit

The answers have to be written in binary too. The first three are fine: 0 and 1 are single binary digits. But 2 in binary is written 10, meaning one two and no ones, just as ten in ordinary notation is written 10, meaning one ten and no ones.

So every answer needs two output digits. The sum digit is the ones place. The carry digit is the twos place, the digit that carries into the next column. Here is the full table:

ABA + BCarrySum
00000
01101
10101
112 (binary 10)10

Check each row: carry times 2 plus sum gives A + B. In the last row, 1 \times 2 + 0 = 2.

Step 3: Recognize the two outputs as logical operations

Look at each output column as a truth table on its own.

The carry column reads 0, 0, 0, 1. It's 1 only when both A and B are 1. That is exactly the AND gate's table. So the carry is A AND B.

The sum column reads 0, 1, 1, 0. It's 1 when exactly one of A and B is 1, and 0 when they're the same. That operation has its own name: exclusive or, often shortened to XOR. It means "one or the other, but not both." Compare it with the OR gate, which outputs 1 in the last row as well. The two differ only when both inputs are 1.

Step 4: Build exclusive or from AND, OR, and NOT

The sum needs an exclusive or, but the toolkit has only AND, OR, and NOT. Put the meaning into words: "one or the other, and not both." Each word is a gate.

  • "One or the other" is A OR B.
  • "Both" is A AND B.
  • "Not both" is NOT (A AND B).
  • Join the first and third with AND.

So the sum is (A OR B) AND NOT (A AND B). Check it against the four cases:

ABA OR BA AND BNOT (A AND B)Sum
000010
011011
101011
111100

The last column matches the sum column from Step 2. Notice that the AND gate computing "both" is also the carry, so one gate serves two purposes. The finished circuit, called a half adder, uses four gates: one OR, one AND, one NOT, and a second AND.

Step 5: Chain adders to add longer binary numbers

Longer numbers are added column by column, right to left, exactly as you add on paper. Every column after the first has three bits to add: a digit from each number and a carry from the column to its right. A circuit that handles three input bits is called a full adder. One way to build it is from two half adders: add the two digits, add the carry to that result, and combine the two carry outputs with an OR gate.

Take 6 + 3. In binary, 6 is 0110 and 3 is 0011. Working from the right:

ColumnDigitsCarry inSum digitCarry out
Ones0 and 1010
Twos1 and 1001
Fours1 and 0101
Eights0 and 0110

Read the sum digits from the bottom row up: 1001. That's one eight and one one, which is 9. Each carry out feeds the next column's carry in. Chain 64 of these adders and you can add 64-digit binary numbers.

Key Considerations

Binary 1 + 1. In binary, 1 + 1 is written 10 and read "one-zero," meaning two. The circuit reports it as sum 0, carry 1. Writing the sum as "2" is impossible, because a single bit can only be 0 or 1. That's why the carry exists.

The common mistake: treating "or" as "exactly one." In everyday speech, "coffee or tea" usually means one or the other, not both. Logical "or," and the OR gate, include both: they output 1 when both inputs are 1. If you build the sum with a plain OR gate, the circuit gets the first three cases right and the last one wrong, reporting a sum digit of 1 for 1 + 1. The fix is the extra "and not both" from Step 4.

Terminology. "Exclusive or" and "XOR" are the same operation. Engineers often draw it as a single gate, but inside it is built from simpler gates like the ones above.

Summary

Adding two binary digits produces a sum digit and a carry digit. The carry is AND; the sum is exclusive or, built from OR, AND, and NOT. Here is the finished half adder:

ABCarry (A AND B)Sum ((A OR B) AND NOT (A AND B))
0000
0101
1001
1110

Gate diagram in words: inputs A and B each feed both an OR gate and an AND gate. The AND gate's output is the carry. It also feeds a NOT gate. The OR gate's output and the NOT gate's output feed a second AND gate, whose output is the sum.

  1. Check every row: carry times 2 plus sum equals A + B.
  2. The single shared AND gate gives the carry and also supplies "both" for the sum.
  3. Two half adders and an OR gate make a full adder; a chain of full adders adds numbers of any length, as in 0110 + 0011 = 1001 (6 + 3 = 9).

References

  • O'Connor, J. J., and E. F. Robertson. 2004. "George Boole." MacTutor History of Mathematics Archive, University of St Andrews. Last updated June 2004.
  • Shannon, Claude E. 1938. "A Symbolic Analysis of Relay and Switching Circuits." Transactions of the American Institute of Electrical Engineers 57: 713–723.
    • Free: None confirmed
    • Free companion: O'Connor and Robertson 2004

Guided Conversation 12 min Done

What Does It Mean That Some Truths Can't Be Proved?

In this conversation you'll reflect on where logic already shapes your day and on what Gödel's incompleteness theorems change about the idea of proof. You'll also weigh whether a question like the continuum hypothesis has an answer at all. You'll leave with one clear statement of what incompleteness does mean and one of what it doesn't.

You'll have this conversation with an AI assistant, using your own account. Choose a button to open a new chat with the prompt already filled in, then press send to start. If the chat opens empty, copy the prompt and paste it in.

Run this conversation in whichever assistant you already use:

Claude desktop app

To use another LLM, simply copy and paste the prompt into its chat window.

Show the full prompt (it lists misreadings to watch for, so skip it if you would rather come to the conversation fresh)
Guided Conversation: What Does It Mean That Some Truths Can't Be Proved? (about 12 minutes)

Note to the learner: press send to start. Everything below is facilitator guidance for the AI. It lists misconceptions to watch for, so skip it if you'd rather come to the conversation fresh.

Please facilitate a reflective dialogue with me. I'm an adult who is comfortable with basic high-school algebra but may be rusty or uneasy with math, exploring what logic and set theory are and whether to study them further. I'm studying Gödel's incompleteness theorems, the continuum hypothesis, and how logic is used in computing. Follow this guidance for the whole conversation.

GOAL
Help me explain, in my own words, what Gödel's incompleteness theorems show and how logic is used in computing, by reflecting on my own experience and assumptions.

HOW TO RUN THE CONVERSATION
- Ask one question at a time, then wait for my reply. Keep each of your turns under about 120 words.
- Don't lecture. Explain a point only when I need it to continue, then return to my examples and views.
- Be curious, collegial, and patient. Define terms briefly on first use, such as formal system: a set of axioms and exact rules for deriving statements. Welcome disagreement when I give a reason.
- Plain conversation only: don't search the web or create files or documents.
- Aim for about 12 minutes, with most of the time on topics 2 and 3. If my replies are brief, offer one concrete prompt, such as "When you filter emails by sender and date, what logic is the filter using?", and move on. If I seem uncertain, shorten the conversation to 5-7 minutes. Always reach the final topic.
- Start now. Open with one or two warm sentences: this is a conversation, not a quiz; honest thinking matters more than technical accuracy; I can ask you to clarify anything. Then ask me where I might use logic during an ordinary day without noticing.

TOPICS, IN ORDER
1. Everyday logic. Ask where I rely on logic without noticing: search filters, spreadsheet formulas, the circuits in my phone. Help me see "and," "or," and "not" at work in one example I give. Follow-up: does it surprise me that hardware runs on the same rules as arguments?
2. What proof meant to me. Ask what I thought a mathematical proof guaranteed before, and whether I assumed every true statement could be proved. Then explain briefly what Gödel's first theorem says and ask what, if anything, it changes for me. Follow-up: what is the difference between "unprovable in this system" and "false"?
3. A question with no answer? Explain briefly that the continuum hypothesis asks whether any infinity lies between the whole numbers and the real numbers, and that it can be neither proved nor disproved from the standard axioms of set theory. Ask whether I think it has a true answer we can't reach, or no answer at all, and why. Follow-up: what would it take to change my mind?
4. Closing. Ask me to state one thing incompleteness does mean and one thing it doesn't, so I leave with two sentences I can take into a short piece of reflective writing.

KEY POINTS TO KEEP ACCURATE
- Gödel published his incompleteness theorems in 1931.
- First theorem: any consistent formal system in which a certain amount of basic arithmetic can be carried out has statements it can neither prove nor disprove.
- Second theorem: such a system, if consistent, can't prove its own consistency.
- Incompleteness applies to consistent systems strong enough for basic arithmetic. A statement unprovable in one system may be provable in a stronger one.
- Incompleteness doesn't make mathematics unreliable; proved theorems stay proved.
- Digital circuits compute and, or, and not on bits (1 and 0); databases answer queries with logical conditions and set operations.
- The continuum hypothesis is independent of the standard axioms (ZFC): Gödel showed in 1940 that they can't disprove it, and Cohen in 1963 that they can't prove it.
- Whether the continuum hypothesis has a true answer is contested. Platonists tend to say it does; formalists tend to say there may be no further fact beyond what chosen axioms derive; other views exist.

MISCONCEPTIONS TO CORRECT GENTLY
When one appears, name the accurate version briefly, then return to my examples and views.
- "Gödel proved nothing can be known for certain": he proved limits of specific formal systems, not of knowledge in general.
- "Incompleteness means mathematics contradicts itself": the theorems concern consistent systems.
- "Computers will eventually prove everything": incompleteness limits any formal system, and a computer proving theorems works within one.
- "Unprovable means false": an undecidable statement is one the system can't settle either way.

LIMITS
- Don't take a side on Platonism or formalism, and don't present either as settled.
- No technical proof of incompleteness; the outline of a self-referring statement is the most detail to give.
- Write any math in plain words.

TO FINISH
After my two sentences, close in one short turn:
- Affirm one specific thing I worked out, in my own words where possible.
- Suggest one or two next steps that fit how the conversation went. Possible steps: explore how Gödel numbered statements so arithmetic could talk about itself; read about Hilbert's program; look at how a search filter combines conditions with and, or, and not; revisit the difference between unprovable and false.
- Restate my two sentences on their own lines, labeled "Incompleteness means" and "Incompleteness doesn't mean", so I can copy them.

Journal 15 minOptional Done

When a True Statement Can't Be Proved

Overview

This optional journal entry asks you to think through what Gödel's first incompleteness theorem means to you. The theorem says that any consistent formal system able to carry out basic arithmetic leaves some statements it can neither prove nor disprove. A formal system is a set of starting statements, called axioms, plus exact rules for deriving new ones; it is consistent if it never proves both a statement and its opposite. Your entry is for your own use.

Writing Prompt

In 300 to 400 words, write about what it means to you that some true mathematical statements can't be proved within a given system, and whether that changes how you think about certainty.

Steps

  1. State in your own words what Gödel's first theorem says. Name both conditions: the system is consistent, and it can carry out basic arithmetic. Then say what follows.
  2. Describe what you thought mathematical proof guaranteed before. Be honest about your old picture, even if it was vague, such as "if it's true, someone can prove it."
  3. Say what changes and what doesn't. Name at least one thing that stays the same, such as the reliability of results already proved.
  4. Connect it to one area of your life where you rely on rules or systems. Choose something specific: a legal code, a workplace policy, a set of house rules, a software tool. Ask whether that system can settle every question put to it, and how you handle the cases it can't.

Self-Check

Before you finish, check that your entry:

  • Summarizes the theorem using the words "consistent" and "arithmetic"
  • Distinguishes "unprovable in a system" from "false"
  • Names at least one thing that doesn't change
  • Connects the theorem to one specific system in your life
  • Falls between 300 and 400 words

Nothing is uploaded. Write in your own notebook or document and keep it.

Knowledge Check 10 min Done

Gödel's incompleteness, the continuum hypothesis, and logic in circuits and databases

This ungraded knowledge check assesses your understanding of how logic runs computers and where logic meets its own limits. You'll be asked about logic gates and circuits, sets and logic in databases, Gödel's incompleteness theorems, and the independence of the continuum hypothesis.

Note: Use this to test yourself, review the feedback on any questions you miss, and retry until you feel confident before moving forward.

5 questions · ungraded · retry as often as you like

Graded Quiz 30 min Done

Logic and Set Theory

This graded quiz assesses your understanding of how logic and set theory define proof, compare infinities, run computers, and find their own limits. You'll be asked about the history of logic and set theory, truth tables, validity and fallacies, Cantor's infinities, logic gates, databases, Gödel's incompleteness theorems, and the continuum hypothesis.

Note: Aim for a score of 80 percent or higher. If you score lower, use the feedback to review the topics you missed, then retake the quiz.

10 questions · target score 80% · 3 forms, rotated on each attempt