GraphIt is a lightweight desktop graph plotting application written in C++ using the Qt framework.
It allows interactive visualization of mathematical functions and smooth navigation across the coordinate system by dragging the view.
The application focuses on responsiveness and deterministic rendering. Function values are precomputed once and then efficiently rendered, which allows smooth panning even with multiple plots.
📖 Detailed technical description: docs/architecture.md
Example of how to use the application
- Plot mathematical expressions from text (ExprTk parser)
- Multiple functions displayed simultaneously
- Adjustable domain per function
- Automatic rebuild after input change (debounced updates)
- Smooth panning (dragging the coordinate plane)
- Deterministic frame rendering independent of expression complexity
Main window after startup
Multiple functions example
- C++17 compatible compiler
- Qt 6 (Core, Gui, Widgets)
- CMake ≥ 3.16 (not required when using Qt Creator)
- Install Qt Creator with Qt 6 Widgets module
- Open
GraphIt.pro - Select a Desktop Qt 6 kit
- Build & Run
- Launch the application — an empty coordinate system appears
- In the bottom panel enter a function:
y := expression - Set domain range (from / to)
- Choose color (default is black)
- The plot appears automatically after a short delay
- Drag inside the window to navigate the coordinate system
- No zoom yet (fixed scale)
- The renderer does not currently split plots at asymptotes or undefined points, so functions with discontinuities (e.g.
1/x,tan(x)) can be plotted incorrectly - Sampling density is fixed and not dependent on zoom level
- Smooth zooming instead of discrete translation
- Viewport‑based sampling (functions without predefined domain)
- Adaptive sampling density
- Detection of discontinuities / asymptotes
- Function legend and visibility toggling
- Export graph to image / SVG
- Keyboard navigation shortcuts
- Theme support (dark mode)
Some of these would require changing the rendering model from precomputed coordinate‑space sampling to dynamic screen‑space evaluation.
This project is licensed under the MIT License — see LICENSE.
Third‑party licenses are listed in THIRD_PARTY_LICENSES.
-> ExprTk — C++ Mathematical Expression Library (MIT License) by Arash Partow


