True, game programming would include a lot of that. But most programmers aren't game programmers.
I really think I would've enjoyed game programming, but I didn't go that route because of all the graphics. That's why I always liked making web sites more, because I could just get a designer to do the design part of it and I could do what I was best at. But what you are talking about would have been, absolutely thrilling.
How do databases include a lot of math? That just requires knowing how to create normalized database schemas and creating queries to extract the data in an efficient manner.