The Maths Behind Everyday Life
The story, the formula and a worked example — see exactly where this maths shows up in the world around you.
How Netflix guesses what you will watch next
Your taste becomes an arrow, and the app looks for arrows pointing the same way.
Recommendation engines turn your ratings into a list of numbers — a vector. Someone with similar taste has a vector pointing in nearly the same direction. The angle between two taste-vectors measures how alike two people are, and that is exactly what cosine similarity computes.
Taste as a direction
Cosine similarity ignores how much someone rates and looks only at the pattern. A value near 1 means "almost identical taste"; near 0 means "nothing in common".
You and a stranger
You rate three films 5, 1, 4. A stranger rates them 4, 1, 5. How alike are you?
Comparing [5, 1, 4] with [4, 1, 5]
- 1
Dot product
- 2
Each length
- 3
Cosine similarity
0.976 out of 1 — nearly identical taste, so whatever the stranger loved will likely be recommended to you.
The takeaway
Recommendations are geometry in disguise: your preferences are a direction in space, and the service finds the people and films whose arrows point the same way.