Rnumb

advertisement
Rnumb
The code Rnumb.for which is called from TRNUMB.FOR is designed to extract a single number
from a string beginning at location IP which is updated to the next character on return from the call. The
call is REALA=RNUMB(STRING,IP)
The string "1.23e-5
comment" is returned as REALA=0.0000123, STRING(:IP) = comment.
The string "T
comment" is returned as REALA=0, STRING(:IP) = comment.
The string "TT
comment" is returned as REALA=0, STRING(:IP) = T
comment.
Chread
The code CHREAD.FOR is a general read code CHREAD(IUNIT,RANS,CRET,NR,IEND) that
reads a string from the specified unit and returns NR reals and the rest of the line as CRET. If the line is at
the end of a file it returns IEND=1. It is tested by TCHREAD.FOR.
1/4/2009
The original rnumb is in ORNUMB.FOR. The current RNUMB.for attempts to use string reads
rather than detailed analysis of the input line. This is reached by rnumb.wpj.
Download