88 REAL(wp),
ALLOCATABLE ::
h_old(:,:)
124 ALLOCATE(
bcw(n_vars) ,
bce(n_vars) ,
bcs(n_vars) ,
bcn(n_vars) )
127 h_bcw%VALUE= 0.0000000000000000
129 hu_bcw%VALUE= 0.0000000000000000
131 hv_bcw%VALUE= 0.0000000000000000
138 h_bce%VALUE= 0.0000000000000000
140 hu_bce%VALUE= 0.0000000000000000
142 hv_bce%VALUE= 0.0000000000000000
149 h_bcs%VALUE= 0.0000000000000000
151 hu_bcs%VALUE= 0.0000000000000000
153 hv_bcs%VALUE= 0.0000000000000000
160 h_bcn%VALUE= 0.0000000000000000
162 hu_bcn%VALUE= 0.0000000000000000
164 hv_bcn%VALUE= 0.0000000000000000
170 time_param(1) = t_end
171 time_param(2) = t_end
172 time_param(3) = 0.0_wp
173 time_param(4) = t_end
186 WRITE(*,*)
'x_source =',x_source
187 WRITE(*,*)
'y_source =',y_source
188 WRITE(*,*)
'r_source =',r_source
189 WRITE(*,*)
'grav =',
grav 229 REAL(wp),
INTENT(IN) :: time
230 LOGICAL,
INTENT(IN) :: steady_state
232 CHARACTER(LEN=4) :: idx_string
234 REAL(wp) :: qp(n_vars+2)
236 REAL(wp) :: r_u , r_v , r_h
242 IF ( .NOT. steady_state )
THEN 265 CALL qc_to_qp(
q(1:n_vars,j,k) , qp(1:n_vars+2))
271 IF ( abs( r_h ) .LT. 1e-20_wp) r_h = 0.0_wp
272 IF ( abs( r_u ) .LT. 1e-20_wp) r_u = 0.0_wp
273 IF ( abs( r_v ) .LT. 1e-20_wp) r_v = 0.0_wp
289 1010
FORMAT(100es15.7e2)
317 CHARACTER*4 FUNCTION lettera(k)
319 CHARACTER ones,tens,hund,thou
323 INTEGER :: iten, ione, ihund, ithou
326 ihund=int((k-(ithou*1000))/100)
327 iten=int((k-(ithou*1000)-(ihund*100))/10)
328 ione=k-ithou*1000-ihund*100-iten*10
integer n_rk
Runge-Kutta order.
integer comp_cells_x
Number of control volumes x in the comp. domain.
real(wp) dt0
Initial time step.
integer comp_cells_y
Number of control volumes y in the comp. domain.
type(bc), dimension(:), allocatable bcw
bcW&flag defines the west boundary condition:
real(wp) x0
Left of the physical domain.
real(wp) t_output
time of the next output
integer n_vars
Number of conservative variables.
real(wp), dimension(:), allocatable x_comp
Location of the centers (x) of the control volume of the domain.
real(wp) dt_output
time interval for the output of the solution
real(wp) cfl
Courant-Friedrichs-Lewy parameter.
character *4 function lettera(k)
Numeric to String conversion.
character(len=20) solver_scheme
Finite volume method: .
logical output_phys_flag
Flag to save the physical variables on file *.p_2d.
integer, parameter output_unit_2d
Output data 2D unit.
integer, parameter output_unit
Output data unit.
logical output_cons_flag
Flag to save the conservative variables on file *.q_2d.
character(len=40) output_file
Name of the output files.
subroutine qc_to_qp(qc, qp)
Conservative to physical variables.
real(wp) t_end
end time for the run
real(wp) dx
Control volumes size.
real(wp), dimension(:,:), allocatable probes_coords
integer, dimension(10) limiter
Limiter for the slope in the linear reconstruction: .
integer output_idx
Counter for the output files.
integer, parameter wp
working precision
type(bc), dimension(:), allocatable bcn
bcN&flag defines the north boundary condition:
integer n_eqns
Number of equations.
character(len=40) output_file_2d
Name of the output files.
real(wp) max_dt
Largest time step allowed.
character(len=30) run_name
Name of the run (used for the output and backup files)
subroutine init_param
Initialization of the variables read from the input file.
real(wp) t_start
initial time for the run
real(wp), dimension(:,:,:), allocatable q
Conservative variables.
type(bc), dimension(:), allocatable bcs
bcS&flag defines the south boundary condition:
real *8 gi
Gravity acceleration.
real(wp) y0
Bottom of the physical domain.
type(bc), dimension(:), allocatable bce
bcE&flag defines the east boundary condition:
real(wp), dimension(4) time_param
real(wp) theta
Van Leer limiter parameter.
real(wp), dimension(:,:), allocatable h_old
real(wp) reconstr_coeff
Slope coefficient in the linear reconstruction.
subroutine output_solution(time, steady_state)
Write the solution on the output unit.
logical interfaces_relaxation
Flag to add the relaxation terms after the linear reconstruction: .
real(wp), dimension(:), allocatable y_comp
Location of the centers (y) of the control volume of the domain.
integer verbose_level
Level of verbose output (0 = minimal output on screen)
real(wp) dy
Control volumes size.