
How Computer Science Students Use Mathematical Modeling in the Real World
When you hear “mathematical modeling,” you may think that it sounds like something that belongs only in a math class. Or maybe you think of something in the messy real world disconnected from what computer science students are doing.
But the truth is that math modeling is more closely connected to computer science than you might think.
If you’re studying computer science, you’re already engaging in modeling in a variety of ways. You’re just not calling it modeling. On a basic level, modeling is about taking a problem and turning it into something you can work with. This is where a lot of computer science work begins, whether it’s obvious or not.
Modeling Starts Before You Write Any Code
Pretend you’re working on a project that involves finding the best route between two locations, perhaps a warehouse and a delivery address. This may seem pretty straightforward, but once you get into it, it’s not that simple. And we haven’t even talked about algorithms yet!
You first have to decide what “best” actually means. Is it the fastest route? The shortest distance? Cheapest option? Are you factoring in traffic or time of day? Those decisions change the entire outcome.
And none of that is code yet. It’s you defining the problem. That definition and its mathematical representation is the model. Once you’ve made those choices, then you can build some code related to your model.
How Math Modeling Shows Up in Algorithms
It’s easy to think algorithms are just about logic. You learn how they work, you implement them, and that’s kind of it. But they don’t just appear out of nowhere. They too are built on layers of assumptions.
Take something like a recommendation system. Before you even get into the technical side, you’re already making calls about how people behave when they choose movies to watch or books to read.
What actually makes two users similar? Does what they did yesterday matter more than what they did six months ago? What signals are worth paying attention to—and which ones aren’t?
Those decisions aren’t really about code. They’re about how you’re thinking through the problem. And they shape the outcome more than people expect.
Then, when you choose an algorithm and how to code it, more modeling enters in. Do you prioritize speed or memory constraints? Will brute force work? Which data structure is best, what language is most robust, etc.?
Mathematical Modeling in Data Science and AI
When you consider data science or machine learning, it becomes even harder to separate modeling from the work. You’re handling data that could be incomplete or inconsistent. So you need to decide what to include, what to do with missing or redundant data, and how to organize the data so it actually tells you something useful.
Then you develop a model to try based on what you think is happening. And most of the time, your first attempt isn’t quite right. So you adjust. Test again. Change something else. And then you try again.
Building, then testing, and finally adjusting is what mathematical modeling in computer science actually looks like. It’s not clean or linear. It’s a lot more iterative.
It Shows Up in Systems, Too
This isn’t only about algorithms or data, though. When you’re building a software system, you’re doing the same thing on different levels. You’re thinking through how different pieces connect, where things might fail, how to integrate the components, and what happens when the system is deployed.
You can’t build everything at the same time. You start by building a draft of the system that you can reason through first. That’s modeling, too.
Seeing It Differently
Mathematical modeling isn’t something separate from computer science. It’s already built into how the field works. Any time you’re defining a problem, making decisions about what matters, or testing how something behaves, you’re using mathematical modeling in computer science.
The difference is whether you’re doing it intentionally. Explicitly adopting a mathematical modeling mindset can help.
And once you start thinking about it that way, you can ask better questions, make smarter decisions, and ultimately create better solutions.
Written by
COMAP
The Consortium for Mathematics and Its Applications is an award-winning non-profit organization whose mission is to improve mathematics education for students of all ages. Since 1980, COMAP has worked with teachers, students, and business people to create learning environments where mathematics is used to investigate and model real issues in our world.
