Module watmod
386 :
387 : ! ******************************************************************
388 : ! * Module defining variables and parameters for the water balance
389 : ! * model (watbal).
390 : ! ******************************************************************
391 :
392 : module watmod
393 : implicit none
394 :
395 : INTEGER :: wlayer_ ! Number of soil layers in unsaturated zone
396 : INTEGER :: wlayernew ! Number of layers in unsaturated zone for next time step
397 :
398 : REAL*8 :: dt_ ! Length of time step (s)
399 : REAL*8 :: dtmax ! Maximum time step (s)
400 : INTEGER :: dtsu_count, dtmax_count ! For speed analysis, count of how often dtsu or dtmax is time limiting
401 :
402 : REAL*8 :: esoil__ ! Bare soil evaporation rate
403 : REAL*8 :: esoil_h ! Hourly soil evaporation
404 : REAL*8 :: esoil_d ! Daily soil evaporation rate
405 : REAL*8 :: esoil_y ! Annual soil evaporation rate
406 :
407 : REAL*8 :: spgfcf__ ! Seepage face flow rate
408 : REAL*8 :: spgfcf_h ! Hourly seepage face flow
409 : REAL*8 :: spgfcf_d ! Daily seepage face flow
410 :
411 : REAL*8 :: inf__ ! Infiltration rate
412 : REAL*8 :: infx__ ! Infiltration excess runoff rate
413 : REAL*8 :: infx_h ! Hourly infiltration excess runoff
414 : REAL*8 :: infx_d ! Daily infiltration excess runoff
415 :
416 : REAL*8 :: zw_ ! Elevation of water table
417 : REAL*8 :: zwnew ! Elevation of water table at next time step
418 :
419 : REAL*8 :: wc_
420 :
421 : REAL*8, ALLOCATABLE :: cH2Ol_s(:) ! Soil water content in each layer (could also be called theta(:))
422 :
423 : REAL*8, ALLOCATABLE :: qbl(:) ! Water flux across bottom boundary of each layer (positive upwards)
424 :
425 : REAL*8, ALLOCATABLE :: pcap_(:) ! Soil matric head (m)
426 : REAL*8, ALLOCATABLE :: pcapnew(:) ! Matric pressure head in each layer at next time step
427 :
428 : REAL*8, ALLOCATABLE :: iovec(:) ! Mass balance for each soil layer
429 : REAL*8 :: io__ ! Input minus output of water in soil domain
430 : REAL*8 :: io_h ! Hourly input minus output of water in soil domain
431 : REAL*8 :: ioacum ! Cumulative mass balance of soil water
432 :
433 : REAL*8, ALLOCATABLE :: su__(:) ! Soil saturation degree in each layer
434 : REAL*8, ALLOCATABLE :: sunew(:) ! Soil saturation degree in each layer at next time step
435 : REAL*8, ALLOCATABLE :: sueq(:) ! Soil saturation degree above water table in hydrostatic equilibrium
436 : REAL*8, ALLOCATABLE :: dsu(:) ! Rate of change in soil saturation degree in each layer
437 :
438 : REAL*8, ALLOCATABLE :: kunsat_(:) ! Unsaturated hydraulic conductivity in each soil layer
439 : REAL*8, ALLOCATABLE :: kunsatnew(:) ! Unsaturated hydraulic conductivity in each layer at next time step
440 :
441 : REAL*8, ALLOCATABLE :: s_ksat(:) ! Saturated hydraulic conductivity
442 : REAL*8, ALLOCATABLE :: s_thetas(:) ! Saturated soil water content
443 : REAL*8, ALLOCATABLE :: s_thetar(:) ! Residual soil water content
444 : REAL*8, ALLOCATABLE :: s_nvg(:) ! Van Genuchten soil parameter n
445 : REAL*8, ALLOCATABLE :: s_avg(:) ! Van Genuchten soil parameter a
446 : REAL*8, ALLOCATABLE :: c_mvg(:) ! Van Genuchten soil parameter m
447 :
448 : ! ****************************
449 : ! * input parameters input.par
450 : ! ****************************
451 :
452 : ! * Catchment parameters
453 :
454 : REAL*8 :: i_cgs ! Capital Gamma S (length scale for seepage outflow) (m)
455 : REAL*8 :: i_zr ! Average channel elevation
456 : REAL*8 :: i_go ! Slope close to channel in radians
457 :
458 : ! * Soil parameters
459 :
460 : REAL*8 :: i_ksat ! Saturated hydraulic conductivity
461 : REAL*8 :: i_thetar ! Residual soil water content
462 : REAL*8 :: i_thetas ! Saturated soil water content
463 : REAL*8 :: i_nvg ! Van Genuchten soil parameter n
464 : REAL*8 :: i_avg ! Van Genuchten soil parameter a
465 : REAL*8 :: i_mvg ! Van Genuchten soil parameter m
466 :
467 : !$OMP threadprivate(wlayer_, wlayernew, dt_, dtmax, dtsu_count, dtmax_count, esoil__, esoil_h, &
468 : !$OMP i_cgs, i_zr, i_go, i_ksat, i_thetar, i_thetas, i_nvg, i_avg, &
469 : !$OMP esoil_d, esoil_y, spgfcf__, spgfcf_h, spgfcf_d, inf__, infx__, infx_h, infx_d, &
470 : !$OMP pcap_, su__, sunew, kunsat_, qbl, dsu, pcapnew, kunsatnew, sueq, cH2Ol_s, iovec, &
471 : !$OMP zw_, zwnew, wc_, io__, io_h, ioacum)
472 :
473 : end module watmod