Zulip Chat Archive
Stream: Is there code for X?
Topic: Print Trace for `ring_nf`
Tanner Duve (Dec 06 2025 at 20:30):
is there a way to print to the info view what a particular call to ring_nf (and other such decision procedures) would do, similarly to simp? or aesop?.
Kevin Buzzard (Dec 06 2025 at 20:58):
It will do some hideously complicated thing.
import Mathlib
theorem x (a b : ℝ) : (a + b) ^ 3 = a^3+3*a^2*b+3*a*b^2+b^3 := by
ring
#print x -- over 250 lines of impenetrable code
Vlad Tsyrklevich (Dec 07 2025 at 07:03):
Another way to get it inline is show_term tactic. This term is often what you're looking for, though the term generated by grind is just an invocation of an intermediate lemma which is less useful.
Last updated: Dec 20 2025 at 21:32 UTC