
!if empty isin $diff
 !exit
!endif

fn=$(fn_$func)
reply_fn=!trim $(reply_fn_$func)

!if $reply_fn = $empty
 diff=empty $func
 !exit
!endif

inp=print(3)
!for i = 1 to $checkpoints
 inp=$inp\
   $name_x=$(checkpoint$i);print(y1=$reply_fn)\
   x=$(checkpoint$i);print(y2=$fn)\
   print(abs(y1-y2))
!next i
s=!exec pari $inp
totabs=0
!for i = 1 to $checkpoints
 answer=!line 3*$i-1 of $s
 real=!line 3*$i of $s
 abs=!line 3*$i+1 of $s
 answer=!eval $answer
 totabs=!eval $totabs+|$answer|
 !if $answer = $empty
   diff=unrecognized
   !exit
 !endif
 diff=!eval $diff+$abs
!next i


