How to Invent Math[Technique Tuesdays]

How to Invent Math[Technique Tuesdays]

One of the things that shocks a lot of people when I talk to them is the fact that I have invented my own metrics. In fact, when it comes to heavy-duty AI/Data Science work, chances are that you will eventually have to eventually invent a quantification metric of your own. A metric that doesn’t exist in standard literature, but was created to solve your own particular problem.

If you’re a software engineer, having the ability to quantify your scenarios in novel ways can be a game changer. It can help you see situations in a new light, learn about blockages in your system and ultimately create innovative solutions for yourself.

Photo by Maria Teneva on Unsplash

In this post, I will teach you how to invent your own Math. We will cover the basic steps you need to craft solutions that are perfect for your specific challenges. And don’t worry, you won’t need to be a Math prodigy for this. Basic Math Knowledge, Problem-Solving Ability, and a flexible mind are the only prerequisites.

Coding Interviews Made Simple was the old Name, hence which is why this is mentioned in the review.

Sound like a Jam? Let’s get right into it. This might get a little abstract for you, so I have a video linked below where you can apply this process first-hand.

How to Invent your own Math

  1. Understand the Problem- The first step to inventing your own Math is to understand the problem you’re currently dealing with. Specifically, you want to focus on the problem you’re dealing with, and pull out the important details. This will guide everything else.
  2. Use basic operations- In most metrics, you will largely be using basic operations- division, multiplication, addition, and subtraction. Here are a few more to add to your tool belt- log, exponents, powers, and absolute values. These will form a strong basis for most of the metrics you build. I will do separate Math Mondays on these operations and the flavor that each adds to your solutions.
  3. Use the existing ideas- Chances are that there are existing metrics that can be used to quantify the value you are trying to solve. It won’t do it well, but it will work. More than often, your invention will then be a twist using this idea as a baseline. For example, for one of the metrics I invented, I used the popular Mean Squared Error as a baseline.
  1. Recognize the problem with the existing metric- Next step is to figure out what exactly the problem your current metric is. In my case, we noticed that MSE flattens the multi-dimensional errors. We were working with a multi-variate prediction system, where each target value had a different priority and units of measurement. Blindly applying MSE would not allow us to study the prediction engine in depth. So we made a few changes, using MSE as a baseline to create a new metric that helped us calculate our system’s weighted deviation from expected values. Once you have figured out the problem, make the required changes, using the operations described.
  2. Keep Going Back to your Metric- Remember that any metric you use (whether your own or a standard one) is not a gift from God. Changing it will not cause the next great flood. Every Metric comes with certain assumptions and simplifications you make about the problems you’re solving. You have to keep going back and revising the metric, at least checking if it is still valid. Far too often, teams get married to their metric and dedicate their resources to improving it. Remember, the goal is not to get a high score/low error, the goal is to build systems that are useful to people. Sometimes, that involves changing your evaluation metrics to suit your new circumstances.

This video by the Amazing Creator RitvikMath is a great example of this process. It goes into the KL Divergence, a popular metric in Data Science and Deep Learning. While it doesn’t ‘invent’ a new metric, it does highlight the process from scratch. Take a look and make notes of each step.

A reminder to anyone looking for work- I post job openings very regularly on my Instagram stories. By following me there, you can get access to job openings for free. My Instagram can be found here (@iseethings404)

If you liked this write-up, you would like my daily email newsletter Technology Made Simple. It covers topics in Algorithm Design, Math, AI, Data Science, Recent Events in Tech, Software Engineering, and much more to help you build a better career in Tech.

Save the time, energy, and money you would burn by going through all those videos, courses, products, and ‘coaches’ and easily find all your needs met in one place.

I am currently running a 20% discount for a WHOLE YEAR, so make sure to check it out. Using this discount will drop the prices-

800 INR (10 USD) → 533 INR (8 USD) per Month

8000 INR (100 USD) → 6400INR (80 USD) per year

You can learn more about the newsletter here. If you’d like to talk to me about your project/company/organization, scroll below and use my contact links to reach out to me.

Reach out to me

Use the links below to check out my other content, learn more about tutoring, reach out to me about projects, or just to say hi.

If you like my writing, I would really appreciate an anonymous testimonial. You can drop it here.

To help me understand you fill out this survey (anonymous)

Check out my other articles on Medium. :

My YouTube:

Reach out to me on LinkedIn. Let’s connect:

My Instagram:

My Twitter:

If you’re looking to build a career in tech:



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store

Writeups from my Substack newsletter, Technology Made Simple. You can find it on my Substack-