forked from Mrkph86/cuenca
-
Notifications
You must be signed in to change notification settings - Fork 0
/
clear.f
50 lines (50 loc) · 2.12 KB
/
clear.f
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
CC PROGRAM 18 ! Based on Hromadka book pag 222
C -----------------------------------------------------------------------
! SUBROUTINE CLEAR(NUT,NDAT)
SUBROUTINE CLEAR(SS1,m,n,NUT,NDAT,Hydro,mn1,mn2) ! ARGU = NDAT 9.25.17
C -----------------------------------------------------------------------
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
C THIS SUBROUTINE CLEARS A SPECIFIED STREAM DATA BANK C
C Variables: C
C C
C K: Stream number to be set to 0 C
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
C -----------------------------------------------------------------------
C DECLARE VARIABLES
C -----------------------------------------------------------------------
IMPLICIT DOUBLE PRECISION (a-h, o-z)
!COMMON/BLK1/SS(600,10),SS1(600,10),Hydro(600,3)
DIMENSION SS(600,10),SS1(600,10),Hydro(600,3)
COMMON/BLK1/SS
DIMENSION A(600)
! EXPORT Hydrograph, Date (hours) StreamA(CFS)
C -----------------------------------------------------------------------
SS=SS1
! CLEAR THE K STREAM IN STREAM MATRIX SS
READ(NDAT,*)K
CALL MREAD(K,A)
DO 30 I=1,600
30 A(I)=0.D0
CALL MWRITE(K,A)
C ------------------------------------------------------------------------
C OUTPUT
C ------------------------------------------------------------------------
WRITE(NUT,101)K
101 FORMAT(10X,'STREAM NUMBER',I2,' IS SET TO ZERO.')
C ------------------------------------------------------------------------
C HYDROGRAPH TO EXPORT
C ------------------------------------------------------------------------
! Hydro(:,2)=A*(0.3048**3)!To obtain in m^3/S
! Hydro(600,2)=0
! DO 716 I=1,mn1
! IF(I==1) THEN
! Hydro(I,1)=0.083333
! ELSE
! J=I-1
! Hydro(I,1)=Hydro(J,1)+0.083333
! END IF
! WRITE(*,*) Hydro(I,1), Hydro(I,2), Hydro(I,3)
!716 CONTINUE
! SS1=SS
RETURN
END SUBROUTINE clear