integer function ispartnum(c) implicit none !ispartnum = 1, c is one of the following: 0 to 9, +, -, ., d, D, E, e, N, n, a, and A. ! = 0, otherwise character c*1 integer i ! ispartnum=0 i=ichar(c) if(i.ge.48.and.i.le.57)ispartnum=1 if(i.eq.43.or.i.eq.45.or.i.eq.46.or.i.eq.68.or. &i.eq.69.or.i.eq.100.or.i.eq.101)ispartnum=1 if(c.eq.'.'.or.c.eq.'+'.or.c.eq.'-')ispartnum=1 if(c.eq.'d'.or.c.eq.'D'.or.c.eq.'e'.or.c.eq.'E') &ispartnum=1 if(c.eq.'n'.or.c.eq.'N'.or.c.eq.'a'.or.c.eq.'A') &ispartnum=1 return end