program plot_fit_range real x(1001),y(1001) integer pgopen if(pgopen('/xwin')<=0)stop xmax=2*3.14159 xmin=0.0 dx=(xmax-xmin)/1000 do i=1,1001 x(i)=(i-1)*dx y(i)=sin(x(i)) end do ymax=sin(0.0) ymin=ymax do i=2,1001 if(y(i)>ymax)ymax=y(i) if(y(i)