define hwid 15 set x=1,512 set y=x*0 set w=-1**x define N 512 # set random 1001 set x=1,$N do i=1,10 { set t=random($N)-0.5 set y=y+t } set y=y/10 window 1 2 1 2 limits x -.3 .3 smooth y ys $hwid box ltype 1 connect x y ltype 0 ctype red connect x ys ctype default relocate 0 .25 label Boxcar width = $hwid window 1 2 1 1 set z=x*0 set y=ys*w fft 1 y z r i set r=r*w set i=i*w set xt=x-257 set xx=xt concat xt set yy=r concat i limits xx -.007 .007 ! limits -10 10 yy box connect xt r ctype red connect xt i ctype default