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

Introduction to Reinforcement Learning

Research Depth 97 in the knowledge graph ☐ I know this ☆ Set as goal
26topics build on this
673prerequisites beneath it
See this on the map →
Markov Decision ProcessesExpected Value and Variance+2 more→→Exploration vs. Exploitation TradeoffModel-Based Reinforcement Learning+4 more
reinforcement-learning learning-paradigm

Core Idea

RL learns from interaction with an environment. Agents select actions, receive rewards, and observe state transitions. Goal is maximizing cumulative discounted reward. Model-free methods learn value/policy directly; model-based methods learn transition/reward models.

Explainer

From your study of Markov decision processes, you know the formal framework: states, actions, transition probabilities, and rewards. An MDP defines the rules of a game. Reinforcement learning is the process of learning to play that game well — without being told the rules in advance. The agent does not know the transition function or the reward function; it must discover them through experience, like a child learning that touching a hot stove hurts by touching it.

The RL loop is deceptively simple. At each time step, the agent observes its current state, selects an action, receives a reward signal, and transitions to a new state. The agent's goal is to learn a policy — a mapping from states to actions — that maximizes the expected cumulative discounted reward, which you know from MDPs as the value function V(s) = E[Σ γᵗrₜ]. The discount factor γ controls how much the agent cares about future rewards versus immediate ones. A γ close to 1 makes the agent far-sighted; a γ close to 0 makes it myopic. This objective connects directly to the expected value concepts you have studied in probability.

The central challenge of RL is the exploration-exploitation tradeoff. The agent must balance exploiting actions it already knows are good against exploring unknown actions that might be better. If a robot discovers that turning left yields a small reward, should it keep turning left or try turning right on the chance of finding a larger reward? Too much exploitation and the agent gets stuck in suboptimal behavior; too much exploration and it wastes time on bad actions. Strategies like ε-greedy (act greedily most of the time, but explore randomly with probability ε) and upper confidence bounds (prefer actions with uncertain value estimates) address this tradeoff.

RL methods split into two families. Model-free methods learn the value function or policy directly from experience without building an explicit model of the environment. Q-learning, for instance, learns Q(s, a) — the expected return of taking action a in state s — by updating estimates after each real transition. Model-based methods instead learn the transition and reward functions, then plan using the learned model. Model-free methods are simpler and more robust to model errors, but they require many more interactions to converge. Model-based methods are sample-efficient but only as good as their learned model. Understanding this distinction is the gateway to the rest of the RL landscape, from deep Q-networks to policy gradient methods and beyond.

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 → Conditional Distributions → Conditional Expectation → Markov Chains → Markov Decision Processes → Introduction to Reinforcement Learning

Longest path: 98 steps · 673 total prerequisite topics

Prerequisites (4)

Leads To (6)