Quick Start Tutorial
This tutorial will walk you through creating and solving your first handwritten equation using AI Math Notes. You’ll learn the basics of the interface and see the AI in action.Launch the Application
Start AI Math Notes
Open your terminal, navigate to the AI Math Notes directory, and run:A window will appear with:
- A black canvas (1200x800 pixels) for drawing
- Three buttons at the bottom: Clear, Undo (Cmd/Ctrl Z), and Calculate (Return/Enter)
Draw Your First Equation
Using your mouse, draw a simple equation on the canvas. Let’s start with something easy:Your drawing will appear in white on the black canvas. Don’t worry if your handwriting isn’t perfect - GPT-4o is quite good at recognizing handwritten math.
Calculate the Result
Press the Enter key (or click the Calculate button).The application will:
- Capture your canvas as an image
- Convert it to base64 encoding
- Send it to OpenAI’s GPT-4o model
- Receive the calculated answer
- Display the result in orange text next to your equals sign
8 appear in orange to the right of your equals sign!Understanding the Interface
Now that you’ve solved your first equation, let’s explore the features available to you:Drawing on the Canvas
The canvas responds to mouse events:- Click and drag to draw lines in white
- Lines are 5 pixels wide for clear visibility
- Each stroke you make is tracked as a separate action (important for undo)
The canvas uses Tkinter for the UI and PIL (Pillow) for image processing. Every line you draw is stored both as a canvas element and in an underlying PIL image.
Control Buttons
Clear
Removes everything from the canvas and resets the image. Use this to start completely fresh.
Undo
Removes the last stroke you drew. You can also use Cmd+Z (macOS) or Ctrl+Z (Windows/Linux).
Calculate
Sends your drawing to GPT-4o for calculation. You can also press Enter or Return.
How the AI Works
When you click Calculate, here’s what happens under the hood:- Look for equals signs with nothing to the right
- Only respond with numbers (no words)
- Calculate the answer to the equation
Try More Complex Equations
Now that you understand the basics, try some more challenging equations:Multi-Operation Expressions
Try an equation with multiple operations:The AI should respect the order of operations (PEMDAS/BODMAS) and return
27.Using Undo
If you make a mistake while drawing:
- Press Cmd/Ctrl+Z to undo the last stroke
- You can undo multiple times to remove several strokes
- Each stroke (from mouse press to release) is one undo action
Tips for Best Results
Write Clearly
While GPT-4o is excellent at handwriting recognition, clearer writing produces more accurate results. Take your time drawing numbers and symbols.Proper Spacing
Leave some space between numbers and operators. This helps the AI distinguish between elements like11 and 1 1.
Equals Sign Placement
The application finds the position of your equals sign by looking at the last stroke you made. Make sure to:- Draw your equation
- Draw the equals sign last
- Immediately press Enter (don’t draw anything else)
Answer Positioning
Answers appear at coordinates calculated from your equals sign position:What’s Next?
You now know how to:- ✓ Draw equations on the canvas
- ✓ Use the Calculate, Undo, and Clear functions
- ✓ Get AI-powered answers to your handwritten math