implicit none
integer :: N
real :: V,AC,BC,RSI,V_max
real,allocatable :: RS(:),QS(:),Q(:)
integer :: t,nt,i
integer :: size1 !用于计数
character(len=512)::buffer1 !用于读取一整行
logical::alive1
integer::status1
character(len=120)::Address,filename
open(10,file='地址.txt')
read(10,*)Address
close(10)
! 从文件读入净雨过程RS(1h净雨过程)
filename=trim(Address)//'净雨过程.txt'
size1=0
inquire(file=filename,exist=alive1)
if(alive1)then
open(10,file=filename,access="sequential",status="old")
do while(.true.)
read(10,"(A512)",iostat=status1)buffer1
if(status1/=0)exit
size1=size1+1
end do
else
write(*,*)TRIM(filename),"不存在。"
stop
end if
allocate(RS(size1))
rewind(10)
read(10,*)
do i=1,size1
read(10,*)RS(i)
end do
close(10)