Overfitting (Intuition) Examples in Math
Start with the recap, study the fully worked examples, then use the practice problems to check your understanding of Overfitting (Intuition).
This page combines explanation, solved examples, and follow-up practice so you can move from recognition to confident problem-solving in Math.
Concept Recap
Overfitting occurs when a model learns the noise in training data instead of just the underlying pattern, performing well on training data but poorly on new data.
The model memorized the training data instead of learning the underlying pattern.
Read the full concept explanation โHow to Use These Examples
- Read the first worked example with the solution open so the structure is clear.
- Try the practice problems before revealing each solution.
- Use the related concepts and background knowledge badges if you feel stuck.
What to Focus On
Core idea: Overfitting: too complex. The model sees patterns that aren't really there.
Common stuck point: Adding more parameters always improves training fit but often hurts prediction.
Worked Examples
Example 1
mediumSolution
- 1 Degree-9 polynomial: 10 parameters for 10 points โ fits every point exactly (interpolates), but captures noise not just signal
- 2 Linear model: 2 parameters โ fits general trend, ignoring noise
- 3 For prediction: the polynomial will perform poorly on new data (it memorized the training data's random fluctuations)
- 4 The linear model captures the true underlying relationship better, generalizing to new data despite lower in-sample R^2
Answer
Example 2
hardPractice Problems
Try these problems on your own first, then open the solution to compare your method.
Example 1
easyExample 2
hardRelated Concepts
Background Knowledge
These ideas may be useful before you work through the harder examples.