A topic in the Open Knowledge Graph — a free, open map of 15,290 topics and the order to learn them in.

VC Dimension

Research Depth 97 in the knowledge graph ☐ I know this ☆ Set as goal
29topics build on this
581prerequisites beneath it
See this on the map →
Growth Function and ShatteringPAC Learning Framework+1 more→→Agnostic PAC LearningBias-Complexity Tradeoff (Formal)+7 more
learning-theory capacity generalization

Core Idea

The Vapnik-Chervonenkis (VC) dimension measures the expressive capacity of a hypothesis class by finding the largest set of points the class can shatter — that is, classify in all 2n possible ways. A hypothesis class with VC dimension d can shatter some set of d points but no set of d+1 points. The VC dimension is the key quantity in the fundamental theorem of statistical learning: a class is PAC-learnable if and only if its VC dimension is finite, and the sample complexity for learning scales linearly with the VC dimension.

Explainer

Building on the PAC framework, we now need a way to measure how "complex" a hypothesis class is, because this complexity determines how many training examples are needed to learn. The Vapnik-Chervonenkis dimension provides exactly this measure. Rather than counting parameters or describing the functional form, VC dimension asks a combinatorial question: what is the largest number of data points that the hypothesis class can classify in every possible way?

The formal definition centers on the concept of shattering. A hypothesis class H shatters a set of points S = {x_1, ..., x_n} if for every possible labeling of these points (every assignment of +1 or -1 to each point), there exists some hypothesis h in H that perfectly classifies them according to that labeling. Since n points have 2n possible labelings, shattering requires that H is expressive enough to realize all 2n dichotomies. The VC dimension of H is the largest n for which there exists some set of n points that H can shatter. If H can shatter arbitrarily large sets, its VC dimension is infinite.

The canonical example is linear classifiers in Rd, which have VC dimension d+1. In R2, lines can shatter 3 points in general position: for each of the 8 labelings, you can draw a line separating the positives from the negatives. But no set of 4 points can be shattered — by Radon's theorem, any 4 points in the plane contain a partition whose convex hulls overlap, creating a labeling that no line can achieve. This result generalizes: hyperplanes in Rd shatter d+1 points but not d+2, giving VC dimension d+1. The connection to the number of "free parameters" (d+1 coefficients for a hyperplane in Rd) is suggestive but coincidental in general — the sine function counterexample, with one parameter but infinite VC dimension, shows parameters alone do not determine capacity.

The profound consequence is the fundamental theorem of statistical learning: a hypothesis class is PAC-learnable if and only if its VC dimension is finite. When VC dimension is d, the sample complexity for achieving error epsilon with confidence 1-delta is O((d/epsilon) * log(1/epsilon) + (1/epsilon) * log(1/delta)). This is a tight characterization — no measure other than VC dimension (and its equivalents) captures learnability so precisely. For practitioners, VC dimension explains why models with too much capacity overfit (they can shatter the training data, memorizing noise) and why controlling capacity — through regularization, architecture constraints, or explicit complexity penalties — is essential for generalization.

Practice Questions 5 questions

Prerequisite Chain

Understanding Zero → The Number Zero → Counting to Five → Counting to 10 → Counting to 20 → Counting a Set of Objects Up to 20 → Cardinality: The Last Number Counted → Matching Numerals to Quantities → Subitizing Small Quantities → Addition Within 10 → Number Bonds to 10 → Addition Within 20 → Doubles and Near Doubles → Doubles Facts Within 10 → Near Doubles Facts Within 20 → Mental Math Strategies for Addition → Mental Math: Adding and Subtracting Tens → Addition Within 100 → Repeated Addition as Multiplication → Multiplication as Equal Groups → Multiplication: Arrays → Basic Multiplication Facts (0s, 1s, 2s, 5s, 10s) → Multiplication Facts Within 100 → Division as Equal Sharing → Division as Grouping (Measurement Division) → Division: Grouping (Repeated Subtraction) Model → Division: Fair Sharing Model → Division as Equal Sharing → Division as Grouping → Basic Division Facts → Division Facts Within 100 → Multiplication and Division Fact Families → Relationship Between Multiplication and Division → Division Facts as Inverse of Multiplication → Remainders and Quotients in Division → Division Word Problems → Multi-Step Word Problems → Solving Multi-Step Word Problems → Multiplication Word Problems → Division Word Problems → Introduction to Long Division → Factors and Multiples → Prime and Composite Numbers → Equivalent Fractions → Relating Fractions and Decimals → Decimal Place Value → Integers and the Number Line → Comparing and Ordering Integers → Absolute Value → Adding Integers → Subtracting Integers → Multiplying Integers → Dividing Integers → Unit Rates → Proportions → Percent Concept → Converting Between Fractions, Decimals, and Percents → Operations with Rational Numbers → Two-Step Equations → Solving Multi-Step Equations → Equations with Variables on Both Sides → Angle Pairs: Complementary, Supplementary, and Vertical → Parallel Lines and Transversals → Corresponding Angles → Alternate Interior Angles → Triangle Angle Sum Theorem → Exterior Angle Theorem → Triangle Inequality Theorem → Similar Triangles: AA Similarity → Similar Triangles: SSS and SAS Similarity → Proportions in Similar Triangles → Right Triangle Trigonometry Introduction → Sine, Cosine, and Tangent Ratios → Trigonometric Ratios Review → Radian Measure → Converting Between Degrees and Radians → The Unit Circle → Graphing Sine and Cosine → Graphing Tangent and Reciprocal Trigonometric Functions → Derivatives of Trigonometric Functions → Antiderivatives → Indefinite Integrals → Basic Integration Rules → Riemann Sums → Definite Integral Definition → Probability Density Functions and Continuous Distributions → Cumulative Distribution Functions → Continuous Random Variables → Probability Density Functions → Expected Value → Weak Law of Large Numbers → Probability Axioms and Rules → Conditional Probability → Law of Total Probability → Bayes' Theorem → PAC Learning Framework → Growth Function and Shattering → VC Dimension

Longest path: 98 steps · 581 total prerequisite topics

Prerequisites (3)

Leads To (9)