APPENDIX 



COMPUTER PROGRAM DOCUMENTATION (INLET) 



1. Program Description . 



The numerical model to predict inlet hydraulics is programed in 

 FORTRAN for a CDC 6600 computer. The simultaneous differential equations 

 are solved by a variable time step Runge-Kutta-Gill marching procedure. 

 The organization of the computer program is shown in Figure A-1. A brief 

 description of each routine follows: 



INLET is the main routine which controls input-output and calls 

 subroutines to execute a specific task. Figure A-1 summarizes control 

 throughout the program. The program is organized to accept up to three 

 inlets connecting the bay to the sea, up to seven channels for each in- 

 let, and up to eight cross sections (seven grids long). 



Subroutine HE LM uses an iterative method of estimating the natural 

 pumping period or Helmholtz period, T^' , for the inlet-bay system by 

 neglecting friction in the inlet to give: 



2Tr 



(kn - L') A 



'bay 



where L' is added inlet length due to radiation, and where L' is 

 given by: 



L' = ^ In 



Subroutine RKGS is a routine to solve simultaneous differential 

 equations. This subroutine was adapted from the scientific subroutine 

 package. 



Subroutine SETEQ evaluates the right-hand side of the equation of 

 motion, one for each inlet, and the continuity equation between the inlet 

 and bay for each step. This routine also evaluates the relative rank of 

 the four terms in the equation of motion for flow in each inlet. 



Subroutine LEVEL determines the water level in the grids at each 

 time step. The routine interpolates the level between the sea and bay 

 based on the relative amount of friction in each grid cell. 



Subroutine TPWRTE writes hydraulic results from each time step on a 

 tape or disc, so that this information can be used later by the output 

 routines . 



Subroutine TABLE outputs a table of instantaneous hydraulics each 

 time the routine is called. 



21 



