The following two function are identical except with different ranges:
f1 = new TF2("f1", "exp(-((x*cos(0.0)+y*sin(0.0))**2+0.25**2*(-x*sin(0.0)+y*cos(0.0))**2)/(2*45.0**2))*cos(6.28*(x*cos(0.0)+y*sin(0.0))/30.0 + 0)", -200, 200, -200, 200)
f2 = new TF2("f2", "exp(-((x*cos(0.0)+y*sin(0.0))**2+0.25**2*(-x*sin(0.0)+y*cos(0.0))**2)/(2*45.0**2))*cos(6.28*(x*cos(0.0)+y*sin(0.0))/30.0 + 0)", -50, 50, -50, 50)
f1->Draw("colz")
f2->Draw("colz")
The maximum of this function should be at x = 0 & y = 0. function f2 correctly plotted the maximum, while the value of function f1 at x=y=0 is truncated.
_ROOT Version:_6.32.02
Platform: ubuntu24.04
Compiler: gcc13.3.0