Stanford CS221 | Autumn 2025 | Lecture 16: Logic II
TL;DR
This lecture introduces First Order Logic as a powerful extension of propositional logic that uses objects, predicates, functions, and quantifiers to compactly represent complex relationships and generalizations without enumerating every possible instance.
⚠️ Limitations of Propositional Logic 2 insights
Scalability breakdown with generalizations
Representing "all students know arithmetic" requires manually listing every student (Alice, Bob, etc.), creating exponentially large formulas that are impractical for real-world domains.
Missing structural elements
Propositional logic treats statements like "Alice knows arithmetic" as monolithic symbols, lacking the machinery to represent internal objects, relationships, or variables needed for abstraction.
🏗️ First Order Logic Syntax 3 insights
Terms denote objects, formulas denote truth
Terms (constants like Alice, variables like x, functions like father(x)) represent objects, while formulas (predicates applied to terms) evaluate to true or false.
Predicates vs. functions
Functions map terms to other terms (father(Alice) returns an object), whereas predicates map terms to boolean values (Student(Alice) returns true/false).
Strict type conventions
Lowercase conventions indicate terms representing objects, while uppercase indicates predicates and formulas representing truth values, preventing ill-formed expressions like Student(Arithmetic).
∀ Quantifiers and Expressive Power 3 insights
Universal and existential quantification
Quantifiers (∀ for all, ∃ for exists) allow expressing general rules like "for all x, Student(x) implies Person(x)" without enumerating every individual in the domain.
Compact complex representations
First order logic enables concise encoding of mathematical conjectures and real-world facts (e.g., Goldbach's conjecture) that would require infinite propositional symbols otherwise.
Inference foundations remain consistent
First order logic maintains the same semantic framework as propositional logic—models, interpretation functions, entailment, and satisfiability—while extending representational capacity.
Bottom Line
First order logic provides the essential machinery—quantifiers, predicates, and a strict separation between terms (objects) and formulas (truth values)—to represent complex world knowledge compactly and perform scalable automated reasoning.
More from Stanford Online
View all
Stanford CS153 Frontier Systems | Nikhyl Singhal from Skip on Product Management in the AI Era
Nikhyl Singhal argues that product management is evolving from manual information gathering to AI-augmented strategic judgment, requiring PMs to focus on solving genuine customer problems while leveraging AI's ability to synthesize vast customer data streams.
Stanford CS153 Frontier Systems | Amit Jain from Luma AI on Unified Intelligence Systems
Amit Jain details Luma AI's evolution from 3D capture to video generation, revealing how the company learned to build scalable world simulators by designing algorithms around data physics rather than theoretical ideals, ultimately converging on unified intelligence systems that combine language, video, and reasoning.
Stanford CS153 Frontier Systems | Andreas Blattmann from Black Forest Labs on Visual Intelligence
Andreas Blattmann, co-founder of Black Forest Labs and co-creator of Stable Diffusion, argues that visual intelligence represents the critical next frontier for AI, requiring a fundamental shift from text-centric unimodal models to multimodal systems trained on 'natural representations' (video, audio, physics) to unlock true reasoning, robotics capabilities, and higher intelligence.
Stanford CS153 Frontier Systems | Mati Staniszewski from ElevenLabs on The Future of Voice Systems
ElevenLabs CEO Mati Staniszewski explains how the company pivoted from an AI dubbing vision to perfecting text-to-speech by staying close to Discord communities, leveraging open-source research, and running lean to solve the 'one voice' dubbing problem he experienced growing up in Poland.