A mental math training TUI application. Built with Python using the textual library.
- Covers many of the standard mental math challenges, including arithmetic, exponents, fractions, complex numbers, unit conversions, and day of the week questions.
- Supports quizzes with an arbitrary maximum number limit and number of questions.
- Options to set a limit on the time per question and make the question vanish after a specified period.
- Detailed data screen with options to question type, question time, or number of mistakes.
There are many resources available that detail methods to calculate quickly and accurately.
- World Mental Calculation
- Secrets of Mental Math, by Arthur Benjamin and Michael Shermer
![]() |
![]() |
|---|---|
![]() |
![]() |
Run mmath from the command line to start the application. Press h to view the help screen which details the options.
1. With uv
mmath can be run with uv with the command
uvx mentalmath
It can be installed with
uv tool install mentalmath
and then run with mmath from the command line.
To build from source with uv, run
git clone https://github.com/kianbroderick/mmath.git
cd mmath
uv pip install -e .
to clone the repository and install the program to a virtual environment.
Install mmath to your global or virtual environment with
pip install mentalmath
Run the application with mmath.
mmath can be built from source with the following commands:
git clone https://github.com/kianbroderick/mmath.git
cd mmath
Install textual in either the global or virtual evironment with
pip install textual
Run the application with
pip install -e .
mmath
- add a screen to type in memorized digits of pi or e
- more operations
- add score tracking and statistics over multiple sessions
mmath is licensed under the terms of the MIT License.



