The TELEMAC-MASCARET system  trunk
mean_grain_size.f
Go to the documentation of this file.
1 ! **************************
2  SUBROUTINE mean_grain_size
3 ! **************************
4 !
5 !
6 !***********************************************************************
7 ! SISYPHE V6P1 21/07/2011
8 !***********************************************************************
9 !
10 !brief GEOMETRIC MEAN GRAIN SIZES OF ACTIVE-LAYER AND UNDER-LAYER.
11 !
12 !history BUI MINH DUC
13 !+ **/11/2002
14 !+ V6P0
15 !+
16 !
17 !history N.DURAND (HRW), S.E.BOURBAN (HRW)
18 !+ 13/07/2010
19 !+ V6P0
20 !+ Translation of French comments within the FORTRAN sources into
21 !+ English comments
22 !
23 !history N.DURAND (HRW), S.E.BOURBAN (HRW)
24 !+ 21/08/2010
25 !+ V6P0
26 !+ Creation of DOXYGEN tags for automated documentation and
27 !+ cross-referencing of the FORTRAN sources
28 !
29 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
30 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
31 !
32  USE bief
35 !
37  IMPLICIT NONE
38 !
39 !-----------------------------------------------------------------------
40 !
41  INTEGER I,J
42 !
43 !-----------------------------------------------------------------------
44 !
45 ! UNLADM IS NEEDED FOR HUNZIKER
46 !
47  DO j=1,npoin
48  acladm%R(j) = 0.d0
49  unladm%R(j) = 0.d0
50  IF(nsicla.GT.1) THEN
51  DO i=1,nsicla
52  IF(avail(j,1,i).GT.0.d0) THEN
53  acladm%R(j) = acladm%R(j) + fdm(i)*avail(j,1,i)
54  unladm%R(j) = unladm%R(j) + fdm(i)*avail(j,2,i)
55  ENDIF
56  ENDDO
57  ENDIF
58  IF(acladm%R(j).LE.0.d0) acladm%R(j) = fdm(1)
59  IF(unladm%R(j).LE.0.d0) unladm%R(j) = acladm%R(j)
60  ENDDO
61 
63 !
64 !-----------------------------------------------------------------------
65 !
66  RETURN
67  END
type(bief_obj), target unladm
type(bief_obj), target acladm
subroutine mean_grain_size
subroutine user_mean_grain_size
double precision, dimension(nsiclm), target fdm
double precision, dimension(:,:,:), allocatable, target avail
Definition: bief.f:3