1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69
|
dd=!deaccent $(reply$i)
units_option=s
dd=!exec units-filter $dd
units_option=
!! the value
dt=!word 1 of $dd
d1=$[$dt]
test=$d1
!! the unit and number of digits
d2=!word 2 to 8 of $dd
!! the number of digits
d3=!word 9 of $dd
m_reply$i=$(reply$i)
!if $wims_read_parm=nocompare
!if NaN isin $d1 or Inf isin $d1 or ERROR isin $d1 or $dt=$empty
test=NaN
!endif
!exit
!endif
gg=!deaccent $(replygood$i)
units_option=o
replyGood$i=!exec units-filter $(replygood$i)
units_option=s
gg=!exec units-filter $(replyGood$i)
units_option=
!! the value
good=!word 1 of $(replyGood$i)
good1=!word 1 of $gg
!!!!good1=$[$good]
!! the units and number of digits
good2=!word 2 to 8 of $gg
!! the number of digits
good3=!word 9 of $gg
!if NaN isin $good or Inf isin $good or ERROR isin $good or $good=$empty
test=bad $i
!exit
!endif
!if NaN isin $d1 or Inf isin $d1 or ERROR isin $d1 or $dt=$empty
test=NaN
!exit
!endif
diff=$[abs($test-($good1))]
!if NaN isin $diff or Inf isin $diff
test=NaN
!exit
!endif
emptyunit=0 0 0 0 0 0 0
!if $good2!=$emptyunit and $d2=$emptyunit
test=NaN notunit
!exit
!endif
!!writefile getfile/log $[$good1]=$d1 and $good2=$d2 and $d3=$good3
!if $[$good1]=$d1 and $good2=$d2 and $d3=$good3
diareply$i=good
!advance freegot
!else
diareply$i=bad
!endif
|