Last updated:
MLCalculators is a free set of calculators for the mathematics behind machine learning: linear algebra, regression, vectors, probability and statistics. It is built and maintained by Jamal Hussein, who is currently studying for an MSc in Artificial Intelligence. Every tool shows its working, so you can check a result instead of taking it on trust.
Who is behind this site?
I am Jamal Hussein. I am pursuing a master’s degree in Artificial Intelligence, and this site grew out of that study: the calculators cover the operations that come up again and again in the coursework and in real model code, such as multiplying matrices, fitting a regression line, turning scores into probabilities or reading a confusion matrix.
I am a student of this subject, not a professor. That is why each page is built so that you do not have to rely on my authority: the formula is stated, the arithmetic is shown step by step, and the equivalent NumPy or SciPy call is given so you can reproduce the answer yourself.
How are the calculators and explanations made?
Being open about the process matters, so here it is in full.
- The calculators are small JavaScript programs that run in your browser. Before a calculator is published, its maths functions are run against test cases with known answers, worked from the exact formula or produced by NumPy and SciPy. A page is not published until those tests pass.
- The explanations are drafted with AI assistance. The articles, worked examples and code samples on this site are written with the help of an AI model (Anthropic’s Claude). The numbers in each worked example are checked against the tested calculator and the reference library, and the pages go through automated checks for broken links and valid markup.
- Sources are linked where a page relies on a library’s behaviour, normally the official NumPy, SciPy or Python documentation.
AI-assisted writing can still contain mistakes. If a result or an explanation looks wrong, compare it with the step-by-step working and the Python code on the same page; those are there so that errors are easy to spot. If you find an error, please report it through the contact page so it can be corrected.
Why does the site exist?
Most online calculators give you a number and nothing else, and some hide the steps behind a paywall. When you are learning the mathematics of machine learning, the steps are the point. The aim here is narrow: a correct answer, the working that leads to it, a diagram where one helps, and the code that reproduces it.
What does it cost, and what happens to my data?
The calculators are free and need no account. The numbers you type are processed in your own browser and are not uploaded. The privacy policy describes exactly what the site does and does not collect.
Where to start
Browse the linear algebra calculators, the regression calculators or the statistics calculators, or go straight to a popular tool such as the matrix multiplication calculator or the confusion matrix calculator.