Index: palm/trunk/SOURCE/nesting_offl_mod.f90
===================================================================
--- palm/trunk/SOURCE/nesting_offl_mod.f90	(revision 4286)
+++ palm/trunk/SOURCE/nesting_offl_mod.f90	(revision 4329)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! Renamed wall_flags_0 to wall_flags_static_0
+! 
+! 4286 2019-10-30 16:01:14Z resler
 ! Fix wrong checks of time from dynamic driver in nesting_offl_mod
 ! 
@@ -188,5 +191,5 @@
                nysv, nysg, nyn, nyng, nzb, nz, nzt,                            &
                topo_top_ind,                                                   &
-               wall_flags_0
+               wall_flags_static_0
 
     USE kinds
@@ -863,5 +866,5 @@
                 volume_flow_l(1) = volume_flow_l(1) + u(k,j,i) * dzw(k) * dy   &
                                      * MERGE( 1.0_wp, 0.0_wp,                  &
-                                              BTEST( wall_flags_0(k,j,i), 1 ) )
+                                              BTEST( wall_flags_static_0(k,j,i), 1 ) )
              ENDDO
           ENDDO
@@ -873,5 +876,5 @@
                 volume_flow_l(1) = volume_flow_l(1) - u(k,j,i) * dzw(k) * dy   &
                                      * MERGE( 1.0_wp, 0.0_wp,                  &
-                                              BTEST( wall_flags_0(k,j,i), 1 ) )
+                                              BTEST( wall_flags_static_0(k,j,i), 1 ) )
              ENDDO
           ENDDO
@@ -883,5 +886,5 @@
                 volume_flow_l(2) = volume_flow_l(2) + v(k,j,i) * dzw(k) * dx   &
                                      * MERGE( 1.0_wp, 0.0_wp,                  &
-                                              BTEST( wall_flags_0(k,j,i), 2 ) )
+                                              BTEST( wall_flags_static_0(k,j,i), 2 ) )
              ENDDO
           ENDDO
@@ -893,5 +896,5 @@
                 volume_flow_l(2) = volume_flow_l(2) - v(k,j,i) * dzw(k) * dx   &
                                      * MERGE( 1.0_wp, 0.0_wp,                  &
-                                              BTEST( wall_flags_0(k,j,i), 2 ) )
+                                              BTEST( wall_flags_static_0(k,j,i), 2 ) )
              ENDDO
           ENDDO
@@ -998,5 +1001,5 @@
                                                 fac_dt ) *                     &
                              MERGE( 1.0_wp, 0.0_wp,                            &
-                                    BTEST( wall_flags_0(k,j,0), 1 ) )
+                                    BTEST( wall_flags_static_0(k,j,0), 1 ) )
                 u(k,j,-1) = u(k,j,0)
              ENDDO
@@ -1010,5 +1013,5 @@
                                                  fac_dt ) *                    &
                             MERGE( 1.0_wp, 0.0_wp,                             &
-                                   BTEST( wall_flags_0(k,j,-1), 3 ) )
+                                   BTEST( wall_flags_static_0(k,j,-1), 3 ) )
              ENDDO
              w(nzt,j,-1) = w(nzt-1,j,-1)
@@ -1021,5 +1024,5 @@
                                                  fac_dt ) *                    &
                                MERGE( 1.0_wp, 0.0_wp,                          &
-                                      BTEST( wall_flags_0(k,j,-1), 2 ) )
+                                      BTEST( wall_flags_static_0(k,j,-1), 2 ) )
              ENDDO
              v_ref_l(nzb+1:nzt) = v_ref_l(nzb+1:nzt) + v(nzb+1:nzt,j,-1)
@@ -1077,5 +1080,5 @@
                                                     fac_dt ) *                 &
                              MERGE( 1.0_wp, 0.0_wp,                            &
-                                    BTEST( wall_flags_0(k,j,nxr+1), 1 ) )
+                                    BTEST( wall_flags_static_0(k,j,nxr+1), 1 ) )
              ENDDO
              u_ref_l(nzb+1:nzt) = u_ref_l(nzb+1:nzt) + u(nzb+1:nzt,j,nxr+1)
@@ -1087,5 +1090,5 @@
                                                     fac_dt ) *                 &
                              MERGE( 1.0_wp, 0.0_wp,                            &
-                                    BTEST( wall_flags_0(k,j,nxr+1), 3 ) )
+                                    BTEST( wall_flags_static_0(k,j,nxr+1), 3 ) )
              ENDDO
              w(nzt,j,nxr+1) = w(nzt-1,j,nxr+1)
@@ -1098,5 +1101,5 @@
                                                     fac_dt ) *                 &
                              MERGE( 1.0_wp, 0.0_wp,                            &
-                                    BTEST( wall_flags_0(k,j,nxr+1), 2 ) )
+                                    BTEST( wall_flags_static_0(k,j,nxr+1), 2 ) )
              ENDDO
              v_ref_l(nzb+1:nzt) = v_ref_l(nzb+1:nzt) + v(nzb+1:nzt,j,nxr+1)
@@ -1155,5 +1158,5 @@
                                                 fac_dt ) *                     &
                            MERGE( 1.0_wp, 0.0_wp,                              &
-                                  BTEST( wall_flags_0(k,0,i), 2 ) )
+                                  BTEST( wall_flags_static_0(k,0,i), 2 ) )
                 v(k,-1,i) = v(k,0,i) 
              ENDDO
@@ -1167,5 +1170,5 @@
                                                  fac_dt ) *                    &
                            MERGE( 1.0_wp, 0.0_wp,                              &
-                                  BTEST( wall_flags_0(k,-1,i), 3 ) )
+                                  BTEST( wall_flags_static_0(k,-1,i), 3 ) )
              ENDDO
              w(nzt,-1,i) = w(nzt-1,-1,i)
@@ -1178,5 +1181,5 @@
                                                  fac_dt ) *                    &
                            MERGE( 1.0_wp, 0.0_wp,                              &
-                                  BTEST( wall_flags_0(k,-1,i), 1 ) )
+                                  BTEST( wall_flags_static_0(k,-1,i), 1 ) )
              ENDDO
              u_ref_l(nzb+1:nzt) = u_ref_l(nzb+1:nzt) + u(nzb+1:nzt,-1,i)
@@ -1236,5 +1239,5 @@
                                                     fac_dt ) *                 &
                                MERGE( 1.0_wp, 0.0_wp,                          &
-                                      BTEST( wall_flags_0(k,nyn+1,i), 2 ) )
+                                      BTEST( wall_flags_static_0(k,nyn+1,i), 2 ) )
              ENDDO
              v_ref_l(nzb+1:nzt) = v_ref_l(nzb+1:nzt) + v(nzb+1:nzt,nyn+1,i)
@@ -1246,5 +1249,5 @@
                                                     fac_dt ) *                 &
                                MERGE( 1.0_wp, 0.0_wp,                          &
-                                      BTEST( wall_flags_0(k,nyn+1,i), 3 ) )
+                                      BTEST( wall_flags_static_0(k,nyn+1,i), 3 ) )
              ENDDO
              w(nzt,nyn+1,i) = w(nzt-1,nyn+1,i)
@@ -1257,5 +1260,5 @@
                                                     fac_dt ) *                 &
                                MERGE( 1.0_wp, 0.0_wp,                          &
-                                      BTEST( wall_flags_0(k,nyn+1,i), 1 ) )
+                                      BTEST( wall_flags_static_0(k,nyn+1,i), 1 ) )
 
              ENDDO
@@ -1315,5 +1318,5 @@
                                                  fac_dt ) *                    &
                            MERGE( 1.0_wp, 0.0_wp,                              &
-                                  BTEST( wall_flags_0(nzt+1,j,i), 1 ) )
+                                  BTEST( wall_flags_static_0(nzt+1,j,i), 1 ) )
              u_ref_l(nzt+1) = u_ref_l(nzt+1) + u(nzt+1,j,i)
           ENDDO
@@ -1331,5 +1334,5 @@
                                                  fac_dt ) *                    &
                            MERGE( 1.0_wp, 0.0_wp,                              &
-                                  BTEST( wall_flags_0(nzt+1,j,i), 2 ) )
+                                  BTEST( wall_flags_static_0(nzt+1,j,i), 2 ) )
              v_ref_l(nzt+1) = v_ref_l(nzt+1) + v(nzt+1,j,i)
           ENDDO
@@ -1347,5 +1350,5 @@
                                                fac_dt ) *                      &
                            MERGE( 1.0_wp, 0.0_wp,                              &
-                                  BTEST( wall_flags_0(nzt,j,i), 3 ) )
+                                  BTEST( wall_flags_static_0(nzt,j,i), 3 ) )
              w(nzt+1,j,i) = w(nzt,j,i)
           ENDDO
@@ -2130,7 +2133,7 @@
 !--    After boundary data is initialized, mask topography at the 
 !--    boundaries for the velocity components.
-       u = MERGE( u, 0.0_wp, BTEST( wall_flags_0, 1 ) )
-       v = MERGE( v, 0.0_wp, BTEST( wall_flags_0, 2 ) )
-       w = MERGE( w, 0.0_wp, BTEST( wall_flags_0, 3 ) )
+       u = MERGE( u, 0.0_wp, BTEST( wall_flags_static_0, 1 ) )
+       v = MERGE( v, 0.0_wp, BTEST( wall_flags_static_0, 2 ) )
+       w = MERGE( w, 0.0_wp, BTEST( wall_flags_static_0, 3 ) )
 !
 !--    Initial calculation of the boundary layer depth from the prescribed 
