MathVis: Can AI Reason through Drawing? A Benchmark for Mathematical Figure Generation
Organizations: Zhihu (zhihu.com) · Tsinghua University (tsinghua.edu.cn) · City University of Hong Kong (cityu.edu.hk) · CIS, Cornell University (cornell.edu)
Abstract
This paper introduces MathVis, a benchmark designed to evaluate LLMs' ability to visualize frontier mathematical problems and perform diagram-assisted reasoning. The benchmark consists of 512 tasks, each comprising a mathematical statement, a reference diagram, executable TikZ or SVG code, a Gold Intermediate Representation (IR), atomic rubrics, and error codes. Through rigorous evaluation, GPT-6-Astra, Claude Fable 5, and Gemini 3.1 Pro Preview achieve pass@1 scores of 31.25%, 26.56%, and 22.85%, respectively. We found that although the tasks require visualization, LLMs produce outputs dominated by formal languages, symbols, and graphics programs, rather than explicit diagram-mediated reasoning. Furthermore, while the solutions generated by LLMs may contain all the necessary elements, they are often visually confusing to humans. Ultimately, this benchmark aims to visualize mathematical problems and promote research on enabling LLMs to simplify their reasoning via visual diagrams.
Figures & tables
| Model | pass@1 | -PSR | -PSR | pass@3 | pass^3 | |
|---|---|---|---|---|---|---|
| GPT-6-Astra | 31.25 | 30.73 | 94.40 | 31.20 | 38.28 | 24.22 |
| Claude Fable 5 | 26.56 | 25.13 | 84.11 | 26.07 | 29.30 | 19.14 |
| Gemini 3.1 Pro Preview | 22.85 | 20.70 | 78.13 | 20.70 | 27.34 | 15.23 |
| Question | Mathematical bottleneck | Direct baseline evidence |
|---|---|---|
| DG-FIG-01 | Coordinate image arrows, transformation directions, and inverse mapping labels | Archived outputs reverse or omit required mappings; displayed artifacts fail the strict delivery gate |
| DG-FIG-02 | Four open semi-circular domains, quadrant intersections, and radical signs | Archived outputs include rendering failures and incomplete domain constructions |
| CV2-FIG-13-01 | Disk interior angles, symmetry axes, and the relation | Archived outputs include missing angle relations and rendering failures |
| ID | Type | Atomic decision question | Evidence and allowed equivalent forms | Weight / code |
| CA-H1 | Hard | Is correctly specified as the circle centered at with radius ? | A labeled equation or domain-plane circle, allowing global translation and uniform scaling when geometry is shown | DOMAIN |
| CA-H2 | Hard | Are the images of under and correctly drawn and labeled? | Curve geometry and function–curve binding, allowing equivalent color schemes and line styles | FUNCTION |
| CA-H3 | Hard | Does the figure or its associated formula give the correct boundary comparison, for ? | Boundary evaluation on , accepting equivalent algebraic presentations of the same inequality chain | BOUNDARY |
| CA-H4 | Hard | Does the figure indicate that has exactly three zeros inside , either by marking the three zeros or by showing a winding number of three? | Count and region membership of zero markers, or the winding number of the image curve about the origin; exact root coordinates are not required | ZEROCOUNT |
| CA-H5 | Hard | Regardless of the graphical perspective, does the conclusion state that and have the same number of zeros inside , both being three counting multiplicities? | Text or formula extraction, accepting equivalent phrasing | CONCLUSION |
| CA-S1 | Soft | Are the chosen contours, regions, winding cues, and any zero markers easy to distinguish? | Scored as , , or by experts based on public anchors | 0.30 |
Appendix figures & tables5 assets
Supplementary material from the paper’s appendix.
Appendix
| Stage | Professional work | Main risks | Archived records |
|---|---|---|---|
| Proposition screening | Recover visualizable propositions from traceable sources and assign to corresponding math sub-disciplines | Forcing illustrations for theorems lacking stable 2D semantics | Source page, local context, rights status, sub-discipline, and visualizability rationale |
| Instance specification | Fix regions, functions, parameters, manifolds, knots, directions, and conventions | Multiple legal instances having different visual meanings | Specific instance , public prompt , allowed equivalent forms, and prohibited conditions |
| Reference figure generation | Generate executable candidate figures using numerical, parametric, off-the-shelf libraries, or manual vector paths | Renderer style becoming a shortcut to identify questions | Source program, renderer version, path label, rendering results, and editing records |
| Automatic pre-check | Check schema, compilation, non-empty rendering, numerical invariants, and mechanically verifiable IR relations | Mistaking successful rendering as evidence of mathematical correctness | Machine logs, measured quantities, failed check items, and evidence confidence |
| Expert verification | Verify source consistency, instance validity, Gold IR coverage, constraint types, reference figure correctness, and ambiguous outputs | Figure appearance reasonably masking subtle semantic errors | Predicate-level decisions, evidence, reviewer sub-discipline, return reasons, and arbitration records |
| Predicate family | Typical hard judgment | Typical soft judgment | Priority evidence |
|---|---|---|---|
| Regions and boundaries | Do regions, holes, boundary branches, inclusion relations, and interior/exterior markers have correct topology? | Are different branches easy to distinguish? | Vector paths, point-in-region tests, and expert review |
| Directions and traversals | Are contour directions mathematically correct and consistent with arrow or parameter directions? | Are direction hints clear and not overly crowded? | Path ordering, arrow extraction, and local tangent checks |
| Functions and images | Are pre-image domains, image domains, branch selections, and boundary correspondences correct? | Is the visual correspondence between pre-image and image clear? | Gold IR edge matching, function sample values, and label recognition |
| Zeros, poles, and critical points | Are multiplicities, positions relative to contours, and point type symbols correct? | Are different point types easy to distinguish? | Numerical roots or pole checks and region membership judgments |
| Quantitative invariants | Are modulus, argument, winding number, residue relations, or inequalities on specified sets correct? | Do invariants establish clear visual connections with relevant objects? | Symbol or numerical checks and formula parsing |
| Branches and branch cuts | Are branch cuts, Riemann surfaces, discontinuities, and analytic continuation paths mathematically compatible? | Are different layers or sides of branch cuts easy to distinguish? | Topological adjacency, sampled arguments, and expert review |
| Field | Admission decision question | Required evidence |
|---|---|---|
| Source consistency | Does the instantiated question maintain the source proposition, notation, assumptions, and directions? | Source page or original figure, local context, and constructor’s verification notes |
| Instance validity | Are regions, functions, parameters, objects, and conventions clear and mutually consistent? | Symbol table, parameter check, and executable or numerical witness |
| Prompt sufficiency | Can a qualified solver reconstruct the required artifact without knowing the evaluation-side information? | Independent reconstruction record based solely on the prompt |
| Gold IR coverage | Does the IR contain all objects, relations, formulas, invariants, equivalent forms, and prohibited conditions required by the instance? | Item-by-item correspondence from source proposition to IR fields |
| Constraint validity | Is each atomic constraint decidable, non-redundant, linked to IR evidence, and correctly classified as hard or soft? | Constraint card with type rationale, weight rationale, and failure codes |
| Reference artifact correctness | Does the executable reference artifact satisfy all hard constraints and expected soft specifications? | Compilation logs, rendering results, automatic measurements, and expert sign-off |
| Model | pass@1 | -PSR | -PSR | pass@3 | pass^3 | |
|---|---|---|---|---|---|---|
| GPT-6-Astra | 31.25 | 30.73 | 94.40 | 31.20 | 38.28 | 24.22 |
| Claude Fable 5 | 26.56 | 25.13 | 84.11 | 26.07 | 29.30 | 19.14 |
| Gemini 3.1 Pro Preview | 22.85 | 20.70 | 78.13 | 20.70 | 27.34 | 15.23 |
| GPT-5.6-sol | 21.48 | 19.99 | 92.32 | 20.05 | 24.22 | 16.60 |
| Claude Opus 4.8 | 20.90 | 19.92 | 78.91 | 20.12 | 24.80 | 15.04 |
| Doubao Seed 2.1 Pro | 20.90 | 19.14 | 81.05 | 20.03 | 24.22 | 14.84 |
| Field | Definition | Current status |
|---|---|---|
| Questions | Question ID, source, prompt, reference materials, and Gold IR | 512 official questions |
| Output contract | Complete independent TikZ or SVG, output code only | Executed |
| Technical gate | Parsing / compilation / rendering / non-empty output | Audited |
| Semantic gate | Rubrics | Diagnostic report |
| Delivery gate | Technical gate, rubrics, readability | Main strict results |
| Repeated runs | Outputs per question under the same prompt and Harness | All 16 configurations: 3 reported rollouts; question-level logs retained for 3 configurations |