Skip to content
GameDev Formulas
Math & physics for real games

Practical math for real-time games

Understand the math and physics behind game development.

A clear, accessible reference for students, indie devs, and professionals. Every formula includes intuition, variable breakdowns, game-development use cases, and implementation-ready JavaScript and C++ code.

Clear explanations
Intuition before notation.
Dual code
JavaScript and C++ examples.
Practical cautions
Tips, warnings, and pitfalls.

Example formula

Dot Product

A simple operation that answers a powerful gameplay question: are two directions aligned?

a⃗⋅b⃗=∥a⃗∥∥b⃗∥cos⁡(θ)\vec{a}\cdot\vec{b} = \lVert\vec{a}\rVert\lVert\vec{b}\rVert\cos(\theta)

Core topics

Start with the fundamentals

Explore the formulas most commonly used in movement, physics, collisions, and camera systems.

View all topics

For every stage

Built for learners and practitioners

Students

Learn what symbols mean, why formulas work, and how they map to game behavior.

Intermediate developers

Bridge theory to implementation with clear code patterns and common pitfalls.

Professionals

Use it as a quick reference for correctness, units, performance, and edge cases.