Ignore:
Timestamp:
Sep 12, 2018 3:02:00 PM (6 years ago)
Author:
raasch
Message:

various changes to avoid compiler warnings (mainly removal of unused variables)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/vertical_nesting_mod.f90

    r3232 r3241  
    2626! -----------------
    2727! $Id$
     28! unused variables removed
     29!
     30! 3232 2018-09-07 12:21:44Z raasch
    2831! references to mrun replaced by palmrun, and updated
    2932!
     
    137140
    138141    INTEGER(iwp)                              :: n_cell_c         !> total no. of CG grid points in a PE
    139     INTEGER(iwp)                              :: n_cell_f         !> total no. of FG grid points in a PE
    140142    INTEGER(iwp),DIMENSION(2)                 :: pdims_partner    !> processor topology of partner PE
    141143    INTEGER(iwp)                              :: target_idex      !> temporary variable
     
    185187            f_rnk_lst, c_rnk_lst, cfratio, pdims_partner,                     &
    186188            nxc, nxf, nyc, nyf, nzc, nzf,                                     &
    187             ngp_c, ngp_f, target_idex, n_cell_c, n_cell_f,                    &
     189            ngp_c, ngp_f, target_idex, n_cell_c,                              &
    188190            offset, map_coord, TYPE_VNEST_BC, TYPE_VNEST_ANTER               
    189191
     
    253255        USE interfaces
    254256        USE pegrid
    255         USE surface_mod,                                                       &
    256             ONLY :  surf_def_h, surf_def_v
    257257        USE turbulence_closure_mod,                                            &
    258258            ONLY :  tcm_diffusivities
     
    264264        INTEGER(iwp)                          :: i
    265265        INTEGER(iwp)                          :: j
    266         INTEGER(iwp)                          :: k
    267         INTEGER(iwp)                          :: im
    268         INTEGER(iwp)                          :: jn
    269         INTEGER(iwp)                          :: ko
    270266        INTEGER(iwp)                          :: iif
    271267        INTEGER(iwp)                          :: jjf
     
    480476                comm_inter,status, ierr )
    481477            interpol3d => u
    482             call interpolate_to_fine_u ( 101 )
     478            call interpolate_to_fine_u
    483479   
    484480            CALL MPI_RECV( work3d,n_cell_c, MPI_REAL, target_idex, 102, &
    485481                comm_inter,status, ierr )
    486482            interpol3d => v
    487             call interpolate_to_fine_v ( 102 )
     483            call interpolate_to_fine_v
    488484   
    489485            CALL MPI_RECV( work3d,n_cell_c, MPI_REAL, target_idex, 103, &
    490486                comm_inter,status, ierr )
    491487            interpol3d => w
    492             call interpolate_to_fine_w ( 103 )
     488            call interpolate_to_fine_w
    493489   
    494490            CALL MPI_RECV( work3d,n_cell_c, MPI_REAL, target_idex, 105, &
    495491                comm_inter,status, ierr )
    496492            interpol3d => pt
    497             call interpolate_to_fine_s ( 105 )
     493            call interpolate_to_fine_s
    498494   
    499495            IF ( humidity )  THEN
     
    501497                comm_inter,status, ierr )
    502498            interpol3d => q
    503             call interpolate_to_fine_s ( 116 )
     499            call interpolate_to_fine_s
    504500            ENDIF
    505501
     
    507503                comm_inter,status, ierr )
    508504            interpol3d => e
    509             call interpolate_to_fine_s ( 104 )
     505            call interpolate_to_fine_s
    510506   
    511507!-- kh,km no target attribute, use of pointer not possible
    512508            CALL MPI_RECV( work3d,n_cell_c, MPI_REAL, target_idex, 106, &
    513509                comm_inter,status, ierr )
    514             call interpolate_to_fine_kh ( 106 )
     510            call interpolate_to_fine_kh
    515511   
    516512            CALL MPI_RECV( work3d,n_cell_c, MPI_REAL, target_idex, 107, &
    517513                comm_inter,status, ierr )
    518             call interpolate_to_fine_km ( 107 )
     514            call interpolate_to_fine_km
    519515   
    520516            DEALLOCATE(   work3d       )
     
    644640    CONTAINS
    645641   
    646        SUBROUTINE interpolate_to_fine_w( tag )
     642       SUBROUTINE interpolate_to_fine_w
    647643     
    648644           USE arrays_3d
     
    655651           IMPLICIT NONE
    656652     
    657            INTEGER(iwp), intent(in)           :: tag
    658653           INTEGER(iwp)                       :: i
    659654           INTEGER(iwp)                       :: j
     
    776771       END SUBROUTINE interpolate_to_fine_w
    777772     
    778        SUBROUTINE interpolate_to_fine_u( tag )
     773       SUBROUTINE interpolate_to_fine_u
    779774     
    780775     
     
    788783           IMPLICIT NONE
    789784     
    790            INTEGER(iwp), intent(in)           :: tag
    791785           INTEGER(iwp)                       :: i
    792786           INTEGER(iwp)                       :: j
     
    922916     
    923917     
    924        SUBROUTINE interpolate_to_fine_v( tag )
     918       SUBROUTINE interpolate_to_fine_v
    925919     
    926920     
     
    934928           IMPLICIT NONE
    935929
    936            INTEGER(iwp), intent(in)           :: tag
    937930           INTEGER(iwp)                       :: i
    938931           INTEGER(iwp)                       :: j
     
    10661059     
    10671060     
    1068        SUBROUTINE interpolate_to_fine_s( tag )
     1061       SUBROUTINE interpolate_to_fine_s
    10691062     
    10701063     
     
    10781071           IMPLICIT NONE
    10791072
    1080            INTEGER(iwp), intent(in)           :: tag
    10811073           INTEGER(iwp)                       :: i
    10821074           INTEGER(iwp)                       :: j
     
    12161208     
    12171209     
    1218        SUBROUTINE interpolate_to_fine_kh( tag )
     1210       SUBROUTINE interpolate_to_fine_kh
    12191211     
    12201212     
     
    12281220           IMPLICIT NONE
    12291221
    1230            INTEGER(iwp), intent(in)           :: tag
    12311222           INTEGER(iwp)                       :: i
    12321223           INTEGER(iwp)                       :: j
     
    12481239           REAL(wp)                           :: edot
    12491240           REAL(wp)                           :: eplus
    1250            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: uprs
    1251            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: vprs
    1252            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: wprs
    12531241           REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: ptprs
    1254            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: eprs
    1255            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: kmprs
    1256            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: khprs
    1257            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: tspr
    1258            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: uprf
    1259            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: vprf
    1260            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: wprf
    12611242           REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: ptprf
    1262            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: eprf
    1263            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: kmprf
    1264            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: khprf
    1265            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: uswspr
    1266            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: vswspr
    1267            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: uspr
    12681243     
    12691244     
     
    13841359       END SUBROUTINE interpolate_to_fine_kh
    13851360     
    1386        SUBROUTINE interpolate_to_fine_km( tag )
     1361       SUBROUTINE interpolate_to_fine_km
    13871362     
    13881363     
     
    13961371           IMPLICIT NONE
    13971372
    1398            INTEGER(iwp), intent(in)           :: tag
    13991373           INTEGER(iwp)                       :: i
    14001374           INTEGER(iwp)                       :: j
     
    14161390           REAL(wp)                           :: edot
    14171391           REAL(wp)                           :: eplus
    1418            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: uprs
    1419            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: vprs
    1420            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: wprs
    14211392           REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: ptprs
    1422            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: eprs
    1423            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: kmprs
    1424            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: khprs
    1425            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: vprf
    1426            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: wprf
    14271393           REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: ptprf
    1428            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: eprf
    1429            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: kmprf
    1430            REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: khprf
    1431            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: uswspr
    1432            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: vswspr
    1433            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: tspr
    1434            REAL(wp), DIMENSION(:,:), ALLOCATABLE   :: uspr
    14351394     
    14361395     
     
    15541513     
    15551514     
    1556        SUBROUTINE interpolate_to_fine_flux( tag )
     1515       SUBROUTINE interpolate_to_fine_flux
    15571516     
    15581517     
     
    15661525           IMPLICIT NONE
    15671526
    1568            INTEGER(iwp), intent(in)           :: tag
    15691527           INTEGER(iwp)                       :: i
    15701528           INTEGER(iwp)                       :: j
    1571            INTEGER(iwp)                       :: k
    15721529           INTEGER(iwp)                       :: iif
    15731530           INTEGER(iwp)                       :: jjf
    1574            INTEGER(iwp)                       :: kkf
    1575            INTEGER(iwp)                       :: nzbottom
    1576            INTEGER(iwp)                       :: nztop
    15771531           INTEGER(iwp)                       :: bottomx
    15781532           INTEGER(iwp)                       :: bottomy
    1579            INTEGER(iwp)                       :: bottomz
    15801533           INTEGER(iwp)                       :: topx
    15811534           INTEGER(iwp)                       :: topy
    1582            INTEGER(iwp)                       :: topz
    15831535           REAL(wp)                           :: eps
    15841536           REAL(wp)                           :: alpha
     
    17151667        INTEGER(iwp)                          :: iif
    17161668        INTEGER(iwp)                          :: jjf
    1717         REAL(wp)                              :: c_max
    1718         REAL(wp)                              :: denom
    17191669   
    17201670   
     
    18681818           INTEGER(iwp)                       :: i
    18691819           INTEGER(iwp)                       :: j
    1870            INTEGER(iwp)                       :: k
    18711820           INTEGER(iwp)                       :: iif
    18721821           INTEGER(iwp)                       :: jjf
    1873            INTEGER(iwp)                       :: kkf
    18741822           INTEGER(iwp)                       :: bottomx
    18751823           INTEGER(iwp)                       :: bottomy
     
    19731921           INTEGER(iwp)                       :: iif
    19741922           INTEGER(iwp)                       :: jjf
    1975            INTEGER(iwp)                       :: kkf
    19761923           INTEGER(iwp)                       :: bottomx
    19771924           INTEGER(iwp)                       :: bottomy
     
    20732020           INTEGER(iwp)                       :: iif
    20742021           INTEGER(iwp)                       :: jjf
    2075            INTEGER(iwp)                       :: kkf
    20762022           INTEGER(iwp)                       :: bottomx
    20772023           INTEGER(iwp)                       :: bottomy
     
    21822128           INTEGER(iwp)                       :: iif
    21832129           INTEGER(iwp)                       :: jjf
    2184            INTEGER(iwp)                       :: kkf
    21852130           INTEGER(iwp)                       :: bottomx
    21862131           INTEGER(iwp)                       :: bottomy
     
    23322277        INTEGER(iwp)                          :: iif
    23332278        INTEGER(iwp)                          :: jjf
    2334         REAL(wp)                              :: c_max
    2335         REAL(wp)                              :: denom
    23362279   
    23372280   
     
    24742417           INTEGER(iwp)                       :: iif
    24752418           INTEGER(iwp)                       :: jjf
    2476            INTEGER(iwp)                       :: kkf
    24772419           INTEGER(iwp)                       :: bottomx
    24782420           INTEGER(iwp)                       :: bottomy
     
    26142556           INTEGER(iwp)                       :: bottomx
    26152557           INTEGER(iwp)                       :: bottomy
    2616            INTEGER(iwp)                       :: bottomz
    26172558           INTEGER(iwp)                       :: topx
    26182559           INTEGER(iwp)                       :: topy
    2619            INTEGER(iwp)                       :: topz
    26202560           REAL(wp)                           :: eps
    26212561           REAL(wp)                           :: alpha
     
    27662706        INTEGER(iwp)                          ::  j
    27672707        INTEGER(iwp)                          ::  k
    2768         INTEGER(iwp)                          ::  im
    2769         INTEGER(iwp)                          ::  jn
    2770         INTEGER(iwp)                          ::  ko
    27712708        INTEGER(iwp)                          ::  kb !< variable to set respective boundary value, depends on facing.
    27722709        INTEGER(iwp)                          ::  l  !< running index boundary type, for up- and downward-facing walls
     
    29692906            anterpol3d => u
    29702907     
    2971             CALL anterpolate_to_crse_u ( 101 )
     2908            CALL anterpolate_to_crse_u
    29722909            CALL MPI_SEND( work3d, 1, TYPE_VNEST_ANTER, target_idex,  &
    29732910                101, comm_inter, ierr)
     
    29752912            anterpol3d => v
    29762913   
    2977             CALL anterpolate_to_crse_v ( 102 )
     2914            CALL anterpolate_to_crse_v
    29782915            CALL MPI_SEND( work3d, 1, TYPE_VNEST_ANTER, target_idex,  &
    29792916                102, comm_inter, ierr)
     
    29812918            anterpol3d => pt
    29822919   
    2983             CALL anterpolate_to_crse_s ( 105 )
     2920            CALL anterpolate_to_crse_s
    29842921            CALL MPI_SEND( work3d, 1, TYPE_VNEST_ANTER, target_idex,  &
    29852922                105, comm_inter, ierr)
     
    29902927            anterpol3d => q
    29912928   
    2992             CALL anterpolate_to_crse_s ( 106 )
     2929            CALL anterpolate_to_crse_s
    29932930            CALL MPI_SEND( work3d, 1, TYPE_VNEST_ANTER, target_idex,  &
    29942931                106, comm_inter, ierr)
     
    30012938                                 bdims_rem(1,1)  :bdims_rem(1,2)))
    30022939            anterpol3d => w
    3003             CALL anterpolate_to_crse_w ( 103 )
     2940            CALL anterpolate_to_crse_w
    30042941            CALL MPI_SEND( work3d, 1, TYPE_VNEST_ANTER, target_idex,  &
    30052942                103, comm_inter, ierr)
     
    30132950
    30142951    CONTAINS
    3015        SUBROUTINE anterpolate_to_crse_u( tag )
     2952       SUBROUTINE anterpolate_to_crse_u
    30162953     
    30172954     
     
    30252962           IMPLICIT NONE
    30262963
    3027            INTEGER(iwp), intent(in)           :: tag
     2964           INTEGER(iwp)                       :: i
     2965           INTEGER(iwp)                       :: j
     2966           INTEGER(iwp)                       :: k
     2967           INTEGER(iwp)                       :: iif
     2968           INTEGER(iwp)                       :: jjf
     2969           INTEGER(iwp)                       :: kkf
     2970           INTEGER(iwp)                       :: bottomy
     2971           INTEGER(iwp)                       :: bottomz
     2972           INTEGER(iwp)                       :: topy
     2973           INTEGER(iwp)                       :: topz
     2974           REAL(wp)                           :: aweight
     2975     
     2976           !
     2977           !-- Anterpolation of the velocity components u
     2978           !-- only values in yz-planes that coincide in the fine and
     2979           !-- the coarse grid are considered
     2980     
     2981           DO k = bdims_rem(3,1)+1, bdims_rem(3,2)
     2982     
     2983               bottomz = (dzc/dzf) * (k-1) + 1
     2984               topz    = (dzc/dzf) * k
     2985     
     2986               DO j = bdims_rem(2,1),bdims_rem(2,2)
     2987       
     2988                   bottomy = (nyf+1) / (nyc+1) * j
     2989                   topy    = (nyf+1) / (nyc+1) * (j+1) - 1
     2990     
     2991                   DO i = bdims_rem(1,1),bdims_rem(1,2)
     2992     
     2993                       iif = (nxf+1) / (nxc+1) * i
     2994     
     2995                       aweight   = 0.0
     2996     
     2997                       DO kkf = bottomz, topz
     2998                           DO jjf = bottomy, topy
     2999     
     3000                               aweight   = aweight + anterpol3d(kkf,jjf,iif) *        &
     3001                                   (dzf/dzc) * (dyf/dyc)
     3002     
     3003                           END DO
     3004                       END DO
     3005     
     3006                       work3d(k,j,i)   = aweight
     3007     
     3008                   END DO
     3009     
     3010               END DO
     3011     
     3012           END DO
     3013     
     3014     
     3015     
     3016       END SUBROUTINE anterpolate_to_crse_u
     3017     
     3018     
     3019       SUBROUTINE anterpolate_to_crse_v
     3020     
     3021     
     3022           USE arrays_3d
     3023           USE control_parameters
     3024           USE grid_variables
     3025           USE indices
     3026           USE pegrid
     3027           
     3028     
     3029           IMPLICIT NONE
     3030
     3031           INTEGER(iwp)                       :: i
     3032           INTEGER(iwp)                       :: j
     3033           INTEGER(iwp)                       :: k
     3034           INTEGER(iwp)                       :: iif
     3035           INTEGER(iwp)                       :: jjf
     3036           INTEGER(iwp)                       :: kkf
     3037           INTEGER(iwp)                       :: bottomx
     3038           INTEGER(iwp)                       :: bottomz
     3039           INTEGER(iwp)                       :: topx
     3040           INTEGER(iwp)                       :: topz
     3041           REAL(wp)                           :: aweight
     3042
     3043           !
     3044           !-- Anterpolation of the velocity components v
     3045           !-- only values in xz-planes that coincide in the fine and
     3046           !-- the coarse grid are considered
     3047     
     3048           DO k = bdims_rem(3,1)+1, bdims_rem(3,2)
     3049     
     3050               bottomz = (dzc/dzf) * (k-1) + 1
     3051               topz    = (dzc/dzf) * k
     3052     
     3053               DO j = bdims_rem(2,1), bdims_rem(2,2)
     3054     
     3055                   jjf = (nyf+1) / (nyc+1) * j
     3056     
     3057                   DO i = bdims_rem(1,1), bdims_rem(1,2)
     3058     
     3059                       bottomx = (nxf+1) / (nxc+1) * i
     3060                       topx    = (nxf+1) / (nxc+1) * (i+1) - 1
     3061     
     3062                       aweight   = 0.0
     3063     
     3064                       DO kkf = bottomz, topz
     3065                           DO iif = bottomx, topx
     3066     
     3067                               aweight   = aweight + anterpol3d(kkf,jjf,iif) *        &
     3068                                   (dzf/dzc) * (dxf/dxc)
     3069     
     3070     
     3071                           END DO
     3072                       END DO
     3073     
     3074                       work3d(k,j,i)   = aweight
     3075     
     3076                   END DO
     3077               END DO
     3078           END DO
     3079     
     3080     
     3081     
     3082       END SUBROUTINE anterpolate_to_crse_v
     3083     
     3084     
     3085       SUBROUTINE anterpolate_to_crse_w
     3086     
     3087     
     3088           USE arrays_3d
     3089           USE control_parameters
     3090           USE grid_variables
     3091           USE indices
     3092           USE pegrid
     3093           
     3094     
     3095           IMPLICIT NONE
     3096
     3097           INTEGER(iwp)                       :: i
     3098           INTEGER(iwp)                       :: j
     3099           INTEGER(iwp)                       :: k
     3100           INTEGER(iwp)                       :: iif
     3101           INTEGER(iwp)                       :: jjf
     3102           INTEGER(iwp)                       :: kkf
     3103           INTEGER(iwp)                       :: bottomx
     3104           INTEGER(iwp)                       :: bottomy
     3105           INTEGER(iwp)                       :: topx
     3106           INTEGER(iwp)                       :: topy
     3107           REAL(wp)                           :: aweight
     3108
     3109           !
     3110           !-- Anterpolation of the velocity components w
     3111           !-- only values in xy-planes that coincide in the fine and
     3112           !-- the coarse grid are considered
     3113     
     3114           DO k = bdims_rem(3,1), bdims_rem(3,2)-1
     3115     
     3116               kkf = cfratio(3) * k
     3117     
     3118               DO j = bdims_rem(2,1), bdims_rem(2,2)
     3119     
     3120                   bottomy = (nyf+1) / (nyc+1) * j
     3121                   topy    = (nyf+1) / (nyc+1) * (j+1) - 1
     3122     
     3123                   DO i = bdims_rem(1,1), bdims_rem(1,2)
     3124     
     3125                       bottomx = (nxf+1) / (nxc+1) * i
     3126                       topx    = (nxf+1) / (nxc+1) * (i+1) - 1
     3127     
     3128                       aweight   = 0.0
     3129     
     3130                       DO jjf = bottomy, topy
     3131                           DO iif = bottomx, topx
     3132     
     3133                               aweight   = aweight + anterpol3d (kkf,jjf,iif) *        &
     3134                                   (dxf/dxc) * (dyf/dyc)
     3135     
     3136                           END DO
     3137                       END DO
     3138     
     3139                       work3d(k,j,i)   = aweight
     3140     
     3141                   END DO
     3142     
     3143               END DO
     3144     
     3145           END DO
     3146     
     3147     
     3148       END SUBROUTINE anterpolate_to_crse_w
     3149     
     3150     
     3151       SUBROUTINE anterpolate_to_crse_s
     3152     
     3153     
     3154           USE arrays_3d
     3155           USE control_parameters
     3156           USE grid_variables
     3157           USE indices
     3158           USE pegrid
     3159           
     3160     
     3161           IMPLICIT NONE
     3162
    30283163           INTEGER(iwp)                       :: i
    30293164           INTEGER(iwp)                       :: j
     
    30413176     
    30423177           !
    3043            !-- Anterpolation of the velocity components u
    3044            !-- only values in yz-planes that coincide in the fine and
    3045            !-- the coarse grid are considered
    3046      
    3047            DO k = bdims_rem(3,1)+1, bdims_rem(3,2)
    3048      
    3049                bottomz = (dzc/dzf) * (k-1) + 1
    3050                topz    = (dzc/dzf) * k
    3051      
    3052                DO j = bdims_rem(2,1),bdims_rem(2,2)
    3053        
    3054                    bottomy = (nyf+1) / (nyc+1) * j
    3055                    topy    = (nyf+1) / (nyc+1) * (j+1) - 1
    3056      
    3057                    DO i = bdims_rem(1,1),bdims_rem(1,2)
    3058      
    3059                        iif = (nxf+1) / (nxc+1) * i
    3060      
    3061                        aweight   = 0.0
    3062      
    3063                        DO kkf = bottomz, topz
    3064                            DO jjf = bottomy, topy
    3065      
    3066                                aweight   = aweight + anterpol3d(kkf,jjf,iif) *        &
    3067                                    (dzf/dzc) * (dyf/dyc)
    3068      
    3069                            END DO
    3070                        END DO
    3071      
    3072                        work3d(k,j,i)   = aweight
    3073      
    3074                    END DO
    3075      
    3076                END DO
    3077      
    3078            END DO
    3079      
    3080      
    3081      
    3082        END SUBROUTINE anterpolate_to_crse_u
    3083      
    3084      
    3085        SUBROUTINE anterpolate_to_crse_v( tag )
    3086      
    3087      
    3088            USE arrays_3d
    3089            USE control_parameters
    3090            USE grid_variables
    3091            USE indices
    3092            USE pegrid
    3093            
    3094      
    3095            IMPLICIT NONE
    3096 
    3097            INTEGER(iwp), intent(in)           :: tag
    3098            INTEGER(iwp)                       :: i
    3099            INTEGER(iwp)                       :: j
    3100            INTEGER(iwp)                       :: k
    3101            INTEGER(iwp)                       :: iif
    3102            INTEGER(iwp)                       :: jjf
    3103            INTEGER(iwp)                       :: kkf
    3104            INTEGER(iwp)                       :: bottomx
    3105            INTEGER(iwp)                       :: bottomy
    3106            INTEGER(iwp)                       :: bottomz
    3107            INTEGER(iwp)                       :: topx
    3108            INTEGER(iwp)                       :: topy
    3109            INTEGER(iwp)                       :: topz
    3110            REAL(wp)                           :: aweight
    3111 
    3112            !
    3113            !-- Anterpolation of the velocity components v
    3114            !-- only values in xz-planes that coincide in the fine and
    3115            !-- the coarse grid are considered
    3116      
    3117            DO k = bdims_rem(3,1)+1, bdims_rem(3,2)
    3118      
    3119                bottomz = (dzc/dzf) * (k-1) + 1
    3120                topz    = (dzc/dzf) * k
    3121      
    3122                DO j = bdims_rem(2,1), bdims_rem(2,2)
    3123      
    3124                    jjf = (nyf+1) / (nyc+1) * j
    3125      
    3126                    DO i = bdims_rem(1,1), bdims_rem(1,2)
    3127      
    3128                        bottomx = (nxf+1) / (nxc+1) * i
    3129                        topx    = (nxf+1) / (nxc+1) * (i+1) - 1
    3130      
    3131                        aweight   = 0.0
    3132      
    3133                        DO kkf = bottomz, topz
    3134                            DO iif = bottomx, topx
    3135      
    3136                                aweight   = aweight + anterpol3d(kkf,jjf,iif) *        &
    3137                                    (dzf/dzc) * (dxf/dxc)
    3138      
    3139      
    3140                            END DO
    3141                        END DO
    3142      
    3143                        work3d(k,j,i)   = aweight
    3144      
    3145                    END DO
    3146                END DO
    3147            END DO
    3148      
    3149      
    3150      
    3151        END SUBROUTINE anterpolate_to_crse_v
    3152      
    3153      
    3154        SUBROUTINE anterpolate_to_crse_w( tag )
    3155      
    3156      
    3157            USE arrays_3d
    3158            USE control_parameters
    3159            USE grid_variables
    3160            USE indices
    3161            USE pegrid
    3162            
    3163      
    3164            IMPLICIT NONE
    3165 
    3166            INTEGER(iwp), intent(in)           :: tag
    3167            INTEGER(iwp)                       :: i
    3168            INTEGER(iwp)                       :: j
    3169            INTEGER(iwp)                       :: k
    3170            INTEGER(iwp)                       :: iif
    3171            INTEGER(iwp)                       :: jjf
    3172            INTEGER(iwp)                       :: kkf
    3173            INTEGER(iwp)                       :: bottomx
    3174            INTEGER(iwp)                       :: bottomy
    3175            INTEGER(iwp)                       :: bottomz
    3176            INTEGER(iwp)                       :: topx
    3177            INTEGER(iwp)                       :: topy
    3178            INTEGER(iwp)                       :: topz
    3179            REAL(wp)                           :: aweight
    3180 
    3181            !
    3182            !-- Anterpolation of the velocity components w
    3183            !-- only values in xy-planes that coincide in the fine and
    3184            !-- the coarse grid are considered
    3185      
    3186            DO k = bdims_rem(3,1), bdims_rem(3,2)-1
    3187      
    3188                kkf = cfratio(3) * k
    3189      
    3190                DO j = bdims_rem(2,1), bdims_rem(2,2)
    3191      
    3192                    bottomy = (nyf+1) / (nyc+1) * j
    3193                    topy    = (nyf+1) / (nyc+1) * (j+1) - 1
    3194      
    3195                    DO i = bdims_rem(1,1), bdims_rem(1,2)
    3196      
    3197                        bottomx = (nxf+1) / (nxc+1) * i
    3198                        topx    = (nxf+1) / (nxc+1) * (i+1) - 1
    3199      
    3200                        aweight   = 0.0
    3201      
    3202                        DO jjf = bottomy, topy
    3203                            DO iif = bottomx, topx
    3204      
    3205                                aweight   = aweight + anterpol3d (kkf,jjf,iif) *        &
    3206                                    (dxf/dxc) * (dyf/dyc)
    3207      
    3208                            END DO
    3209                        END DO
    3210      
    3211                        work3d(k,j,i)   = aweight
    3212      
    3213                    END DO
    3214      
    3215                END DO
    3216      
    3217            END DO
    3218      
    3219      
    3220        END SUBROUTINE anterpolate_to_crse_w
    3221      
    3222      
    3223        SUBROUTINE anterpolate_to_crse_s( tag )
    3224      
    3225      
    3226            USE arrays_3d
    3227            USE control_parameters
    3228            USE grid_variables
    3229            USE indices
    3230            USE pegrid
    3231            
    3232      
    3233            IMPLICIT NONE
    3234 
    3235            INTEGER(iwp), intent(in)           :: tag
    3236            INTEGER(iwp)                       :: i
    3237            INTEGER(iwp)                       :: j
    3238            INTEGER(iwp)                       :: k
    3239            INTEGER(iwp)                       :: iif
    3240            INTEGER(iwp)                       :: jjf
    3241            INTEGER(iwp)                       :: kkf
    3242            INTEGER(iwp)                       :: bottomx
    3243            INTEGER(iwp)                       :: bottomy
    3244            INTEGER(iwp)                       :: bottomz
    3245            INTEGER(iwp)                       :: topx
    3246            INTEGER(iwp)                       :: topy
    3247            INTEGER(iwp)                       :: topz
    3248            REAL(wp)                           :: aweight
    3249      
    3250            !
    32513178           !-- Anterpolation of the potential temperature pt
    32523179           !-- all fine grid values are considered
     
    33173244        INTEGER(iwp)                          :: i
    33183245        INTEGER(iwp)                          :: j
    3319         INTEGER(iwp)                          :: k
    3320         INTEGER(iwp)                          :: im
    3321         INTEGER(iwp)                          :: jn
    3322         INTEGER(iwp)                          :: ko
    3323    
    33243246   
    33253247        !
     
    34373359            anterpol3d => e
    34383360   
    3439             CALL anterpolate_to_crse_e ( 104 )
     3361            CALL anterpolate_to_crse_e
    34403362
    34413363            CALL MPI_SEND( work3d, 1, TYPE_VNEST_ANTER, target_idex,  &
     
    34533375   
    34543376   
    3455        SUBROUTINE anterpolate_to_crse_e( tag )
     3377       SUBROUTINE anterpolate_to_crse_e
    34563378     
    34573379     
     
    34653387           IMPLICIT NONE
    34663388
    3467            INTEGER(iwp), intent(in)           :: tag
    34683389           INTEGER(iwp)                       :: i
    34693390           INTEGER(iwp)                       :: j
     
    35653486
    35663487
    3567        USE control_parameters,                                                    &
    3568            ONLY:  coupling_mode, coupling_mode_remote, coupling_topology, dz
    3569 
    3570        USE grid_variables,                                                        &
    3571            ONLY:  dx, dy
    3572            
    3573        USE indices,                                                               &
    3574            ONLY: nbgp, nx, ny, nz
     3488       USE control_parameters,                                                 &
     3489           ONLY:  coupling_mode
    35753490
    35763491       USE kinds
     
    35883503               CALL MPI_SEND( pdims, 2, MPI_INTEGER, numprocs, 33, comm_inter, &
    35893504                   ierr )
    3590                CALL MPI_RECV( pdims_partner, 2, MPI_INTEGER, numprocs, 66,      &
     3505               CALL MPI_RECV( pdims_partner, 2, MPI_INTEGER, numprocs, 66,     &
    35913506                   comm_inter, status, ierr )
    35923507           ELSEIF ( coupling_mode == 'vnested_fine') THEN
     
    36493564#if defined( __parallel )
    36503565
    3651        USE control_parameters,                                                    &
    3652            ONLY:  coupling_mode, coupling_mode_remote, coupling_topology, dz,     &
     3566       USE control_parameters,                                                 &
     3567           ONLY:  coupling_mode, coupling_topology, dz,                        &
    36533568                  dz_stretch_level_start, message_string
    36543569
    3655        USE grid_variables,                                                        &
     3570       USE grid_variables,                                                     &
    36563571           ONLY:  dx, dy
    36573572           
    3658        USE indices,                                                               &
    3659            ONLY: nbgp, nx, ny, nz, nxl, nxr, nys, nyn, nzb, nzt, &
    3660                  nxlg, nxrg, nysg, nyng
     3573       USE indices,                                                            &
     3574           ONLY: nbgp, nx, ny, nz, nxl, nxr, nys, nyn, nzb, nzt
    36613575
    36623576       USE kinds
     
    36663580       IMPLICIT NONE
    36673581
    3668        INTEGER(iwp)                           :: dest_rnk
    36693582       INTEGER(iwp)                           :: i              !<
    36703583       INTEGER(iwp)                           :: j              !<
Note: See TracChangeset for help on using the changeset viewer.