TLDR: A new interpretability framework analyzes how Large Language Models (LLMs) solve undergraduate calculus problems, moving beyond just answer correctness. It breaks down LLM solutions into semantically labeled reasoning steps and evaluates how sensitive their outputs are to changes in prompt phrasing. Applied to real university exams, the framework revealed that LLMs can produce fluent but conceptually flawed solutions, with reasoning patterns sensitive to input variations. This work aims to make AI-assisted learning in STEM more transparent and reliable for both students and educators.
Large Language Models (LLMs) are becoming increasingly common in educational settings, but simply getting the correct answer isn’t enough, especially in subjects like mathematics. In calculus, where multi-step logic, symbolic reasoning, and clear concepts are crucial, understanding *how* an LLM arrives at a solution is just as important as the solution itself. Traditional ways of evaluating these models often miss the reasoning process, which can hide flaws in their problem-solving approach.
To address this, researchers have introduced a new framework designed to interpret how LLMs solve undergraduate calculus problems. This framework helps diagnose reasoning failures, align AI tools with curriculum goals, and inform the creation of AI-assisted feedback tools that are more transparent and reliable. This study is notable as the first to offer a structured, quantitative, and educationally-focused way to understand LLM reasoning in math education, paving the way for responsible AI use in STEM learning.
Understanding the Interpretability Framework
The framework has two main parts. The first is a reasoning flow analysis. This involves breaking down an LLM’s step-by-step solution into individual reasoning steps. Each step is then labeled with the mathematical operation performed (like differentiation or substitution), the concept applied (such as the chain rule or gradient), and an estimate of its cognitive complexity (low, medium, or high). By mapping these steps, the framework creates a “reasoning graph” that shows the logical connections and helps identify where the model might skip steps, make conceptual errors, or over-generalize.
The second part is a sensitivity ablation method. This technique assesses how much specific parts of a question influence the LLM’s answer. Researchers take a calculus problem and systematically change or remove certain elements – like numerical values, instructional keywords (“find,” “compute”), or even linguistic features like punctuation. The LLM is then given both the original and the altered prompts. By comparing the outputs, the framework measures “phrase sensitivity” (how much the output changes due to a specific phrase) and “robustness” (the overall stability of the output despite input variations). This helps pinpoint which parts of a problem the model relies on most heavily and where its reasoning might be fragile.
Why Calculus?
Calculus is an ideal subject for this research because of its structured progression of complexity, from Calculus I (limits, derivatives) to Calculus III (multivariable functions, vector calculus). This allows researchers to test LLM behavior across different levels of mathematical demand, from concrete computations to abstract generalizations. The study used real Calculus I–III university exams to evaluate how LLMs handle procedural steps, symbolic manipulations, and conceptual understanding.
Also Read:
- Navigating the Learning Path: How Data Order Influences LLM Mathematical Reasoning
- Beyond Final Answers: How RLVR Affects LLM Reasoning Traces
Key Findings and Implications
The study found that LLMs often produce solutions that sound correct but have underlying conceptual flaws. Their reasoning patterns can also be very sensitive to how a prompt is phrased or how inputs are varied. For instance, the Gemma 3 model, chosen for its consistency and mathematical ability, performed competitively with human students in many calculus exams. However, its performance varied, especially in more complex Calculus III problems, highlighting challenges with spatial reasoning and multi-step symbolic derivations.
The research also explored how external knowledge, provided through techniques like Retrieval Augmented Generation (RAG) and Contextual Retrieval, affects LLM performance. While these methods sometimes improved accuracy, especially in Calculus I, they could also degrade performance in higher-difficulty domains if the retrieved information was not perfectly aligned or introduced noise. This suggests that simply adding more information isn’t always better; the quality and relevance of the context are crucial.
From an educational perspective, this framework offers significant benefits. It allows educators to evaluate whether an LLM’s reasoning aligns with valid teaching patterns and to identify areas where models consistently struggle. For students, seeing the step-by-step reasoning can help them compare their own problem-solving approaches, understand errors, and develop better metacognitive skills. The framework also helps in designing assignments where AI assistance is used responsibly, teaching students how to verify AI-generated steps and interpret problem formulations effectively. For more details, you can read the full paper here.
Despite its promise, the study acknowledges limitations. LLMs can still produce high-scoring answers with subtle conceptual errors, and they often excel in procedural tasks but struggle with deeper conceptual reasoning. Future work aims to integrate this framework into intelligent tutoring systems, using its insights to provide adaptive learning environments and flag LLM solutions that need human review, ensuring AI remains an assistive, not a replacive, tool in education.


