Sample · 34-Book 5-1 · Chapter 34-1 · Algorithmic Strategy & Analysis (Foundations)
Chapter 34 Overview
Book 5-1 · Chapter 34-1 · Algorithmic Strategy & Analysis (Foundations)
This is the first chapter of the review book Algorithm and Discrete Reasoning. It starts from the very beginning — what discrete mathematics even is — and climbs, step by step, to the strategic ideas that make algorithms fast. We deliberately go from the simplest ideas to the most complex: first the raw material (discrete objects, logic, Boolean algebra, sets), then the machinery for reasoning about programs (what an algorithm is, and how we measure its speed with big-O), and finally the great strategy patterns (greedy, divide and conquer, searching, sorting, and optimization). Nothing is assumed; every term is defined and illustrated.
Why start with logic and sets before algorithms? Because data structures are discrete structures, and algorithms are all about discrete structures — the true/false reasoning of Boolean algebra becomes the if-conditions of code, and the union/intersection of sets becomes the operations of real programs. Building this base makes everything afterward feel obvious. The foundations follow S. Sinha, Discrete Mathematical Algorithm, and Data Structure (Leanpub, 2020–2026); the algorithm-analysis and strategy topics follow Y. Disser, Algorithmic Discrete Mathematics (TU Darmstadt, 2024). Each topic has plain-language explanations, worked examples, figures, comics, a book reference, and fully solved questions.
📚 Contents of Chapter 34-1
Read straight through — each topic builds on the previous one, simplest first.
1.1 What Is Discrete Mathematics?
1.1 What Is Discrete Mathematics?
Discrete mathematics is the study of objects that are separate and distinct — things you can count one by one, with nothing “in between.” The natural numbers \( 0,1,2,3,\dots \) are the perfect example: there is no whole number strictly between \( 2 \) and \( 3 \). This is the opposite of continuous mathematics (like calculus or the real number line), where between any two values there are infinitely many others. People, chairs, letters, and computer bits are all discrete; a smoothly sliding dimmer switch is continuous, but the individual steps of a staircase are discrete.
Why does a computer-science student begin here? Because computers are discrete machines: they store information in distinct bits (\( 0 \) or \( 1 \)) and run in distinct steps. Every data structure is a discrete structure, and every algorithm manipulates discrete structures — so discrete mathematics is quite literally the mathematics of computing. Its core toolkits — logic, sets, graphs, counting, and number theory — reappear throughout this book. A classic bridge is the Euclidean algorithm for the greatest common divisor: it works entirely with whole numbers and repeated remainders, a purely discrete process at the heart of both mathematics and cryptography.
Continue reading — 3 chapters, worked examples and practice.
Sign in to buy