MODULE module_alloc_space_6 CONTAINS SUBROUTINE alloc_space_field_core_6 ( grid, id, setinitval_in , tl_in , inter_domain_in , okay_to_alloc_in, num_bytes_allocated , & sd31, ed31, sd32, ed32, sd33, ed33, & sm31 , em31 , sm32 , em32 , sm33 , em33 , & sp31 , ep31 , sp32 , ep32 , sp33 , ep33 , & sp31x, ep31x, sp32x, ep32x, sp33x, ep33x, & sp31y, ep31y, sp32y, ep32y, sp33y, ep33y, & sm31x, em31x, sm32x, em32x, sm33x, em33x, & sm31y, em31y, sm32y, em32y, sm33y, em33y ) USE module_domain_type USE module_configure, ONLY : model_config_rec, grid_config_rec_type, in_use_for_config, model_to_grid_config_rec USE module_scalar_tables IMPLICIT NONE TYPE(domain) , POINTER :: grid INTEGER , INTENT(IN) :: id INTEGER , INTENT(IN) :: setinitval_in INTEGER , INTENT(IN) :: sd31, ed31, sd32, ed32, sd33, ed33 INTEGER , INTENT(IN) :: sm31, em31, sm32, em32, sm33, em33 INTEGER , INTENT(IN) :: sp31, ep31, sp32, ep32, sp33, ep33 INTEGER , INTENT(IN) :: sp31x, ep31x, sp32x, ep32x, sp33x, ep33x INTEGER , INTENT(IN) :: sp31y, ep31y, sp32y, ep32y, sp33y, ep33y INTEGER , INTENT(IN) :: sm31x, em31x, sm32x, em32x, sm33x, em33x INTEGER , INTENT(IN) :: sm31y, em31y, sm32y, em32y, sm33y, em33y INTEGER , INTENT(IN) :: tl_in LOGICAL , INTENT(IN) :: inter_domain_in, okay_to_alloc_in INTEGER(KIND=8) , INTENT(INOUT) :: num_bytes_allocated INTEGER idum1, idum2, spec_bdy_width REAL initial_data_value CHARACTER (LEN=256) message INTEGER tl LOGICAL inter_domain, okay_to_alloc INTEGER setinitval INTEGER sr_x, sr_y INTEGER ierr INTEGER :: loop TYPE ( grid_config_rec_type ) :: config_flags INTEGER :: k_start , k_end, its, ite, jts, jte INTEGER :: ids , ide , jds , jde , kds , kde , & ims , ime , jms , jme , kms , kme , & ips , ipe , jps , jpe , kps , kpe INTEGER :: sids , side , sjds , sjde , skds , skde , & sims , sime , sjms , sjme , skms , skme , & sips , sipe , sjps , sjpe , skps , skpe INTEGER :: imsx, imex, jmsx, jmex, kmsx, kmex, & ipsx, ipex, jpsx, jpex, kpsx, kpex, & imsy, imey, jmsy, jmey, kmsy, kmey, & ipsy, ipey, jpsy, jpey, kpsy, kpey data_ordering : SELECT CASE ( model_data_order ) CASE ( DATA_ORDER_XYZ ) ids = sd31 ; ide = ed31 ; jds = sd32 ; jde = ed32 ; kds = sd33 ; kde = ed33 ; ims = sm31 ; ime = em31 ; jms = sm32 ; jme = em32 ; kms = sm33 ; kme = em33 ; ips = sp31 ; ipe = ep31 ; jps = sp32 ; jpe = ep32 ; kps = sp33 ; kpe = ep33 ; imsx = sm31x ; imex = em31x ; jmsx = sm32x ; jmex = em32x ; kmsx = sm33x ; kmex = em33x ; ipsx = sp31x ; ipex = ep31x ; jpsx = sp32x ; jpex = ep32x ; kpsx = sp33x ; kpex = ep33x ; imsy = sm31y ; imey = em31y ; jmsy = sm32y ; jmey = em32y ; kmsy = sm33y ; kmey = em33y ; ipsy = sp31y ; ipey = ep31y ; jpsy = sp32y ; jpey = ep32y ; kpsy = sp33y ; kpey = ep33y ; CASE ( DATA_ORDER_YXZ ) ids = sd32 ; ide = ed32 ; jds = sd31 ; jde = ed31 ; kds = sd33 ; kde = ed33 ; ims = sm32 ; ime = em32 ; jms = sm31 ; jme = em31 ; kms = sm33 ; kme = em33 ; ips = sp32 ; ipe = ep32 ; jps = sp31 ; jpe = ep31 ; kps = sp33 ; kpe = ep33 ; imsx = sm32x ; imex = em32x ; jmsx = sm31x ; jmex = em31x ; kmsx = sm33x ; kmex = em33x ; ipsx = sp32x ; ipex = ep32x ; jpsx = sp31x ; jpex = ep31x ; kpsx = sp33x ; kpex = ep33x ; imsy = sm32y ; imey = em32y ; jmsy = sm31y ; jmey = em31y ; kmsy = sm33y ; kmey = em33y ; ipsy = sp32y ; ipey = ep32y ; jpsy = sp31y ; jpey = ep31y ; kpsy = sp33y ; kpey = ep33y ; CASE ( DATA_ORDER_ZXY ) ids = sd32 ; ide = ed32 ; jds = sd33 ; jde = ed33 ; kds = sd31 ; kde = ed31 ; ims = sm32 ; ime = em32 ; jms = sm33 ; jme = em33 ; kms = sm31 ; kme = em31 ; ips = sp32 ; ipe = ep32 ; jps = sp33 ; jpe = ep33 ; kps = sp31 ; kpe = ep31 ; imsx = sm32x ; imex = em32x ; jmsx = sm33x ; jmex = em33x ; kmsx = sm31x ; kmex = em31x ; ipsx = sp32x ; ipex = ep32x ; jpsx = sp33x ; jpex = ep33x ; kpsx = sp31x ; kpex = ep31x ; imsy = sm32y ; imey = em32y ; jmsy = sm33y ; jmey = em33y ; kmsy = sm31y ; kmey = em31y ; ipsy = sp32y ; ipey = ep32y ; jpsy = sp33y ; jpey = ep33y ; kpsy = sp31y ; kpey = ep31y ; CASE ( DATA_ORDER_ZYX ) ids = sd33 ; ide = ed33 ; jds = sd32 ; jde = ed32 ; kds = sd31 ; kde = ed31 ; ims = sm33 ; ime = em33 ; jms = sm32 ; jme = em32 ; kms = sm31 ; kme = em31 ; ips = sp33 ; ipe = ep33 ; jps = sp32 ; jpe = ep32 ; kps = sp31 ; kpe = ep31 ; imsx = sm33x ; imex = em33x ; jmsx = sm32x ; jmex = em32x ; kmsx = sm31x ; kmex = em31x ; ipsx = sp33x ; ipex = ep33x ; jpsx = sp32x ; jpex = ep32x ; kpsx = sp31x ; kpex = ep31x ; imsy = sm33y ; imey = em33y ; jmsy = sm32y ; jmey = em32y ; kmsy = sm31y ; kmey = em31y ; ipsy = sp33y ; ipey = ep33y ; jpsy = sp32y ; jpey = ep32y ; kpsy = sp31y ; kpey = ep31y ; CASE ( DATA_ORDER_XZY ) ids = sd31 ; ide = ed31 ; jds = sd33 ; jde = ed33 ; kds = sd32 ; kde = ed32 ; ims = sm31 ; ime = em31 ; jms = sm33 ; jme = em33 ; kms = sm32 ; kme = em32 ; ips = sp31 ; ipe = ep31 ; jps = sp33 ; jpe = ep33 ; kps = sp32 ; kpe = ep32 ; imsx = sm31x ; imex = em31x ; jmsx = sm33x ; jmex = em33x ; kmsx = sm32x ; kmex = em32x ; ipsx = sp31x ; ipex = ep31x ; jpsx = sp33x ; jpex = ep33x ; kpsx = sp32x ; kpex = ep32x ; imsy = sm31y ; imey = em31y ; jmsy = sm33y ; jmey = em33y ; kmsy = sm32y ; kmey = em32y ; ipsy = sp31y ; ipey = ep31y ; jpsy = sp33y ; jpey = ep33y ; kpsy = sp32y ; kpey = ep32y ; CASE ( DATA_ORDER_YZX ) ids = sd33 ; ide = ed33 ; jds = sd31 ; jde = ed31 ; kds = sd32 ; kde = ed32 ; ims = sm33 ; ime = em33 ; jms = sm31 ; jme = em31 ; kms = sm32 ; kme = em32 ; ips = sp33 ; ipe = ep33 ; jps = sp31 ; jpe = ep31 ; kps = sp32 ; kpe = ep32 ; imsx = sm33x ; imex = em33x ; jmsx = sm31x ; jmex = em31x ; kmsx = sm32x ; kmex = em32x ; ipsx = sp33x ; ipex = ep33x ; jpsx = sp31x ; jpex = ep31x ; kpsx = sp32x ; kpex = ep32x ; imsy = sm33y ; imey = em33y ; jmsy = sm31y ; jmey = em31y ; kmsy = sm32y ; kmey = em32y ; ipsy = sp33y ; ipey = ep33y ; jpsy = sp31y ; jpey = ep31y ; kpsy = sp32y ; kpey = ep32y ; END SELECT data_ordering CALL model_to_grid_config_rec ( id , model_config_rec , config_flags ) CALL nl_get_sr_x( id , sr_x ) CALL nl_get_sr_y( id , sr_y ) tl = tl_in inter_domain = inter_domain_in okay_to_alloc = okay_to_alloc_in CALL get_initial_data_value ( initial_data_value ) setinitval = setinitval_in CALL nl_get_spec_bdy_width( 1, spec_bdy_width ) IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw8').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw8(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",165,& 'frame/module_domain.f: Failed to allocate grid%extaerlw8(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw8=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw8' grid%tail_statevars%DataName = 'LWEXTAER8' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw8 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw8(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",215,& 'frame/module_domain.f: Failed to allocate grid%extaerlw8(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw9').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw9(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",224,& 'frame/module_domain.f: Failed to allocate grid%extaerlw9(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw9=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw9' grid%tail_statevars%DataName = 'LWEXTAER9' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw9 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw9(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",274,& 'frame/module_domain.f: Failed to allocate grid%extaerlw9(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw10').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw10(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",283,& 'frame/module_domain.f: Failed to allocate grid%extaerlw10(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw10=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw10' grid%tail_statevars%DataName = 'LWEXTAER10' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw10 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw10(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",333,& 'frame/module_domain.f: Failed to allocate grid%extaerlw10(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw11').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw11(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",342,& 'frame/module_domain.f: Failed to allocate grid%extaerlw11(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw11=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw11' grid%tail_statevars%DataName = 'LWEXTAER11' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw11 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw11(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",392,& 'frame/module_domain.f: Failed to allocate grid%extaerlw11(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw12').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw12(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",401,& 'frame/module_domain.f: Failed to allocate grid%extaerlw12(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw12=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw12' grid%tail_statevars%DataName = 'LWEXTAER12' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw12 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw12(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",451,& 'frame/module_domain.f: Failed to allocate grid%extaerlw12(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw13').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw13(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",460,& 'frame/module_domain.f: Failed to allocate grid%extaerlw13(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw13=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw13' grid%tail_statevars%DataName = 'LWEXTAER13' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw13 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw13(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",510,& 'frame/module_domain.f: Failed to allocate grid%extaerlw13(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw14').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw14(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",519,& 'frame/module_domain.f: Failed to allocate grid%extaerlw14(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw14=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw14' grid%tail_statevars%DataName = 'LWEXTAER14' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw14 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw14(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",569,& 'frame/module_domain.f: Failed to allocate grid%extaerlw14(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw15').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw15(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",578,& 'frame/module_domain.f: Failed to allocate grid%extaerlw15(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw15=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw15' grid%tail_statevars%DataName = 'LWEXTAER15' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw15 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw15(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",628,& 'frame/module_domain.f: Failed to allocate grid%extaerlw15(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaerlw16').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaerlw16(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",637,& 'frame/module_domain.f: Failed to allocate grid%extaerlw16(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaerlw16=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaerlw16' grid%tail_statevars%DataName = 'LWEXTAER16' grid%tail_statevars%Description = 'layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaerlw16 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaerlw16(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",687,& 'frame/module_domain.f: Failed to allocate grid%extaerlw16(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",696,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw1' grid%tail_statevars%DataName = 'LWTAUAER1' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",746,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",755,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw2' grid%tail_statevars%DataName = 'LWTAUAER2' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",805,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",814,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw3' grid%tail_statevars%DataName = 'LWTAUAER3' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",864,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw4(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",873,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw4(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw4' grid%tail_statevars%DataName = 'LWTAUAER4' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw4(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",923,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw4(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw5').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw5(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",932,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw5(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw5=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw5' grid%tail_statevars%DataName = 'LWTAUAER5' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw5 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw5(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",982,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw5(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw6').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw6(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",991,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw6(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw6=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw6' grid%tail_statevars%DataName = 'LWTAUAER6' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw6 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw6(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1041,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw6(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw7').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw7(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1050,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw7(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw7=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw7' grid%tail_statevars%DataName = 'LWTAUAER7' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw7 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw7(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1100,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw7(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw8').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw8(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1109,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw8(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw8=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw8' grid%tail_statevars%DataName = 'LWTAUAER8' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw8 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw8(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1159,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw8(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw9').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw9(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1168,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw9(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw9=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw9' grid%tail_statevars%DataName = 'LWTAUAER9' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw9 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw9(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1218,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw9(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw10').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw10(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1227,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw10(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw10=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw10' grid%tail_statevars%DataName = 'LWTAUAER10' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw10 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw10(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1277,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw10(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw11').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw11(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1286,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw11(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw11=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw11' grid%tail_statevars%DataName = 'LWTAUAER11' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw11 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw11(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1336,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw11(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw12').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw12(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1345,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw12(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw12=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw12' grid%tail_statevars%DataName = 'LWTAUAER12' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw12 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw12(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1395,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw12(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw13').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw13(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1404,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw13(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw13=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw13' grid%tail_statevars%DataName = 'LWTAUAER13' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw13 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw13(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1454,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw13(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw14').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw14(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1463,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw14(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw14=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw14' grid%tail_statevars%DataName = 'LWTAUAER14' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw14 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw14(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1513,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw14(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw15').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw15(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1522,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw15(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw15=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw15' grid%tail_statevars%DataName = 'LWTAUAER15' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw15 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw15(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1572,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw15(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaerlw16').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaerlw16(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1581,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw16(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaerlw16=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaerlw16' grid%tail_statevars%DataName = 'LWTAUAER16' grid%tail_statevars%Description = 'layer optical thickness' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaerlw16 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaerlw16(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1631,& 'frame/module_domain.f: Failed to allocate grid%tauaerlw16(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaer1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaer1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1640,& 'frame/module_domain.f: Failed to allocate grid%extaer1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaer1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaer1' grid%tail_statevars%DataName = 'EXTAER1' grid%tail_statevars%Description = 'bin 1 layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaer1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaer1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1690,& 'frame/module_domain.f: Failed to allocate grid%extaer1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaer2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaer2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1699,& 'frame/module_domain.f: Failed to allocate grid%extaer2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaer2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaer2' grid%tail_statevars%DataName = 'EXTAER2' grid%tail_statevars%Description = 'bin 2 layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaer2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaer2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1749,& 'frame/module_domain.f: Failed to allocate grid%extaer2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaer3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaer3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1758,& 'frame/module_domain.f: Failed to allocate grid%extaer3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaer3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaer3' grid%tail_statevars%DataName = 'EXTAER3' grid%tail_statevars%Description = 'bin 3 layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaer3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaer3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1808,& 'frame/module_domain.f: Failed to allocate grid%extaer3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'extaer4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%extaer4(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1817,& 'frame/module_domain.f: Failed to allocate grid%extaer4(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%extaer4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'extaer4' grid%tail_statevars%DataName = 'EXTAER4' grid%tail_statevars%Description = 'bin 4 layer extinction coef' grid%tail_statevars%Units = '1/km' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%extaer4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%extaer4(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1867,& 'frame/module_domain.f: Failed to allocate grid%extaer4(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaer1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaer1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1876,& 'frame/module_domain.f: Failed to allocate grid%tauaer1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaer1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaer1' grid%tail_statevars%DataName = 'TAUAER1' grid%tail_statevars%Description = 'bin 1 layer optical thickness' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaer1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaer1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1926,& 'frame/module_domain.f: Failed to allocate grid%tauaer1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaer2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaer2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1935,& 'frame/module_domain.f: Failed to allocate grid%tauaer2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaer2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaer2' grid%tail_statevars%DataName = 'TAUAER2' grid%tail_statevars%Description = 'bin 2 layer optical thickness' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaer2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaer2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1985,& 'frame/module_domain.f: Failed to allocate grid%tauaer2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaer3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaer3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1994,& 'frame/module_domain.f: Failed to allocate grid%tauaer3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaer3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaer3' grid%tail_statevars%DataName = 'TAUAER3' grid%tail_statevars%Description = 'bin 3 layer optical thickness' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaer3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaer3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2044,& 'frame/module_domain.f: Failed to allocate grid%tauaer3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauaer4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauaer4(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2053,& 'frame/module_domain.f: Failed to allocate grid%tauaer4(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauaer4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauaer4' grid%tail_statevars%DataName = 'TAUAER4' grid%tail_statevars%Description = 'bin 4 layer optical thickness' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tauaer4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tauaer4(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2103,& 'frame/module_domain.f: Failed to allocate grid%tauaer4(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'gaer1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%gaer1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2112,& 'frame/module_domain.f: Failed to allocate grid%gaer1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%gaer1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'gaer1' grid%tail_statevars%DataName = 'GAER1' grid%tail_statevars%Description = 'bin 1 layer assymetry parameter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%gaer1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%gaer1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2162,& 'frame/module_domain.f: Failed to allocate grid%gaer1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'gaer2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%gaer2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2171,& 'frame/module_domain.f: Failed to allocate grid%gaer2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%gaer2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'gaer2' grid%tail_statevars%DataName = 'GAER2' grid%tail_statevars%Description = 'bin 2 layer assymetry parameter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%gaer2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%gaer2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2221,& 'frame/module_domain.f: Failed to allocate grid%gaer2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'gaer3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%gaer3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2230,& 'frame/module_domain.f: Failed to allocate grid%gaer3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%gaer3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'gaer3' grid%tail_statevars%DataName = 'GAER3' grid%tail_statevars%Description = 'bin 3 layer assymetry parameter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%gaer3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%gaer3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2280,& 'frame/module_domain.f: Failed to allocate grid%gaer3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'gaer4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%gaer4(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2289,& 'frame/module_domain.f: Failed to allocate grid%gaer4(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%gaer4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'gaer4' grid%tail_statevars%DataName = 'GAER4' grid%tail_statevars%Description = 'bin 4 layer assymetry parameter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%gaer4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%gaer4(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2339,& 'frame/module_domain.f: Failed to allocate grid%gaer4(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'waer1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%waer1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2348,& 'frame/module_domain.f: Failed to allocate grid%waer1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%waer1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'waer1' grid%tail_statevars%DataName = 'WAER1' grid%tail_statevars%Description = 'bin 1 layer single-scattering albedo' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%waer1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%waer1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2398,& 'frame/module_domain.f: Failed to allocate grid%waer1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'waer2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%waer2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2407,& 'frame/module_domain.f: Failed to allocate grid%waer2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%waer2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'waer2' grid%tail_statevars%DataName = 'WAER2' grid%tail_statevars%Description = 'bin 2 layer single-scattering albedo' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%waer2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%waer2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2457,& 'frame/module_domain.f: Failed to allocate grid%waer2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'waer3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%waer3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2466,& 'frame/module_domain.f: Failed to allocate grid%waer3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%waer3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'waer3' grid%tail_statevars%DataName = 'WAER3' grid%tail_statevars%Description = 'bin 3 layer single-scattering albedo' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%waer3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%waer3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2516,& 'frame/module_domain.f: Failed to allocate grid%waer3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'waer4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%waer4(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2525,& 'frame/module_domain.f: Failed to allocate grid%waer4(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%waer4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'waer4' grid%tail_statevars%DataName = 'WAER4' grid%tail_statevars%Description = 'bin 4 layer single-scattering albedo' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%waer4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%waer4(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2575,& 'frame/module_domain.f: Failed to allocate grid%waer4(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bscoef1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bscoef1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2584,& 'frame/module_domain.f: Failed to allocate grid%bscoef1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bscoef1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bscoef1' grid%tail_statevars%DataName = 'BSCOEF1' grid%tail_statevars%Description = 'bin 1 layer backscatter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bscoef1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bscoef1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2634,& 'frame/module_domain.f: Failed to allocate grid%bscoef1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bscoef2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bscoef2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2643,& 'frame/module_domain.f: Failed to allocate grid%bscoef2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bscoef2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bscoef2' grid%tail_statevars%DataName = 'BSCOEF2' grid%tail_statevars%Description = 'bin 2 layer backscatter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bscoef2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bscoef2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2693,& 'frame/module_domain.f: Failed to allocate grid%bscoef2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bscoef3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bscoef3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2702,& 'frame/module_domain.f: Failed to allocate grid%bscoef3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bscoef3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bscoef3' grid%tail_statevars%DataName = 'BSCOEF3' grid%tail_statevars%Description = 'bin 3 layer backscatter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bscoef3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bscoef3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2752,& 'frame/module_domain.f: Failed to allocate grid%bscoef3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bscoef4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bscoef4(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2761,& 'frame/module_domain.f: Failed to allocate grid%bscoef4(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bscoef4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bscoef4' grid%tail_statevars%DataName = 'BSCOEF4' grid%tail_statevars%Description = 'bin 4 layer backscatter' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bscoef4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bscoef4(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2811,& 'frame/module_domain.f: Failed to allocate grid%bscoef4(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'l2aer').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))*(((4)-(1)+1))) * 4 ALLOCATE(grid%l2aer(sm31:em31,sm32:em32,sm33:em33,1:4),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2820,& 'frame/module_domain.f: Failed to allocate grid%l2aer(sm31:em31,sm32:em32,sm33:em33,1:4). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%l2aer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'l2aer' grid%tail_statevars%DataName = 'L2AER' grid%tail_statevars%Description = 'legendre polynomial 2' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%l2aer grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%l2aer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2870,& 'frame/module_domain.f: Failed to allocate grid%l2aer(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'l3aer').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))*(((4)-(1)+1))) * 4 ALLOCATE(grid%l3aer(sm31:em31,sm32:em32,sm33:em33,1:4),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2879,& 'frame/module_domain.f: Failed to allocate grid%l3aer(sm31:em31,sm32:em32,sm33:em33,1:4). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%l3aer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'l3aer' grid%tail_statevars%DataName = 'L3AER' grid%tail_statevars%Description = 'legendre polynomial 3' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%l3aer grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%l3aer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2929,& 'frame/module_domain.f: Failed to allocate grid%l3aer(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'l4aer').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))*(((4)-(1)+1))) * 4 ALLOCATE(grid%l4aer(sm31:em31,sm32:em32,sm33:em33,1:4),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2938,& 'frame/module_domain.f: Failed to allocate grid%l4aer(sm31:em31,sm32:em32,sm33:em33,1:4). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%l4aer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'l4aer' grid%tail_statevars%DataName = 'L4AER' grid%tail_statevars%Description = 'legendre polynomial 4' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%l4aer grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%l4aer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2988,& 'frame/module_domain.f: Failed to allocate grid%l4aer(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'l5aer').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))*(((4)-(1)+1))) * 4 ALLOCATE(grid%l5aer(sm31:em31,sm32:em32,sm33:em33,1:4),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2997,& 'frame/module_domain.f: Failed to allocate grid%l5aer(sm31:em31,sm32:em32,sm33:em33,1:4). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%l5aer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'l5aer' grid%tail_statevars%DataName = 'L5AER' grid%tail_statevars%Description = 'legendre polynomial 5' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%l5aer grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%l5aer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3047,& 'frame/module_domain.f: Failed to allocate grid%l5aer(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'l6aer').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))*(((4)-(1)+1))) * 4 ALLOCATE(grid%l6aer(sm31:em31,sm32:em32,sm33:em33,1:4),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3056,& 'frame/module_domain.f: Failed to allocate grid%l6aer(sm31:em31,sm32:em32,sm33:em33,1:4). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%l6aer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'l6aer' grid%tail_statevars%DataName = 'L6AER' grid%tail_statevars%Description = 'legendre polynomial 6' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%l6aer grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%l6aer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3106,& 'frame/module_domain.f: Failed to allocate grid%l6aer(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'l7aer').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))*(((4)-(1)+1))) * 4 ALLOCATE(grid%l7aer(sm31:em31,sm32:em32,sm33:em33,1:4),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3115,& 'frame/module_domain.f: Failed to allocate grid%l7aer(sm31:em31,sm32:em32,sm33:em33,1:4). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%l7aer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'l7aer' grid%tail_statevars%DataName = 'L7AER' grid%tail_statevars%Description = 'legendre polynomial 7' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%l7aer grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%l7aer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3165,& 'frame/module_domain.f: Failed to allocate grid%l7aer(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'chem_cupflag').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%chem_cupflag(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3174,& 'frame/module_domain.f: Failed to allocate grid%chem_cupflag(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_cupflag=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'chem_cupflag' grid%tail_statevars%DataName = 'CHEM_CUPFLAG' grid%tail_statevars%Description = 'flag for cup chemistry - positive when there is cup conv. cloud chemistry at ikj' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_3d => grid%chem_cupflag grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%chem_cupflag(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3224,& 'frame/module_domain.f: Failed to allocate grid%chem_cupflag(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'co_a_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%co_a_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3233,& 'frame/module_domain.f: Failed to allocate grid%co_a_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%co_a_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'co_a_ic_cup' grid%tail_statevars%DataName = 'CO_A_IC_CUP' grid%tail_statevars%Description = 'interstitial CO within convective cloud' grid%tail_statevars%Units = 'ppmv' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%co_a_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%co_a_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3283,& 'frame/module_domain.f: Failed to allocate grid%co_a_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hno3_a_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hno3_a_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3292,& 'frame/module_domain.f: Failed to allocate grid%hno3_a_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hno3_a_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hno3_a_ic_cup' grid%tail_statevars%DataName = 'HNO3_A_IC_CUP' grid%tail_statevars%Description = 'interstitial HNO3 within convective cloud' grid%tail_statevars%Units = 'ppmv' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%hno3_a_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%hno3_a_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3342,& 'frame/module_domain.f: Failed to allocate grid%hno3_a_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'so4_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%so4_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3351,& 'frame/module_domain.f: Failed to allocate grid%so4_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%so4_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'so4_a_1to4_ic_cup' grid%tail_statevars%DataName = 'SO4_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%so4_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%so4_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3401,& 'frame/module_domain.f: Failed to allocate grid%so4_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'so4_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%so4_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3410,& 'frame/module_domain.f: Failed to allocate grid%so4_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%so4_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'so4_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'SO4_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%so4_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%so4_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3460,& 'frame/module_domain.f: Failed to allocate grid%so4_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nh4_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%nh4_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3469,& 'frame/module_domain.f: Failed to allocate grid%nh4_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nh4_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nh4_a_1to4_ic_cup' grid%tail_statevars%DataName = 'NH4_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial ammonium (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%nh4_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nh4_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3519,& 'frame/module_domain.f: Failed to allocate grid%nh4_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nh4_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%nh4_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3528,& 'frame/module_domain.f: Failed to allocate grid%nh4_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nh4_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nh4_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'NH4_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne ammonium (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%nh4_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nh4_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3578,& 'frame/module_domain.f: Failed to allocate grid%nh4_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'no3_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%no3_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3587,& 'frame/module_domain.f: Failed to allocate grid%no3_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%no3_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'no3_a_1to4_ic_cup' grid%tail_statevars%DataName = 'NO3_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial nitrate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%no3_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%no3_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3637,& 'frame/module_domain.f: Failed to allocate grid%no3_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'no3_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%no3_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3646,& 'frame/module_domain.f: Failed to allocate grid%no3_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%no3_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'no3_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'NO3_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne nitrate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%no3_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%no3_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3696,& 'frame/module_domain.f: Failed to allocate grid%no3_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oa_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oa_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3705,& 'frame/module_domain.f: Failed to allocate grid%oa_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oa_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oa_a_1to4_ic_cup' grid%tail_statevars%DataName = 'OA_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial organic aerosol (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oa_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oa_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3755,& 'frame/module_domain.f: Failed to allocate grid%oa_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oa_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oa_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3764,& 'frame/module_domain.f: Failed to allocate grid%oa_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oa_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oa_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'OA_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne organic aerosol (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oa_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oa_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3814,& 'frame/module_domain.f: Failed to allocate grid%oa_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oin_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oin_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3823,& 'frame/module_domain.f: Failed to allocate grid%oin_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oin_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oin_a_1to4_ic_cup' grid%tail_statevars%DataName = 'OIN_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oin_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oin_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3873,& 'frame/module_domain.f: Failed to allocate grid%oin_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oin_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oin_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3882,& 'frame/module_domain.f: Failed to allocate grid%oin_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oin_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oin_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'OIN_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oin_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oin_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3932,& 'frame/module_domain.f: Failed to allocate grid%oin_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bc_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bc_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3941,& 'frame/module_domain.f: Failed to allocate grid%bc_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bc_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bc_a_1to4_ic_cup' grid%tail_statevars%DataName = 'BC_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bc_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bc_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3991,& 'frame/module_domain.f: Failed to allocate grid%bc_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bc_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bc_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4000,& 'frame/module_domain.f: Failed to allocate grid%bc_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bc_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bc_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'BC_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bc_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bc_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4050,& 'frame/module_domain.f: Failed to allocate grid%bc_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'na_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%na_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4059,& 'frame/module_domain.f: Failed to allocate grid%na_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%na_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'na_a_1to4_ic_cup' grid%tail_statevars%DataName = 'NA_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%na_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%na_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4109,& 'frame/module_domain.f: Failed to allocate grid%na_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'na_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%na_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4118,& 'frame/module_domain.f: Failed to allocate grid%na_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%na_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'na_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'NA_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%na_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%na_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4168,& 'frame/module_domain.f: Failed to allocate grid%na_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cl_a_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cl_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4177,& 'frame/module_domain.f: Failed to allocate grid%cl_a_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cl_a_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cl_a_1to4_ic_cup' grid%tail_statevars%DataName = 'CL_A_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cl_a_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cl_a_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4227,& 'frame/module_domain.f: Failed to allocate grid%cl_a_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cl_cw_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cl_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4236,& 'frame/module_domain.f: Failed to allocate grid%cl_cw_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cl_cw_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cl_cw_1to4_ic_cup' grid%tail_statevars%DataName = 'CL_CW_1TO4_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cl_cw_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cl_cw_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4286,& 'frame/module_domain.f: Failed to allocate grid%cl_cw_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'so4_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%so4_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4295,& 'frame/module_domain.f: Failed to allocate grid%so4_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%so4_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'so4_a_5to6_ic_cup' grid%tail_statevars%DataName = 'SO4_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry>625 nm and Ddry<2500 ) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%so4_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%so4_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4345,& 'frame/module_domain.f: Failed to allocate grid%so4_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'so4_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%so4_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4354,& 'frame/module_domain.f: Failed to allocate grid%so4_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%so4_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'so4_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'SO4_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%so4_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%so4_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4404,& 'frame/module_domain.f: Failed to allocate grid%so4_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nh4_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%nh4_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4413,& 'frame/module_domain.f: Failed to allocate grid%nh4_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nh4_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nh4_a_5to6_ic_cup' grid%tail_statevars%DataName = 'NH4_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial ammonium (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%nh4_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nh4_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4463,& 'frame/module_domain.f: Failed to allocate grid%nh4_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nh4_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%nh4_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4472,& 'frame/module_domain.f: Failed to allocate grid%nh4_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nh4_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nh4_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'NH4_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne ammonium (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%nh4_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nh4_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4522,& 'frame/module_domain.f: Failed to allocate grid%nh4_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'no3_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%no3_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4531,& 'frame/module_domain.f: Failed to allocate grid%no3_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%no3_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'no3_a_5to6_ic_cup' grid%tail_statevars%DataName = 'NO3_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial nitrate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%no3_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%no3_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4581,& 'frame/module_domain.f: Failed to allocate grid%no3_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'no3_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%no3_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4590,& 'frame/module_domain.f: Failed to allocate grid%no3_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%no3_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'no3_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'NO3_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne nitrate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%no3_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%no3_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4640,& 'frame/module_domain.f: Failed to allocate grid%no3_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oa_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oa_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4649,& 'frame/module_domain.f: Failed to allocate grid%oa_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oa_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oa_a_5to6_ic_cup' grid%tail_statevars%DataName = 'OA_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial organic aerosol (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oa_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oa_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4699,& 'frame/module_domain.f: Failed to allocate grid%oa_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oa_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oa_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4708,& 'frame/module_domain.f: Failed to allocate grid%oa_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oa_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oa_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'OA_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne organic aerosol (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oa_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oa_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4758,& 'frame/module_domain.f: Failed to allocate grid%oa_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oin_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oin_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4767,& 'frame/module_domain.f: Failed to allocate grid%oin_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oin_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oin_a_5to6_ic_cup' grid%tail_statevars%DataName = 'OIN_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oin_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oin_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4817,& 'frame/module_domain.f: Failed to allocate grid%oin_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oin_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oin_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4826,& 'frame/module_domain.f: Failed to allocate grid%oin_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oin_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oin_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'OIN_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oin_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oin_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4876,& 'frame/module_domain.f: Failed to allocate grid%oin_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bc_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bc_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4885,& 'frame/module_domain.f: Failed to allocate grid%bc_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bc_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bc_a_5to6_ic_cup' grid%tail_statevars%DataName = 'BC_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bc_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bc_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4935,& 'frame/module_domain.f: Failed to allocate grid%bc_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bc_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bc_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4944,& 'frame/module_domain.f: Failed to allocate grid%bc_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bc_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bc_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'BC_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bc_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bc_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4994,& 'frame/module_domain.f: Failed to allocate grid%bc_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'na_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%na_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5003,& 'frame/module_domain.f: Failed to allocate grid%na_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%na_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'na_a_5to6_ic_cup' grid%tail_statevars%DataName = 'NA_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%na_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%na_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5053,& 'frame/module_domain.f: Failed to allocate grid%na_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'na_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%na_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5062,& 'frame/module_domain.f: Failed to allocate grid%na_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%na_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'na_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'NA_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%na_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%na_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5112,& 'frame/module_domain.f: Failed to allocate grid%na_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cl_a_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cl_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5121,& 'frame/module_domain.f: Failed to allocate grid%cl_a_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cl_a_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cl_a_5to6_ic_cup' grid%tail_statevars%DataName = 'CL_A_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cl_a_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cl_a_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5171,& 'frame/module_domain.f: Failed to allocate grid%cl_a_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cl_cw_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cl_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5180,& 'frame/module_domain.f: Failed to allocate grid%cl_cw_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cl_cw_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cl_cw_5to6_ic_cup' grid%tail_statevars%DataName = 'CL_CW_5TO6_IC_CUP' grid%tail_statevars%Description = 'cloud-borne sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cl_cw_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cl_cw_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5230,& 'frame/module_domain.f: Failed to allocate grid%cl_cw_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'water_1to4_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%water_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5239,& 'frame/module_domain.f: Failed to allocate grid%water_1to4_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%water_1to4_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'water_1to4_ic_cup' grid%tail_statevars%DataName = 'WATER_1TO4_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry<625 nm) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%water_1to4_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%water_1to4_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5289,& 'frame/module_domain.f: Failed to allocate grid%water_1to4_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'water_5to6_ic_cup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%water_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5298,& 'frame/module_domain.f: Failed to allocate grid%water_5to6_ic_cup(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%water_5to6_ic_cup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'water_5to6_ic_cup' grid%tail_statevars%DataName = 'WATER_5TO6_IC_CUP' grid%tail_statevars%Description = 'interstitial sulfate (Ddry>625 nm and Ddry<2500) within convective cloud' grid%tail_statevars%Units = 'ug/kg-dryair' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%water_5to6_ic_cup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%water_5to6_ic_cup(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5348,& 'frame/module_domain.f: Failed to allocate grid%water_5to6_ic_cup(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'h2oaj').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%h2oaj(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5357,& 'frame/module_domain.f: Failed to allocate grid%h2oaj(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%h2oaj=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'h2oaj' grid%tail_statevars%DataName = 'H2OAJ' grid%tail_statevars%Description = 'Aerosol water conc. Acc.mode' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%h2oaj grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%h2oaj(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5407,& 'frame/module_domain.f: Failed to allocate grid%h2oaj(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'h2oai').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%h2oai(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5416,& 'frame/module_domain.f: Failed to allocate grid%h2oai(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%h2oai=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'h2oai' grid%tail_statevars%DataName = 'H2OAI' grid%tail_statevars%Description = 'Aerosol water conc. Aitken mode' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%h2oai grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%h2oai(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5466,& 'frame/module_domain.f: Failed to allocate grid%h2oai(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nu3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%nu3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5475,& 'frame/module_domain.f: Failed to allocate grid%nu3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nu3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nu3' grid%tail_statevars%DataName = 'NU3' grid%tail_statevars%Description = '3rd moment Aitken mode' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%nu3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nu3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5525,& 'frame/module_domain.f: Failed to allocate grid%nu3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ac3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ac3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5534,& 'frame/module_domain.f: Failed to allocate grid%ac3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ac3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ac3' grid%tail_statevars%DataName = 'AC3' grid%tail_statevars%Description = '3rd moment Acc. mode' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ac3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ac3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5584,& 'frame/module_domain.f: Failed to allocate grid%ac3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cor3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cor3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5593,& 'frame/module_domain.f: Failed to allocate grid%cor3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cor3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cor3' grid%tail_statevars%DataName = 'COR3' grid%tail_statevars%Description = '3rd moment coarse mode' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cor3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cor3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5643,& 'frame/module_domain.f: Failed to allocate grid%cor3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'asulf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%asulf(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5652,& 'frame/module_domain.f: Failed to allocate grid%asulf(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%asulf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'asulf' grid%tail_statevars%DataName = 'ASULF' grid%tail_statevars%Description = 'sulfuric acid vapor deposition' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%asulf grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%asulf(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5702,& 'frame/module_domain.f: Failed to allocate grid%asulf(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ahno3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ahno3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5711,& 'frame/module_domain.f: Failed to allocate grid%ahno3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ahno3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ahno3' grid%tail_statevars%DataName = 'AHNO3' grid%tail_statevars%Description = 'nitric acid vapor deposition' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ahno3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ahno3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5761,& 'frame/module_domain.f: Failed to allocate grid%ahno3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'anh3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%anh3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5770,& 'frame/module_domain.f: Failed to allocate grid%anh3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%anh3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'anh3' grid%tail_statevars%DataName = 'ANH3' grid%tail_statevars%Description = 'amonia gas concentration' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%anh3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%anh3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5820,& 'frame/module_domain.f: Failed to allocate grid%anh3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvaro1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvaro1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5829,& 'frame/module_domain.f: Failed to allocate grid%cvaro1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvaro1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvaro1' grid%tail_statevars%DataName = 'CVARO1' grid%tail_statevars%Description = 'cond.vapor from aromatics' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvaro1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvaro1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5879,& 'frame/module_domain.f: Failed to allocate grid%cvaro1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvaro2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvaro2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5888,& 'frame/module_domain.f: Failed to allocate grid%cvaro2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvaro2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvaro2' grid%tail_statevars%DataName = 'CVARO2' grid%tail_statevars%Description = 'cond.vapor from aromatics' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvaro2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvaro2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5938,& 'frame/module_domain.f: Failed to allocate grid%cvaro2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvalk1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvalk1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5947,& 'frame/module_domain.f: Failed to allocate grid%cvalk1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvalk1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvalk1' grid%tail_statevars%DataName = 'CVALK1' grid%tail_statevars%Description = 'cond.vapor from alkanes' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvalk1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvalk1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5997,& 'frame/module_domain.f: Failed to allocate grid%cvalk1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvole1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvole1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6006,& 'frame/module_domain.f: Failed to allocate grid%cvole1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvole1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvole1' grid%tail_statevars%DataName = 'CVOLE1' grid%tail_statevars%Description = 'cond.vapor from olefines' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvole1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvole1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6056,& 'frame/module_domain.f: Failed to allocate grid%cvole1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvapi1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvapi1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6065,& 'frame/module_domain.f: Failed to allocate grid%cvapi1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvapi1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvapi1' grid%tail_statevars%DataName = 'CVAPI1' grid%tail_statevars%Description = 'cond.vapor from biogenics' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvapi1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvapi1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6115,& 'frame/module_domain.f: Failed to allocate grid%cvapi1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvapi2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvapi2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6124,& 'frame/module_domain.f: Failed to allocate grid%cvapi2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvapi2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvapi2' grid%tail_statevars%DataName = 'CVAPI2' grid%tail_statevars%Description = 'cond.vapor from biogenics' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvapi2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvapi2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6174,& 'frame/module_domain.f: Failed to allocate grid%cvapi2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvlim1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvlim1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6183,& 'frame/module_domain.f: Failed to allocate grid%cvlim1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvlim1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvlim1' grid%tail_statevars%DataName = 'CVLIM1' grid%tail_statevars%Description = 'cond.vapor from biogenics' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvlim1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvlim1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6233,& 'frame/module_domain.f: Failed to allocate grid%cvlim1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cvlim2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cvlim2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6242,& 'frame/module_domain.f: Failed to allocate grid%cvlim2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cvlim2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cvlim2' grid%tail_statevars%DataName = 'CVLIM2' grid%tail_statevars%Description = 'cond.vapor from biogenics' grid%tail_statevars%Units = '?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cvlim2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cvlim2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6292,& 'frame/module_domain.f: Failed to allocate grid%cvlim2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'addt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%addt(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6301,& 'frame/module_domain.f: Failed to allocate grid%addt(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%addt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'addt' grid%tail_statevars%DataName = 'ADDT' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%addt grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%addt(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6351,& 'frame/module_domain.f: Failed to allocate grid%addt(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'addx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%addx(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6360,& 'frame/module_domain.f: Failed to allocate grid%addx(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%addx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'addx' grid%tail_statevars%DataName = 'ADDX' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%addx grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%addx(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6410,& 'frame/module_domain.f: Failed to allocate grid%addx(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'addc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%addc(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6419,& 'frame/module_domain.f: Failed to allocate grid%addc(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%addc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'addc' grid%tail_statevars%DataName = 'ADDC' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%addc grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%addc(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6469,& 'frame/module_domain.f: Failed to allocate grid%addc(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'etep').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%etep(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6478,& 'frame/module_domain.f: Failed to allocate grid%etep(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%etep=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'etep' grid%tail_statevars%DataName = 'ETEP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%etep grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%etep(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6528,& 'frame/module_domain.f: Failed to allocate grid%etep(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oltp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oltp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6537,& 'frame/module_domain.f: Failed to allocate grid%oltp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oltp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oltp' grid%tail_statevars%DataName = 'OLTP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oltp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oltp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6587,& 'frame/module_domain.f: Failed to allocate grid%oltp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'olip').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%olip(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6596,& 'frame/module_domain.f: Failed to allocate grid%olip(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%olip=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'olip' grid%tail_statevars%DataName = 'OLIP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%olip grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%olip(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6646,& 'frame/module_domain.f: Failed to allocate grid%olip(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cslp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cslp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6655,& 'frame/module_domain.f: Failed to allocate grid%cslp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cslp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cslp' grid%tail_statevars%DataName = 'CSLP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cslp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cslp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6705,& 'frame/module_domain.f: Failed to allocate grid%cslp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'limp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%limp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6714,& 'frame/module_domain.f: Failed to allocate grid%limp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%limp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'limp' grid%tail_statevars%DataName = 'LIMP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%limp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%limp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6764,& 'frame/module_domain.f: Failed to allocate grid%limp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hc5p').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hc5p(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6773,& 'frame/module_domain.f: Failed to allocate grid%hc5p(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hc5p=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hc5p' grid%tail_statevars%DataName = 'HC5P' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%hc5p grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%hc5p(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6823,& 'frame/module_domain.f: Failed to allocate grid%hc5p(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hc8p').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hc8p(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6832,& 'frame/module_domain.f: Failed to allocate grid%hc8p(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hc8p=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hc8p' grid%tail_statevars%DataName = 'HC8P' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%hc8p grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%hc8p(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6882,& 'frame/module_domain.f: Failed to allocate grid%hc8p(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tolp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tolp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6891,& 'frame/module_domain.f: Failed to allocate grid%tolp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tolp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tolp' grid%tail_statevars%DataName = 'TOLP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tolp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tolp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6941,& 'frame/module_domain.f: Failed to allocate grid%tolp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xylp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xylp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6950,& 'frame/module_domain.f: Failed to allocate grid%xylp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xylp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xylp' grid%tail_statevars%DataName = 'XYLP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%xylp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%xylp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7000,& 'frame/module_domain.f: Failed to allocate grid%xylp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'apip').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%apip(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7009,& 'frame/module_domain.f: Failed to allocate grid%apip(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%apip=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'apip' grid%tail_statevars%DataName = 'APIP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%apip grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%apip(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7059,& 'frame/module_domain.f: Failed to allocate grid%apip(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'isop').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%isop(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7068,& 'frame/module_domain.f: Failed to allocate grid%isop(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%isop=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'isop' grid%tail_statevars%DataName = 'ISOP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%isop grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%isop(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7118,& 'frame/module_domain.f: Failed to allocate grid%isop(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hc3p').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hc3p(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7127,& 'frame/module_domain.f: Failed to allocate grid%hc3p(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hc3p=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hc3p' grid%tail_statevars%DataName = 'HC3P' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%hc3p grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%hc3p(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7177,& 'frame/module_domain.f: Failed to allocate grid%hc3p(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ethp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ethp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7186,& 'frame/module_domain.f: Failed to allocate grid%ethp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ethp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ethp' grid%tail_statevars%DataName = 'ETHP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ethp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ethp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7236,& 'frame/module_domain.f: Failed to allocate grid%ethp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'o3p').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%o3p(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7245,& 'frame/module_domain.f: Failed to allocate grid%o3p(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%o3p=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'o3p' grid%tail_statevars%DataName = 'O3P' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%o3p grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%o3p(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7295,& 'frame/module_domain.f: Failed to allocate grid%o3p(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tco3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tco3(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7304,& 'frame/module_domain.f: Failed to allocate grid%tco3(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tco3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tco3' grid%tail_statevars%DataName = 'TCO3' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tco3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tco3(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7354,& 'frame/module_domain.f: Failed to allocate grid%tco3(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mo2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%mo2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7363,& 'frame/module_domain.f: Failed to allocate grid%mo2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mo2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'mo2' grid%tail_statevars%DataName = 'MO2' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%mo2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%mo2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7413,& 'frame/module_domain.f: Failed to allocate grid%mo2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'o1d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%o1d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7422,& 'frame/module_domain.f: Failed to allocate grid%o1d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%o1d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'o1d' grid%tail_statevars%DataName = 'O1D' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%o1d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%o1d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7472,& 'frame/module_domain.f: Failed to allocate grid%o1d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'olnn').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%olnn(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7481,& 'frame/module_domain.f: Failed to allocate grid%olnn(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%olnn=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'olnn' grid%tail_statevars%DataName = 'OLNN' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%olnn grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%olnn(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7531,& 'frame/module_domain.f: Failed to allocate grid%olnn(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'olnd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%olnd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7540,& 'frame/module_domain.f: Failed to allocate grid%olnd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%olnd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'olnd' grid%tail_statevars%DataName = 'OLND' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%olnd grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%olnd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7590,& 'frame/module_domain.f: Failed to allocate grid%olnd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rpho').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rpho(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7599,& 'frame/module_domain.f: Failed to allocate grid%rpho(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rpho=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rpho' grid%tail_statevars%DataName = 'RPHO' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rpho grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rpho(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7649,& 'frame/module_domain.f: Failed to allocate grid%rpho(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xo2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xo2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7658,& 'frame/module_domain.f: Failed to allocate grid%xo2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xo2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xo2' grid%tail_statevars%DataName = 'XO2' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%xo2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%xo2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7708,& 'frame/module_domain.f: Failed to allocate grid%xo2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ketp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ketp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7717,& 'frame/module_domain.f: Failed to allocate grid%ketp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ketp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ketp' grid%tail_statevars%DataName = 'KETP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ketp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ketp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7767,& 'frame/module_domain.f: Failed to allocate grid%ketp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xno2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xno2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7776,& 'frame/module_domain.f: Failed to allocate grid%xno2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xno2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xno2' grid%tail_statevars%DataName = 'XNO2' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%xno2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%xno2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7826,& 'frame/module_domain.f: Failed to allocate grid%xno2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ol2p').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ol2p(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7835,& 'frame/module_domain.f: Failed to allocate grid%ol2p(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ol2p=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ol2p' grid%tail_statevars%DataName = 'OL2P' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ol2p grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ol2p(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7885,& 'frame/module_domain.f: Failed to allocate grid%ol2p(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'oln').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%oln(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7894,& 'frame/module_domain.f: Failed to allocate grid%oln(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%oln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'oln' grid%tail_statevars%DataName = 'OLN' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%oln grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%oln(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7944,& 'frame/module_domain.f: Failed to allocate grid%oln(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'macp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%macp(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7953,& 'frame/module_domain.f: Failed to allocate grid%macp(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%macp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'macp' grid%tail_statevars%DataName = 'MACP' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%macp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%macp(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8003,& 'frame/module_domain.f: Failed to allocate grid%macp(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hocoo').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hocoo(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8012,& 'frame/module_domain.f: Failed to allocate grid%hocoo(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hocoo=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hocoo' grid%tail_statevars%DataName = 'HOCOO' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%hocoo grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%hocoo(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8062,& 'frame/module_domain.f: Failed to allocate grid%hocoo(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bzno2_o').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bzno2_o(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8071,& 'frame/module_domain.f: Failed to allocate grid%bzno2_o(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bzno2_o=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bzno2_o' grid%tail_statevars%DataName = 'BZNO2_O' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bzno2_o grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bzno2_o(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8121,& 'frame/module_domain.f: Failed to allocate grid%bzno2_o(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bz_o').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bz_o(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8130,& 'frame/module_domain.f: Failed to allocate grid%bz_o(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bz_o=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bz_o' grid%tail_statevars%DataName = 'BZ_O' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bz_o grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%bz_o(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8180,& 'frame/module_domain.f: Failed to allocate grid%bz_o(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tbu_o').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tbu_o(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8189,& 'frame/module_domain.f: Failed to allocate grid%tbu_o(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tbu_o=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tbu_o' grid%tail_statevars%DataName = 'TBU_O' grid%tail_statevars%Description = 'Radicals' grid%tail_statevars%Units = 'ppm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%tbu_o grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tbu_o(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8239,& 'frame/module_domain.f: Failed to allocate grid%tbu_o(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'vprm_in'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((8)-(1)+1))*(((em33)-(sm33)+1)*num_vprm_in)) * 4 ALLOCATE(grid%vprm_in(sm31:em31,1:8,sm33:em33,num_vprm_in),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8248,& 'frame/module_domain.f: Failed to allocate grid%vprm_in(sm31:em31,1:8,sm33:em33,num_vprm_in). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vprm_in=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vprm_in' grid%tail_statevars%DataName = 'VPRM_IN' grid%tail_statevars%Description = 'VPRM input fields' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%vprm_in grid%tail_statevars%num_table => vprm_in_num_table grid%tail_statevars%index_table => vprm_in_index_table grid%tail_statevars%boundary_table => vprm_in_boundary_table grid%tail_statevars%dname_table => vprm_in_dname_table grid%tail_statevars%desc_table => vprm_in_desc_table grid%tail_statevars%units_table => vprm_in_units_table grid%tail_statevars%streams_table => vprm_in_streams_table grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097664 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 8 grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 8 grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 8 grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'vprm_vgcls' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%vprm_in(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8305,& 'frame/module_domain.f: Failed to allocate grid%vprm_in(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rad_vprm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((8)-(1)+1))) * 4 ALLOCATE(grid%rad_vprm(1:8),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8314,& 'frame/module_domain.f: Failed to allocate grid%rad_vprm(1:8). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rad_vprm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rad_vprm' grid%tail_statevars%DataName = 'RAD_VPRM' grid%tail_statevars%Description = ' ' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%rad_vprm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 8 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 8 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 8 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'vprm_vgcls' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%rad_vprm(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8362,& 'frame/module_domain.f: Failed to allocate grid%rad_vprm(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lambda_vprm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((8)-(1)+1))) * 4 ALLOCATE(grid%lambda_vprm(1:8),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8371,& 'frame/module_domain.f: Failed to allocate grid%lambda_vprm(1:8). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lambda_vprm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lambda_vprm' grid%tail_statevars%DataName = 'LAMBDA_VPRM' grid%tail_statevars%Description = ' ' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%lambda_vprm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 8 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 8 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 8 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'vprm_vgcls' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%lambda_vprm(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8419,& 'frame/module_domain.f: Failed to allocate grid%lambda_vprm(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'alpha_vprm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((8)-(1)+1))) * 4 ALLOCATE(grid%alpha_vprm(1:8),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8428,& 'frame/module_domain.f: Failed to allocate grid%alpha_vprm(1:8). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%alpha_vprm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'alpha_vprm' grid%tail_statevars%DataName = 'ALPHA_VPRM' grid%tail_statevars%Description = ' ' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%alpha_vprm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 8 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 8 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 8 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'vprm_vgcls' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%alpha_vprm(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8476,& 'frame/module_domain.f: Failed to allocate grid%alpha_vprm(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'resp_vprm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((8)-(1)+1))) * 4 ALLOCATE(grid%resp_vprm(1:8),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8485,& 'frame/module_domain.f: Failed to allocate grid%resp_vprm(1:8). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%resp_vprm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'resp_vprm' grid%tail_statevars%DataName = 'RESP_VPRM' grid%tail_statevars%Description = ' ' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%resp_vprm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 8 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 8 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 8 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'vprm_vgcls' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%resp_vprm(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8533,& 'frame/module_domain.f: Failed to allocate grid%resp_vprm(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wet_in'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((1)-(1)+1))*(((em33)-(sm33)+1)*num_wet_in)) * 4 ALLOCATE(grid%wet_in(sm31:em31,1:1,sm33:em33,num_wet_in),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8542,& 'frame/module_domain.f: Failed to allocate grid%wet_in(sm31:em31,1:1,sm33:em33,num_wet_in). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wet_in=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wet_in' grid%tail_statevars%DataName = 'WET_IN' grid%tail_statevars%Description = 'Wetland input fields' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%wet_in grid%tail_statevars%num_table => wet_in_num_table grid%tail_statevars%index_table => wet_in_index_table grid%tail_statevars%boundary_table => wet_in_boundary_table grid%tail_statevars%dname_table => wet_in_dname_table grid%tail_statevars%desc_table => wet_in_desc_table grid%tail_statevars%units_table => wet_in_units_table grid%tail_statevars%streams_table => wet_in_streams_table grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097664 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'one' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%wet_in(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8599,& 'frame/module_domain.f: Failed to allocate grid%wet_in(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'biomt_par').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((14)-(1)+1))) * 4 ALLOCATE(grid%biomt_par(1:14),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8608,& 'frame/module_domain.f: Failed to allocate grid%biomt_par(1:14). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%biomt_par=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'biomt_par' grid%tail_statevars%DataName = 'BIOMT_PAR' grid%tail_statevars%Description = 'biomass termite per vegetation type' grid%tail_statevars%Units = 'g/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%biomt_par grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 14 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 14 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 14 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'termite_vgcls' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%biomt_par(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8656,& 'frame/module_domain.f: Failed to allocate grid%biomt_par(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'emit_par').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((14)-(1)+1))) * 4 ALLOCATE(grid%emit_par(1:14),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8665,& 'frame/module_domain.f: Failed to allocate grid%emit_par(1:14). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%emit_par=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'emit_par' grid%tail_statevars%DataName = 'EMIT_PAR' grid%tail_statevars%Description = ' ' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%emit_par grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 14 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 14 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 14 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'termite_vgcls' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%emit_par(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8713,& 'frame/module_domain.f: Failed to allocate grid%emit_par(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'chem'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_chem)) * 4 ALLOCATE(grid%chem(sm31:em31,sm32:em32,sm33:em33,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8722,& 'frame/module_domain.f: Failed to allocate grid%chem(sm31:em31,sm32:em32,sm33:em33,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'chem' grid%tail_statevars%DataName = 'CHEM' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%chem grid%tail_statevars%num_table => chem_num_table grid%tail_statevars%index_table => chem_index_table grid%tail_statevars%boundary_table => chem_boundary_table grid%tail_statevars%dname_table => chem_dname_table grid%tail_statevars%desc_table => chem_desc_table grid%tail_statevars%units_table => chem_units_table grid%tail_statevars%streams_table => chem_streams_table grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097216 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%chem(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8779,& 'frame/module_domain.f: Failed to allocate grid%chem(1,1,1,1). ') endif ENDIF IF(.TRUE..AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_bxs(sm33:em33,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8788,& 'frame/module_domain.f: Failed to allocate grid%chem_bxs(sm33:em33,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_bxs=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_bxe(sm33:em33,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8796,& 'frame/module_domain.f: Failed to allocate grid%chem_bxe(sm33:em33,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_bxe=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_bys(sm31:em31,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8804,& 'frame/module_domain.f: Failed to allocate grid%chem_bys(sm31:em31,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_bys=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_bye(sm31:em31,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8812,& 'frame/module_domain.f: Failed to allocate grid%chem_bye(sm31:em31,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_bye=initial_data_value ELSE ALLOCATE(grid%chem_bxs(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8819,& 'frame/module_domain.f: Failed to allocate grid%chem_bxs(1,1,1,num_chem). ') endif ALLOCATE(grid%chem_bxe(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8824,& 'frame/module_domain.f: Failed to allocate grid%chem_bxe(1,1,1,num_chem). ') endif ALLOCATE(grid%chem_bys(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8829,& 'frame/module_domain.f: Failed to allocate grid%chem_bys(1,1,1,num_chem). ') endif ALLOCATE(grid%chem_bye(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8834,& 'frame/module_domain.f: Failed to allocate grid%chem_bye(1,1,1,num_chem). ') endif ENDIF IF(.TRUE..AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_btxs(sm33:em33,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8843,& 'frame/module_domain.f: Failed to allocate grid%chem_btxs(sm33:em33,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_btxs=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_btxe(sm33:em33,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8851,& 'frame/module_domain.f: Failed to allocate grid%chem_btxe(sm33:em33,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_btxe=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_btys(sm31:em31,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8859,& 'frame/module_domain.f: Failed to allocate grid%chem_btys(sm31:em31,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_btys=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_chem)) * 4 ALLOCATE(grid%chem_btye(sm31:em31,sm32:em32,spec_bdy_width,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8867,& 'frame/module_domain.f: Failed to allocate grid%chem_btye(sm31:em31,sm32:em32,spec_bdy_width,num_chem). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%chem_btye=initial_data_value ELSE ALLOCATE(grid%chem_btxs(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8874,& 'frame/module_domain.f: Failed to allocate grid%chem_btxs(1,1,1,num_chem). ') endif ALLOCATE(grid%chem_btxe(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8879,& 'frame/module_domain.f: Failed to allocate grid%chem_btxe(1,1,1,num_chem). ') endif ALLOCATE(grid%chem_btys(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8884,& 'frame/module_domain.f: Failed to allocate grid%chem_btys(1,1,1,num_chem). ') endif ALLOCATE(grid%chem_btye(1,1,1,num_chem),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8889,& 'frame/module_domain.f: Failed to allocate grid%chem_btye(1,1,1,num_chem). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tracer'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_tracer)) * 4 ALLOCATE(grid%tracer(sm31:em31,sm32:em32,sm33:em33,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8898,& 'frame/module_domain.f: Failed to allocate grid%tracer(sm31:em31,sm32:em32,sm33:em33,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tracer' grid%tail_statevars%DataName = 'TRACER' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%tracer grid%tail_statevars%num_table => tracer_num_table grid%tail_statevars%index_table => tracer_index_table grid%tail_statevars%boundary_table => tracer_boundary_table grid%tail_statevars%dname_table => tracer_dname_table grid%tail_statevars%desc_table => tracer_desc_table grid%tail_statevars%units_table => tracer_units_table grid%tail_statevars%streams_table => tracer_streams_table grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097156 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tracer(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8955,& 'frame/module_domain.f: Failed to allocate grid%tracer(1,1,1,1). ') endif ENDIF IF(.TRUE..AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_bxs(sm33:em33,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8964,& 'frame/module_domain.f: Failed to allocate grid%tracer_bxs(sm33:em33,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_bxs=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_bxe(sm33:em33,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8972,& 'frame/module_domain.f: Failed to allocate grid%tracer_bxe(sm33:em33,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_bxe=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_bys(sm31:em31,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8980,& 'frame/module_domain.f: Failed to allocate grid%tracer_bys(sm31:em31,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_bys=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_bye(sm31:em31,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8988,& 'frame/module_domain.f: Failed to allocate grid%tracer_bye(sm31:em31,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_bye=initial_data_value ELSE ALLOCATE(grid%tracer_bxs(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8995,& 'frame/module_domain.f: Failed to allocate grid%tracer_bxs(1,1,1,num_tracer). ') endif ALLOCATE(grid%tracer_bxe(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9000,& 'frame/module_domain.f: Failed to allocate grid%tracer_bxe(1,1,1,num_tracer). ') endif ALLOCATE(grid%tracer_bys(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9005,& 'frame/module_domain.f: Failed to allocate grid%tracer_bys(1,1,1,num_tracer). ') endif ALLOCATE(grid%tracer_bye(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9010,& 'frame/module_domain.f: Failed to allocate grid%tracer_bye(1,1,1,num_tracer). ') endif ENDIF IF(.TRUE..AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_btxs(sm33:em33,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9019,& 'frame/module_domain.f: Failed to allocate grid%tracer_btxs(sm33:em33,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_btxs=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em33-sm33+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_btxe(sm33:em33,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9027,& 'frame/module_domain.f: Failed to allocate grid%tracer_btxe(sm33:em33,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_btxe=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_btys(sm31:em31,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9035,& 'frame/module_domain.f: Failed to allocate grid%tracer_btys(sm31:em31,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_btys=initial_data_value num_bytes_allocated = num_bytes_allocated + & (((em31-sm31+1)*(em32-sm32+1)*(spec_bdy_width)*num_tracer)) * 4 ALLOCATE(grid%tracer_btye(sm31:em31,sm32:em32,spec_bdy_width,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9043,& 'frame/module_domain.f: Failed to allocate grid%tracer_btye(sm31:em31,sm32:em32,spec_bdy_width,num_tracer). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tracer_btye=initial_data_value ELSE ALLOCATE(grid%tracer_btxs(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9050,& 'frame/module_domain.f: Failed to allocate grid%tracer_btxs(1,1,1,num_tracer). ') endif ALLOCATE(grid%tracer_btxe(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9055,& 'frame/module_domain.f: Failed to allocate grid%tracer_btxe(1,1,1,num_tracer). ') endif ALLOCATE(grid%tracer_btys(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9060,& 'frame/module_domain.f: Failed to allocate grid%tracer_btys(1,1,1,num_tracer). ') endif ALLOCATE(grid%tracer_btye(1,1,1,num_tracer),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9065,& 'frame/module_domain.f: Failed to allocate grid%tracer_btye(1,1,1,num_tracer). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'irr_diag'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_irr_diag)) * 4 ALLOCATE(grid%irr_diag(sm31:em31,sm32:em32,sm33:em33,num_irr_diag),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9074,& 'frame/module_domain.f: Failed to allocate grid%irr_diag(sm31:em31,sm32:em32,sm33:em33,num_irr_diag). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%irr_diag=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'irr_diag' grid%tail_statevars%DataName = 'IRR_DIAG' grid%tail_statevars%Description = 'Integrated Reaction Rates' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%irr_diag grid%tail_statevars%num_table => irr_diag_num_table grid%tail_statevars%index_table => irr_diag_index_table grid%tail_statevars%boundary_table => irr_diag_boundary_table grid%tail_statevars%dname_table => irr_diag_dname_table grid%tail_statevars%desc_table => irr_diag_desc_table grid%tail_statevars%units_table => irr_diag_units_table grid%tail_statevars%streams_table => irr_diag_streams_table grid%tail_statevars%streams(1) = 512 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%irr_diag(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9131,& 'frame/module_domain.f: Failed to allocate grid%irr_diag(1,1,1,1). ') endif ENDIF IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'stepbioe' grid%tail_statevars%DataName = 'STEPBIOE' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN BIOGENIC EMIS CALLS' grid%tail_statevars%Units = 'NA' grid%tail_statevars%Type = 'i' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_0d => grid%stepbioe grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepbioe=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'stepphot' grid%tail_statevars%DataName = 'STEPPHOT' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN PHOTOLYSIS CALLS' grid%tail_statevars%Units = 'NA' grid%tail_statevars%Type = 'i' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_0d => grid%stepphot grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepphot=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'stepchem' grid%tail_statevars%DataName = 'STEPCHEM' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN CHEM MECH CALLS' grid%tail_statevars%Units = 'NA' grid%tail_statevars%Type = 'i' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_0d => grid%stepchem grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepchem=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'stepfirepl' grid%tail_statevars%DataName = 'STEPFIREPL' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN CALLSTO PLUMERISE FIRE ROUTINE' grid%tail_statevars%Units = 'NA' grid%tail_statevars%Type = 'i' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_0d => grid%stepfirepl grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepfirepl=0 IF ( setinitval .EQ. 3 ) grid%io_style_emissions=0 IF ( setinitval .EQ. 3 ) grid%bioemdt=initial_data_value IF ( setinitval .EQ. 3 ) grid%photdt=initial_data_value IF ( setinitval .EQ. 3 ) grid%chemdt=initial_data_value IF ( setinitval .EQ. 3 ) grid%ne_area=0 IF ( setinitval .EQ. 3 ) grid%kemit=0 IF ( setinitval .EQ. 3 ) grid%nmegan=0 IF ( setinitval .EQ. 3 ) grid%kfuture=0 IF ( setinitval .EQ. 3 ) grid%kfire=0 IF ( setinitval .EQ. 3 ) grid%kemit_aircraft=0 IF ( setinitval .EQ. 3 ) grid%kdvel=0 IF ( setinitval .EQ. 3 ) grid%ndepvel=0 IF ( setinitval .EQ. 3 ) grid%kdepvel=0 IF ( setinitval .EQ. 3 ) grid%erosion_dim=0 IF ( setinitval .EQ. 3 ) grid%biomass_emiss_opt=0 IF ( setinitval .EQ. 3 ) grid%cam_mam_mode=0 IF ( setinitval .EQ. 3 ) grid%cam_mam_nspec=0 IF ( setinitval .EQ. 3 ) grid%cam_mp_mam_cpled=.FALSE. IF ( setinitval .EQ. 3 ) grid%lightning_opt=0 IF ( setinitval .EQ. 3 ) grid%lightning_time_step=0 IF ( setinitval .EQ. 3 ) grid%temp_upper=initial_data_value IF ( setinitval .EQ. 3 ) grid%temp_lower=initial_data_value IF ( setinitval .EQ. 3 ) grid%n_ic=initial_data_value IF ( setinitval .EQ. 3 ) grid%n_cg=initial_data_value IF ( setinitval .EQ. 3 ) grid%passive_ltng=0 IF ( setinitval .EQ. 3 ) grid%lflash_data=0 IF ( setinitval .EQ. 3 ) grid%flashrate_method=0 IF ( setinitval .EQ. 3 ) grid%wpeat=initial_data_value IF ( setinitval .EQ. 3 ) grid%wflood=initial_data_value IF ( setinitval .EQ. 3 ) grid%chem_conv_tr=0 IF ( setinitval .EQ. 3 ) grid%conv_tr_wetscav=0 IF ( setinitval .EQ. 3 ) grid%conv_tr_aqchem=0 IF ( setinitval .EQ. 3 ) grid%chem_opt=0 IF ( setinitval .EQ. 3 ) grid%gaschem_onoff=0 IF ( setinitval .EQ. 3 ) grid%aerchem_onoff=0 IF ( setinitval .EQ. 3 ) grid%wetscav_onoff=0 IF ( setinitval .EQ. 3 ) grid%dustwd_onoff=0 IF ( setinitval .EQ. 3 ) grid%cldchem_onoff=0 IF ( setinitval .EQ. 3 ) grid%is_full_tuv=.FALSE. IF ( setinitval .EQ. 3 ) grid%lambda_cutoff=initial_data_value IF ( setinitval .EQ. 3 ) grid%cld_od_opt=0 IF ( setinitval .EQ. 3 ) grid%pht_cldfrc_opt=0 IF ( setinitval .EQ. 3 ) grid%vertmix_onoff=0 IF ( setinitval .EQ. 3 ) grid%chem_in_opt=0 IF ( setinitval .EQ. 3 ) grid%phot_opt=0 IF ( setinitval .EQ. 3 ) grid%gas_drydep_opt=0 IF ( setinitval .EQ. 3 ) grid%aer_drydep_opt=0 IF ( setinitval .EQ. 3 ) grid%diagnostic_chem=0 IF ( setinitval .EQ. 3 ) grid%aero_diag_opt=0 IF ( setinitval .EQ. 3 ) grid%aero_cw_diag_opt=0 IF ( setinitval .EQ. 3 ) grid%aer_aerodynres_opt=0 IF ( setinitval .EQ. 3 ) grid%emiss_opt=0 IF ( setinitval .EQ. 3 ) grid%emiss_opt_vol=0 IF ( setinitval .EQ. 3 ) grid%dust_opt=0 IF ( setinitval .EQ. 3 ) grid%dust_schme=0 IF ( setinitval .EQ. 3 ) grid%dmsemis_opt=0 IF ( setinitval .EQ. 3 ) grid%seas_opt=0 IF ( setinitval .EQ. 3 ) grid%bio_emiss_opt=0 IF ( setinitval .EQ. 3 ) grid%biomass_burn_opt=0 IF ( setinitval .EQ. 3 ) grid%plumerisefire_frq=0 IF ( setinitval .EQ. 3 ) grid%emiss_inpt_opt=0 IF ( setinitval .EQ. 3 ) grid%gas_bc_opt=0 IF ( setinitval .EQ. 3 ) grid%gas_ic_opt=0 IF ( setinitval .EQ. 3 ) grid%aer_bc_opt=0 IF ( setinitval .EQ. 3 ) grid%aer_ic_opt=0 IF ( setinitval .EQ. 3 ) grid%have_bcs_chem=.FALSE. IF ( setinitval .EQ. 3 ) grid%have_bcs_tracer=.FALSE. IF ( setinitval .EQ. 3 ) grid%scale_fire_emiss=.FALSE. IF ( setinitval .EQ. 3 ) grid%aer_ra_feedback=0 IF ( setinitval .EQ. 3 ) grid%aer_op_opt=0 IF ( setinitval .EQ. 3 ) grid%opt_pars_out=0 IF ( setinitval .EQ. 3 ) grid%diagnostic_dep=0 IF ( setinitval .EQ. 3 ) grid%aircraft_emiss_opt=0 IF ( setinitval .EQ. 3 ) grid%have_bcs_upper=.FALSE. IF ( setinitval .EQ. 3 ) grid%fixed_ubc_press=initial_data_value IF ( setinitval .EQ. 3 ) grid%chemdiag=0 IF ( setinitval .EQ. 3 ) grid%dust_alpha=initial_data_value IF ( setinitval .EQ. 3 ) grid%dust_gamma=initial_data_value IF ( setinitval .EQ. 3 ) grid%dust_smtune=initial_data_value IF ( setinitval .EQ. 3 ) grid%dust_ustune=initial_data_value IF ( setinitval .EQ. 3 ) grid%dust_dsr=0 IF ( setinitval .EQ. 3 ) grid%dust_veg=0 IF ( setinitval .EQ. 3 ) grid%dust_soils=0 IF ( setinitval .EQ. 3 ) grid%dust_smois=0 IF ( setinitval .EQ. 3 ) grid%emiss_ash_hgt=initial_data_value IF ( setinitval .EQ. 3 ) grid%depo_fact=initial_data_value IF ( setinitval .EQ. 3 ) grid%track_chem_num=0 IF ( setinitval .EQ. 3 ) grid%track_rad_num=0 IF ( setinitval .EQ. 3 ) grid%track_tuv_num=0 IF ( setinitval .EQ. 3 ) grid%track_tuv_lev=0 IF ( setinitval .EQ. 3 ) grid%n2o5_hetchem=0 IF ( setinitval .EQ. 3 ) grid%af_lambda_start=initial_data_value IF ( setinitval .EQ. 3 ) grid%af_lambda_end=initial_data_value IF ( setinitval .EQ. 3 ) grid%lnox_opt=0 IF ( setinitval .EQ. 3 ) grid%lnox_passive=.FALSE. IF ( setinitval .EQ. 3 ) grid%ltng_temp_upper=initial_data_value IF ( setinitval .EQ. 3 ) grid%ltng_temp_lower=initial_data_value IF ( setinitval .EQ. 3 ) grid%has_o3_exo_coldens=.FALSE. IF ( setinitval .EQ. 3 ) grid%du_at_grnd=initial_data_value IF ( setinitval .EQ. 3 ) grid%scale_o3_to_grnd_exo_coldens=.FALSE. IF ( setinitval .EQ. 3 ) grid%scale_o3_to_du_at_grnd=.FALSE. IF ( setinitval .EQ. 3 ) grid%irr_opt=0 IF(okay_to_alloc.AND.in_use_for_config(id,'lfn_hist').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((1)-(1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%lfn_hist((sm31-1)*sr_x+1:em31*sr_x,1:1,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9318,& 'frame/module_domain.f: Failed to allocate grid%lfn_hist((sm31-1)*sr_x+1:em31*sr_x,1:1,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lfn_hist=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lfn_hist' grid%tail_statevars%DataName = 'LFN_HIST' grid%tail_statevars%Description = 'level function history' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%lfn_hist grid%tail_statevars%streams(1) = 234881025 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = MAX(1,jde * sr_y) grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = (jms-1)*sr_y+1 grid%tail_statevars%em3 = MAX(1,jme*sr_y) grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = (jps-1)*sr_y+1 grid%tail_statevars%ep3 = MAX(1,jpe*sr_y) grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'i_lfn_history_stag' grid%tail_statevars%dimname3 = 'south_north_subgrid' ENDIF ELSE ALLOCATE(grid%lfn_hist(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9368,& 'frame/module_domain.f: Failed to allocate grid%lfn_hist(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lfn_time').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((1)-(1)+1))) * 4 ALLOCATE(grid%lfn_time(1:1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9377,& 'frame/module_domain.f: Failed to allocate grid%lfn_time(1:1). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lfn_time=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lfn_time' grid%tail_statevars%DataName = 'LFN_TIME' grid%tail_statevars%Description = 'level function history time' grid%tail_statevars%Units = 's' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%lfn_time grid%tail_statevars%streams(1) = 234881025 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 1 grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = 1 grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = 1 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'i_lfn_history' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%lfn_time(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9425,& 'frame/module_domain.f: Failed to allocate grid%lfn_time(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nfuel_cat').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%nfuel_cat((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9434,& 'frame/module_domain.f: Failed to allocate grid%nfuel_cat((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nfuel_cat=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nfuel_cat' grid%tail_statevars%DataName = 'NFUEL_CAT' grid%tail_statevars%Description = 'fuel data' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%nfuel_cat grid%tail_statevars%streams(1) = 234881025 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%nfuel_cat(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9484,& 'frame/module_domain.f: Failed to allocate grid%nfuel_cat(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zsf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%zsf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9493,& 'frame/module_domain.f: Failed to allocate grid%zsf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zsf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zsf' grid%tail_statevars%DataName = 'ZSF' grid%tail_statevars%Description = 'height of surface above sea level' grid%tail_statevars%Units = 'm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%zsf grid%tail_statevars%streams(1) = 234881025 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%zsf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9543,& 'frame/module_domain.f: Failed to allocate grid%zsf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dzdxf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%dzdxf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9552,& 'frame/module_domain.f: Failed to allocate grid%dzdxf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dzdxf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dzdxf' grid%tail_statevars%DataName = 'DZDXF' grid%tail_statevars%Description = 'surface gradient x' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%dzdxf grid%tail_statevars%streams(1) = 234881025 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%dzdxf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9602,& 'frame/module_domain.f: Failed to allocate grid%dzdxf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dzdyf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%dzdyf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9611,& 'frame/module_domain.f: Failed to allocate grid%dzdyf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dzdyf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dzdyf' grid%tail_statevars%DataName = 'DZDYF' grid%tail_statevars%Description = 'surface gradient y' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%dzdyf grid%tail_statevars%streams(1) = 234881025 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%dzdyf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9661,& 'frame/module_domain.f: Failed to allocate grid%dzdyf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tign_g').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%tign_g((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9670,& 'frame/module_domain.f: Failed to allocate grid%tign_g((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tign_g=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tign_g' grid%tail_statevars%DataName = 'TIGN_G' grid%tail_statevars%Description = 'ignition time on ground' grid%tail_statevars%Units = 's' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%tign_g grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%tign_g(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9720,& 'frame/module_domain.f: Failed to allocate grid%tign_g(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rthfrten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rthfrten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9729,& 'frame/module_domain.f: Failed to allocate grid%rthfrten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rthfrten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rthfrten' grid%tail_statevars%DataName = 'RTHFRTEN' grid%tail_statevars%Description = 'temperature tendency' grid%tail_statevars%Units = 'K/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rthfrten grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rthfrten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9779,& 'frame/module_domain.f: Failed to allocate grid%rthfrten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rqvfrten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rqvfrten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9788,& 'frame/module_domain.f: Failed to allocate grid%rqvfrten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rqvfrten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rqvfrten' grid%tail_statevars%DataName = 'RQVFRTEN' grid%tail_statevars%Description = 'humidity tendency' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rqvfrten grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rqvfrten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9838,& 'frame/module_domain.f: Failed to allocate grid%rqvfrten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avg_fuel_frac').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avg_fuel_frac(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9847,& 'frame/module_domain.f: Failed to allocate grid%avg_fuel_frac(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avg_fuel_frac=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avg_fuel_frac' grid%tail_statevars%DataName = 'AVG_FUEL_FRAC' grid%tail_statevars%Description = 'fuel remaining averaged to atmospheric grid' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%avg_fuel_frac grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%avg_fuel_frac(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9897,& 'frame/module_domain.f: Failed to allocate grid%avg_fuel_frac(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'grnhfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%grnhfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9906,& 'frame/module_domain.f: Failed to allocate grid%grnhfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%grnhfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'grnhfx' grid%tail_statevars%DataName = 'GRNHFX' grid%tail_statevars%Description = 'heat flux from ground fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%grnhfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%grnhfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9956,& 'frame/module_domain.f: Failed to allocate grid%grnhfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'grnqfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%grnqfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9965,& 'frame/module_domain.f: Failed to allocate grid%grnqfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%grnqfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'grnqfx' grid%tail_statevars%DataName = 'GRNQFX' grid%tail_statevars%Description = 'moisture flux from ground fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%grnqfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%grnqfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10015,& 'frame/module_domain.f: Failed to allocate grid%grnqfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'canhfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%canhfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10024,& 'frame/module_domain.f: Failed to allocate grid%canhfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%canhfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'canhfx' grid%tail_statevars%DataName = 'CANHFX' grid%tail_statevars%Description = 'heat flux from crown fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%canhfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%canhfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10074,& 'frame/module_domain.f: Failed to allocate grid%canhfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'canqfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%canqfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10083,& 'frame/module_domain.f: Failed to allocate grid%canqfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%canqfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'canqfx' grid%tail_statevars%DataName = 'CANQFX' grid%tail_statevars%Description = 'moisture flux from crown fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%canqfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%canqfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10133,& 'frame/module_domain.f: Failed to allocate grid%canqfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'uah').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%uah(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10142,& 'frame/module_domain.f: Failed to allocate grid%uah(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%uah=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'uah' grid%tail_statevars%DataName = 'UAH' grid%tail_statevars%Description = 'wind at fire_wind_height' grid%tail_statevars%Units = 'm/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'X' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%uah grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%uah(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10192,& 'frame/module_domain.f: Failed to allocate grid%uah(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'vah').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%vah(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10201,& 'frame/module_domain.f: Failed to allocate grid%vah(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vah=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vah' grid%tail_statevars%DataName = 'VAH' grid%tail_statevars%Description = 'wind at fire_wind_height' grid%tail_statevars%Units = 'm/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Y' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%vah grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%vah(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10251,& 'frame/module_domain.f: Failed to allocate grid%vah(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lfn').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%lfn((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10260,& 'frame/module_domain.f: Failed to allocate grid%lfn((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lfn=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lfn' grid%tail_statevars%DataName = 'LFN' grid%tail_statevars%Description = 'level function' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%lfn grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%lfn(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10310,& 'frame/module_domain.f: Failed to allocate grid%lfn(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fuel_frac').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fuel_frac((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10319,& 'frame/module_domain.f: Failed to allocate grid%fuel_frac((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fuel_frac=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fuel_frac' grid%tail_statevars%DataName = 'FUEL_FRAC' grid%tail_statevars%Description = 'fuel remaining' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fuel_frac grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fuel_frac(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10369,& 'frame/module_domain.f: Failed to allocate grid%fuel_frac(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fire_area').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fire_area((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10378,& 'frame/module_domain.f: Failed to allocate grid%fire_area((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fire_area=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fire_area' grid%tail_statevars%DataName = 'FIRE_AREA' grid%tail_statevars%Description = 'fraction of cell area on fire' grid%tail_statevars%Units = '1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fire_area grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fire_area(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10428,& 'frame/module_domain.f: Failed to allocate grid%fire_area(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'uf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%uf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10437,& 'frame/module_domain.f: Failed to allocate grid%uf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%uf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'uf' grid%tail_statevars%DataName = 'UF' grid%tail_statevars%Description = 'fire wind' grid%tail_statevars%Units = 'm/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%uf grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%uf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10487,& 'frame/module_domain.f: Failed to allocate grid%uf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'vf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%vf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10496,& 'frame/module_domain.f: Failed to allocate grid%vf((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vf' grid%tail_statevars%DataName = 'VF' grid%tail_statevars%Description = 'fire wind' grid%tail_statevars%Units = 'm/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%vf grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%vf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10546,& 'frame/module_domain.f: Failed to allocate grid%vf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fgrnhfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fgrnhfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10555,& 'frame/module_domain.f: Failed to allocate grid%fgrnhfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fgrnhfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fgrnhfx' grid%tail_statevars%DataName = 'FGRNHFX' grid%tail_statevars%Description = 'heat flux from ground fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fgrnhfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fgrnhfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10605,& 'frame/module_domain.f: Failed to allocate grid%fgrnhfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fgrnqfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fgrnqfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10614,& 'frame/module_domain.f: Failed to allocate grid%fgrnqfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fgrnqfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fgrnqfx' grid%tail_statevars%DataName = 'FGRNQFX' grid%tail_statevars%Description = 'moisture flux from ground fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fgrnqfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fgrnqfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10664,& 'frame/module_domain.f: Failed to allocate grid%fgrnqfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fcanhfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fcanhfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10673,& 'frame/module_domain.f: Failed to allocate grid%fcanhfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fcanhfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fcanhfx' grid%tail_statevars%DataName = 'FCANHFX' grid%tail_statevars%Description = 'heat flux from crown fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fcanhfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fcanhfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10723,& 'frame/module_domain.f: Failed to allocate grid%fcanhfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fcanqfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fcanqfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10732,& 'frame/module_domain.f: Failed to allocate grid%fcanqfx((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fcanqfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fcanqfx' grid%tail_statevars%DataName = 'FCANQFX' grid%tail_statevars%Description = 'moisture flux from crown fire' grid%tail_statevars%Units = 'W/m^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fcanqfx grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fcanqfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10782,& 'frame/module_domain.f: Failed to allocate grid%fcanqfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ros').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%ros((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10791,& 'frame/module_domain.f: Failed to allocate grid%ros((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ros=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ros' grid%tail_statevars%DataName = 'ROS' grid%tail_statevars%Description = 'rate of spread' grid%tail_statevars%Units = 'm/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%ros grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%ros(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10841,& 'frame/module_domain.f: Failed to allocate grid%ros(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fxlong').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fxlong((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10850,& 'frame/module_domain.f: Failed to allocate grid%fxlong((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fxlong=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fxlong' grid%tail_statevars%DataName = 'FXLONG' grid%tail_statevars%Description = 'longitude of midpoints of fire cells' grid%tail_statevars%Units = 'degrees' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fxlong grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fxlong(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10900,& 'frame/module_domain.f: Failed to allocate grid%fxlong(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fxlat').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fxlat((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10909,& 'frame/module_domain.f: Failed to allocate grid%fxlat((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fxlat=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fxlat' grid%tail_statevars%DataName = 'FXLAT' grid%tail_statevars%Description = 'latitude of midpoints of fire cells' grid%tail_statevars%Units = 'degrees' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fxlat grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fxlat(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10959,& 'frame/module_domain.f: Failed to allocate grid%fxlat(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fuel_time').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fuel_time((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10968,& 'frame/module_domain.f: Failed to allocate grid%fuel_time((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fuel_time=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fuel_time' grid%tail_statevars%DataName = 'FUEL_TIME' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fuel_time grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fuel_time(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11018,& 'frame/module_domain.f: Failed to allocate grid%fuel_time(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bbb').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%bbb((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11027,& 'frame/module_domain.f: Failed to allocate grid%bbb((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bbb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bbb' grid%tail_statevars%DataName = 'BBB' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%bbb grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%bbb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11077,& 'frame/module_domain.f: Failed to allocate grid%bbb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'betafl').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%betafl((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11086,& 'frame/module_domain.f: Failed to allocate grid%betafl((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%betafl=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'betafl' grid%tail_statevars%DataName = 'BETAFL' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%betafl grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%betafl(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11136,& 'frame/module_domain.f: Failed to allocate grid%betafl(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'phiwc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%phiwc((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11145,& 'frame/module_domain.f: Failed to allocate grid%phiwc((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%phiwc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'phiwc' grid%tail_statevars%DataName = 'PHIWC' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%phiwc grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%phiwc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11195,& 'frame/module_domain.f: Failed to allocate grid%phiwc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'r_0').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%r_0((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11204,& 'frame/module_domain.f: Failed to allocate grid%r_0((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%r_0=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'r_0' grid%tail_statevars%DataName = 'R_0' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%r_0 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%r_0(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11254,& 'frame/module_domain.f: Failed to allocate grid%r_0(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fgip').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%fgip((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11263,& 'frame/module_domain.f: Failed to allocate grid%fgip((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fgip=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fgip' grid%tail_statevars%DataName = 'FGIP' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fgip grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%fgip(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11313,& 'frame/module_domain.f: Failed to allocate grid%fgip(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ischap').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31*sr_x)-((sm31-1)*sr_x+1)+1))*(((em33*sr_y)-((sm33-1)*sr_y+1)+1))) * 4 ALLOCATE(grid%ischap((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11322,& 'frame/module_domain.f: Failed to allocate grid%ischap((sm31-1)*sr_x+1:em31*sr_x,(sm33-1)*sr_y+1:em33*sr_y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ischap=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ischap' grid%tail_statevars%DataName = 'ISCHAP' grid%tail_statevars%Description = 'fuel' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%ischap grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = MAX(1,ide * sr_x) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = MAX(1,jde * sr_y) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = (ims-1)*sr_x+1 grid%tail_statevars%em1 = MAX(1,ime*sr_x) grid%tail_statevars%sm2 = (jms-1)*sr_y+1 grid%tail_statevars%em2 = MAX(1,jme*sr_y) grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = (ips-1)*sr_x+1 grid%tail_statevars%ep1 = MAX(1,ipe*sr_x) grid%tail_statevars%sp2 = (jps-1)*sr_y+1 grid%tail_statevars%ep2 = MAX(1,jpe*sr_y) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .TRUE. grid%tail_statevars%subgrid_y = .TRUE. grid%tail_statevars%dimname1 = 'west_east_subgrid' grid%tail_statevars%dimname2 = 'south_north_subgrid' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%ischap(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11372,& 'frame/module_domain.f: Failed to allocate grid%ischap(1,1). ') endif ENDIF IF ( setinitval .EQ. 3 ) grid%ifire=0 IF ( setinitval .EQ. 3 ) grid%fire_boundary_guard=0 IF ( setinitval .EQ. 3 ) grid%fire_num_ignitions=0 IF ( setinitval .EQ. 3 ) grid%fire_ignition_ros1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lon1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lat1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lon1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lat1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_radius1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_time1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_time1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_ros2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lon2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lat2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lon2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lat2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_radius2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_time2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_time2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_ros3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lon3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lat3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lon3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lat3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_radius3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_time3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_time3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_ros4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lon4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lat4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lon4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lat4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_radius4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_time4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_time4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_ros5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lon5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_lat5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lon5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_lat5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_radius5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_time5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_time5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_x1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_y1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_x1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_y1=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_x2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_y2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_x2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_y2=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_x3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_y3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_x3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_y3=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_x4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_y4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_x4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_y4=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_x5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_start_y5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_x5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ignition_end_y5=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_lat_init=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_lon_init=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ign_time=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_shape=0 IF ( setinitval .EQ. 3 ) grid%fire_sprd_mdl=0 IF ( setinitval .EQ. 3 ) grid%fire_crwn_hgt=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ext_grnd=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_ext_crwn=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_wind_height=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_fuel_read=0 IF ( setinitval .EQ. 3 ) grid%fire_fuel_cat=0 IF ( setinitval .EQ. 3 ) grid%fire_print_msg=0 IF ( setinitval .EQ. 3 ) grid%fire_print_file=0 IF ( setinitval .EQ. 3 ) grid%fire_fuel_left_method=0 IF ( setinitval .EQ. 3 ) grid%fire_fuel_left_irl=0 IF ( setinitval .EQ. 3 ) grid%fire_fuel_left_jrl=0 IF ( setinitval .EQ. 3 ) grid%fire_back_weight=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_grows_only=0 IF ( setinitval .EQ. 3 ) grid%fire_upwinding=0 IF ( setinitval .EQ. 3 ) grid%fire_upwind_split=0 IF ( setinitval .EQ. 3 ) grid%fire_viscosity=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_lfn_ext_up=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_topo_from_atm=0 IF ( setinitval .EQ. 3 ) grid%fire_advection=0 IF ( setinitval .EQ. 3 ) grid%fire_test_steps=0 IF ( setinitval .EQ. 3 ) grid%fire_const_time=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_const_grnhfx=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_const_grnqfx=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_atm_feedback=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_mountain_type=0 IF ( setinitval .EQ. 3 ) grid%fire_mountain_height=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_mountain_start_x=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_mountain_start_y=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_mountain_end_x=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_mountain_end_y=initial_data_value IF ( setinitval .EQ. 3 ) grid%delt_perturbation=initial_data_value IF ( setinitval .EQ. 3 ) grid%xrad_perturbation=initial_data_value IF ( setinitval .EQ. 3 ) grid%yrad_perturbation=initial_data_value IF ( setinitval .EQ. 3 ) grid%zrad_perturbation=initial_data_value IF ( setinitval .EQ. 3 ) grid%hght_perturbation=initial_data_value IF ( setinitval .EQ. 3 ) grid%stretch_grd=.FALSE. IF ( setinitval .EQ. 3 ) grid%stretch_hyp=.FALSE. IF ( setinitval .EQ. 3 ) grid%z_grd_scale=initial_data_value IF ( setinitval .EQ. 3 ) grid%sfc_full_init=.FALSE. IF ( setinitval .EQ. 3 ) grid%sfc_lu_index=0 IF ( setinitval .EQ. 3 ) grid%sfc_tsk=initial_data_value IF ( setinitval .EQ. 3 ) grid%sfc_tmn=initial_data_value IF ( setinitval .EQ. 3 ) grid%fire_read_lu=.FALSE. IF ( setinitval .EQ. 3 ) grid%fire_read_tsk=.FALSE. IF ( setinitval .EQ. 3 ) grid%fire_read_tmn=.FALSE. IF ( setinitval .EQ. 3 ) grid%fire_read_atm_ht=.FALSE. IF ( setinitval .EQ. 3 ) grid%fire_read_fire_ht=.FALSE. IF ( setinitval .EQ. 3 ) grid%fire_read_atm_grad=.FALSE. IF ( setinitval .EQ. 3 ) grid%fire_read_fire_grad=.FALSE. IF ( setinitval .EQ. 3 ) grid%sfc_vegfra=initial_data_value IF ( setinitval .EQ. 3 ) grid%sfc_canwat=initial_data_value IF ( setinitval .EQ. 3 ) grid%sfc_ivgtyp=0 IF ( setinitval .EQ. 3 ) grid%sfc_isltyp=0 IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_rum').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_rum(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11502,& 'frame/module_domain.f: Failed to allocate grid%avgflx_rum(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_rum=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_rum' grid%tail_statevars%DataName = 'AVGFLX_RUM' grid%tail_statevars%Description = 'hist-time-averaged mu-coupled u' grid%tail_statevars%Units = 'Pa m s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'X' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_rum grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_rum(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11552,& 'frame/module_domain.f: Failed to allocate grid%avgflx_rum(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_rvm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_rvm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11561,& 'frame/module_domain.f: Failed to allocate grid%avgflx_rvm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_rvm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_rvm' grid%tail_statevars%DataName = 'AVGFLX_RVM' grid%tail_statevars%Description = 'hist-time-averaged mu-coupled v' grid%tail_statevars%Units = 'Pa m s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Y' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_rvm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( jde, jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%avgflx_rvm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11611,& 'frame/module_domain.f: Failed to allocate grid%avgflx_rvm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_wwm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_wwm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11620,& 'frame/module_domain.f: Failed to allocate grid%avgflx_wwm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_wwm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_wwm' grid%tail_statevars%DataName = 'AVGFLX_WWM' grid%tail_statevars%Description = 'hist-time-averaged mu-coupled eta-dot' grid%tail_statevars%Units = 'Pa s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_wwm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_wwm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11670,& 'frame/module_domain.f: Failed to allocate grid%avgflx_wwm(1,1,1). ') endif ENDIF IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'avgflx_count' grid%tail_statevars%DataName = 'AVGFLX_COUNT' grid%tail_statevars%Description = 'Counter for time-averaged mu-coupled velocities' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_0d => grid%avgflx_count grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%avgflx_count=0 IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_cfu1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_cfu1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11698,& 'frame/module_domain.f: Failed to allocate grid%avgflx_cfu1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_cfu1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_cfu1' grid%tail_statevars%DataName = 'CFU1' grid%tail_statevars%Description = 'AVERAGE updraft mass flux from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_cfu1 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_cfu1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11748,& 'frame/module_domain.f: Failed to allocate grid%avgflx_cfu1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_cfd1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_cfd1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11757,& 'frame/module_domain.f: Failed to allocate grid%avgflx_cfd1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_cfd1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_cfd1' grid%tail_statevars%DataName = 'CFD1' grid%tail_statevars%Description = 'AVERAGE downdraft mass flux from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_cfd1 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_cfd1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11807,& 'frame/module_domain.f: Failed to allocate grid%avgflx_cfd1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_dfu1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_dfu1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11816,& 'frame/module_domain.f: Failed to allocate grid%avgflx_dfu1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_dfu1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_dfu1' grid%tail_statevars%DataName = 'DFU1' grid%tail_statevars%Description = 'AVERAGE detrainment from updraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_dfu1 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_dfu1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11866,& 'frame/module_domain.f: Failed to allocate grid%avgflx_dfu1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_efu1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_efu1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11875,& 'frame/module_domain.f: Failed to allocate grid%avgflx_efu1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_efu1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_efu1' grid%tail_statevars%DataName = 'EFU1' grid%tail_statevars%Description = 'AVERAGE entrainment into updraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_efu1 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_efu1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11925,& 'frame/module_domain.f: Failed to allocate grid%avgflx_efu1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_dfd1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_dfd1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11934,& 'frame/module_domain.f: Failed to allocate grid%avgflx_dfd1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_dfd1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_dfd1' grid%tail_statevars%DataName = 'DFD1' grid%tail_statevars%Description = 'AVERAGE detrainment from downdraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_dfd1 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_dfd1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11984,& 'frame/module_domain.f: Failed to allocate grid%avgflx_dfd1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'avgflx_efd1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%avgflx_efd1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11993,& 'frame/module_domain.f: Failed to allocate grid%avgflx_efd1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%avgflx_efd1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'avgflx_efd1' grid%tail_statevars%DataName = 'EFD1' grid%tail_statevars%Description = 'AVERAGE entrainment into downdraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%avgflx_efd1 grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%avgflx_efd1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12043,& 'frame/module_domain.f: Failed to allocate grid%avgflx_efd1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cfu1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cfu1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12052,& 'frame/module_domain.f: Failed to allocate grid%cfu1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cfu1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cfu1' grid%tail_statevars%DataName = 'CFU1' grid%tail_statevars%Description = 'instantaneous updraft mass flux from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cfu1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cfu1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12102,& 'frame/module_domain.f: Failed to allocate grid%cfu1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cfd1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cfd1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12111,& 'frame/module_domain.f: Failed to allocate grid%cfd1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cfd1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cfd1' grid%tail_statevars%DataName = 'CFD1' grid%tail_statevars%Description = 'instantaneous downdraft mass flux from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cfd1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cfd1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12161,& 'frame/module_domain.f: Failed to allocate grid%cfd1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dfu1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dfu1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12170,& 'frame/module_domain.f: Failed to allocate grid%dfu1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dfu1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dfu1' grid%tail_statevars%DataName = 'DFU1' grid%tail_statevars%Description = 'instantaneous detrainment from updraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%dfu1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%dfu1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12220,& 'frame/module_domain.f: Failed to allocate grid%dfu1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'efu1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%efu1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12229,& 'frame/module_domain.f: Failed to allocate grid%efu1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%efu1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'efu1' grid%tail_statevars%DataName = 'EFU1' grid%tail_statevars%Description = 'instantaneous entrainment into updraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%efu1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%efu1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12279,& 'frame/module_domain.f: Failed to allocate grid%efu1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dfd1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dfd1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12288,& 'frame/module_domain.f: Failed to allocate grid%dfd1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dfd1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dfd1' grid%tail_statevars%DataName = 'DFD1' grid%tail_statevars%Description = 'instantaneous detrainment from downdraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%dfd1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%dfd1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12338,& 'frame/module_domain.f: Failed to allocate grid%dfd1(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'efd1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%efd1(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12347,& 'frame/module_domain.f: Failed to allocate grid%efd1(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%efd1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'efd1' grid%tail_statevars%DataName = 'EFD1' grid%tail_statevars%Description = 'instantaneous entrainment into downdraft from GD-scheme' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%efd1 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%efd1(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12397,& 'frame/module_domain.f: Failed to allocate grid%efd1(1,1,1). ') endif ENDIF IF ( setinitval .EQ. 3 ) grid%do_avgflx_em=0 IF ( setinitval .EQ. 3 ) grid%do_avgflx_cugd=0 IF(okay_to_alloc.AND.in_use_for_config(id,'vertstrucc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%vertstrucc(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12408,& 'frame/module_domain.f: Failed to allocate grid%vertstrucc(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vertstrucc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vertstrucc' grid%tail_statevars%DataName = 'VERTSTRUCC' grid%tail_statevars%Description = 'vertical structure for stoch. forcing ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%vertstrucc grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%vertstrucc(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12458,& 'frame/module_domain.f: Failed to allocate grid%vertstrucc(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'vertstrucs'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%vertstrucs(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12467,& 'frame/module_domain.f: Failed to allocate grid%vertstrucs(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vertstrucs=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vertstrucs' grid%tail_statevars%DataName = 'VERTSTRUCS' grid%tail_statevars%Description = 'vertical structure for stoch. forcing ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%vertstrucs grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%vertstrucs(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12517,& 'frame/module_domain.f: Failed to allocate grid%vertstrucs(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'field_sf'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%field_sf(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12526,& 'frame/module_domain.f: Failed to allocate grid%field_sf(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%field_sf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'field_sf' grid%tail_statevars%DataName = 'FIELD_SF ' grid%tail_statevars%Description = 'field for surface perturbations ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%field_sf grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%field_sf(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12576,& 'frame/module_domain.f: Failed to allocate grid%field_sf(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'field_pbl'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%field_pbl(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12585,& 'frame/module_domain.f: Failed to allocate grid%field_pbl(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%field_pbl=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'field_pbl' grid%tail_statevars%DataName = 'FIELD_PBL ' grid%tail_statevars%Description = 'field for surface perturbations ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%field_pbl grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%field_pbl(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12635,& 'frame/module_domain.f: Failed to allocate grid%field_pbl(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'field_conv'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%field_conv(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12644,& 'frame/module_domain.f: Failed to allocate grid%field_conv(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%field_conv=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'field_conv' grid%tail_statevars%DataName = 'FIELD_CONV ' grid%tail_statevars%Description = 'field for surface perturbations ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%field_conv grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%field_conv(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12694,& 'frame/module_domain.f: Failed to allocate grid%field_conv(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ru_tendf_stoch'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ru_tendf_stoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12703,& 'frame/module_domain.f: Failed to allocate grid%ru_tendf_stoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ru_tendf_stoch=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ru_tendf_stoch' grid%tail_statevars%DataName = 'RU_TENDF_STOCH' grid%tail_statevars%Description = 'stochastic forcing, U ' grid%tail_statevars%Units = 'm/s^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'X' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ru_tendf_stoch grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ru_tendf_stoch(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12753,& 'frame/module_domain.f: Failed to allocate grid%ru_tendf_stoch(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rv_tendf_stoch'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rv_tendf_stoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12762,& 'frame/module_domain.f: Failed to allocate grid%rv_tendf_stoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rv_tendf_stoch=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rv_tendf_stoch' grid%tail_statevars%DataName = 'RV_TENDF_STOCH' grid%tail_statevars%Description = 'stochastic forcing, V ' grid%tail_statevars%Units = 'm/s^2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Y' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rv_tendf_stoch grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( jde, jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rv_tendf_stoch(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12812,& 'frame/module_domain.f: Failed to allocate grid%rv_tendf_stoch(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rt_tendf_stoch'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rt_tendf_stoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12821,& 'frame/module_domain.f: Failed to allocate grid%rt_tendf_stoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rt_tendf_stoch=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rt_tendf_stoch' grid%tail_statevars%DataName = 'RT_TENDF_STOCH' grid%tail_statevars%Description = 'stochastic forcing, T ' grid%tail_statevars%Units = 'K/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rt_tendf_stoch grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rt_tendf_stoch(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12871,& 'frame/module_domain.f: Failed to allocate grid%rt_tendf_stoch(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_pert'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rand_pert(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12880,& 'frame/module_domain.f: Failed to allocate grid%rand_pert(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_pert=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_pert' grid%tail_statevars%DataName = 'RAND_PERT' grid%tail_statevars%Description = 'randomn field ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_pert grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rand_pert(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12930,& 'frame/module_domain.f: Failed to allocate grid%rand_pert(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pattern_spp_conv'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pattern_spp_conv(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12939,& 'frame/module_domain.f: Failed to allocate grid%pattern_spp_conv(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pattern_spp_conv=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pattern_spp_conv' grid%tail_statevars%DataName = 'PATTERN_SPP_CONV' grid%tail_statevars%Description = 'pattern sppt conv' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%pattern_spp_conv grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%pattern_spp_conv(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12989,& 'frame/module_domain.f: Failed to allocate grid%pattern_spp_conv(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pattern_spp_pbl'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pattern_spp_pbl(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12998,& 'frame/module_domain.f: Failed to allocate grid%pattern_spp_pbl(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pattern_spp_pbl=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pattern_spp_pbl' grid%tail_statevars%DataName = 'PATTERN_SPP_PBL' grid%tail_statevars%Description = 'pattern sppt pbl' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%pattern_spp_pbl grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%pattern_spp_pbl(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13048,& 'frame/module_domain.f: Failed to allocate grid%pattern_spp_pbl(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pattern_spp_lsm'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pattern_spp_lsm(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13057,& 'frame/module_domain.f: Failed to allocate grid%pattern_spp_lsm(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pattern_spp_lsm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pattern_spp_lsm' grid%tail_statevars%DataName = 'PATTERN_SPP_LSM' grid%tail_statevars%Description = 'pattern sppt lsm' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%pattern_spp_lsm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%pattern_spp_lsm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13107,& 'frame/module_domain.f: Failed to allocate grid%pattern_spp_lsm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rstoch'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rstoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13116,& 'frame/module_domain.f: Failed to allocate grid%rstoch(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rstoch=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rstoch' grid%tail_statevars%DataName = 'RSTOCH' grid%tail_statevars%Description = 'randomn field for SPPT' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rstoch grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'num_stoch_levels' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rstoch(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13166,& 'frame/module_domain.f: Failed to allocate grid%rstoch(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_real').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rand_real(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13175,& 'frame/module_domain.f: Failed to allocate grid%rand_real(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_real=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_real' grid%tail_statevars%DataName = 'RAND_REAL' grid%tail_statevars%Description = 'array for FFTs' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'XYZ' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_real grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( jde, jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels_stag' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rand_real(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13225,& 'frame/module_domain.f: Failed to allocate grid%rand_real(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_imag').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rand_imag(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13234,& 'frame/module_domain.f: Failed to allocate grid%rand_imag(sm31:em31,1:model_config_rec%num_stoch_levels,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_imag=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_imag' grid%tail_statevars%DataName = 'RAND_IMAG' grid%tail_statevars%Description = 'array for FFTs' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'XYZ' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_imag grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( jde, jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels_stag' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rand_imag(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13284,& 'frame/module_domain.f: Failed to allocate grid%rand_imag(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spstreamforcc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spstreamforcc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13293,& 'frame/module_domain.f: Failed to allocate grid%spstreamforcc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spstreamforcc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spstreamforcc' grid%tail_statevars%DataName = 'SPSTREAMFORCC' grid%tail_statevars%Description = 'real spect. coeff. of stoch. streamfunction perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spstreamforcc grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spstreamforcc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13343,& 'frame/module_domain.f: Failed to allocate grid%spstreamforcc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spstreamforcs').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spstreamforcs(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13352,& 'frame/module_domain.f: Failed to allocate grid%spstreamforcs(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spstreamforcs=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spstreamforcs' grid%tail_statevars%DataName = 'SPSTREAMFORCS' grid%tail_statevars%Description = 'imag. spect. coeff. of stoch. streamfunction perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spstreamforcs grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spstreamforcs(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13402,& 'frame/module_domain.f: Failed to allocate grid%spstreamforcs(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spstream_amp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spstream_amp(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13411,& 'frame/module_domain.f: Failed to allocate grid%spstream_amp(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spstream_amp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spstream_amp' grid%tail_statevars%DataName = 'SPSTREAM_AMP' grid%tail_statevars%Description = 'amplitude of stoch. streamfunction perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spstream_amp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spstream_amp(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13461,& 'frame/module_domain.f: Failed to allocate grid%spstream_amp(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sptforcc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sptforcc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13470,& 'frame/module_domain.f: Failed to allocate grid%sptforcc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sptforcc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sptforcc' grid%tail_statevars%DataName = 'SPTFORCC' grid%tail_statevars%Description = 'real spect. coeff. of stoch. temperature perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sptforcc grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sptforcc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13520,& 'frame/module_domain.f: Failed to allocate grid%sptforcc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sptforcs').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sptforcs(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13529,& 'frame/module_domain.f: Failed to allocate grid%sptforcs(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sptforcs=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sptforcs' grid%tail_statevars%DataName = 'SPTFORCS' grid%tail_statevars%Description = 'imag. spect. coeff. of stoch. temperature perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sptforcs grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sptforcs(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13579,& 'frame/module_domain.f: Failed to allocate grid%sptforcs(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spt_amp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spt_amp(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13588,& 'frame/module_domain.f: Failed to allocate grid%spt_amp(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spt_amp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spt_amp' grid%tail_statevars%DataName = 'SPT_AMP' grid%tail_statevars%Description = 'amplitude of stoch. temperature perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spt_amp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spt_amp(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13638,& 'frame/module_domain.f: Failed to allocate grid%spt_amp(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13647,& 'frame/module_domain.f: Failed to allocate grid%spforcc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcc' grid%tail_statevars%DataName = 'SPFORCC' grid%tail_statevars%Description = 'real spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcc grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13697,& 'frame/module_domain.f: Failed to allocate grid%spforcc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcs').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcs(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13706,& 'frame/module_domain.f: Failed to allocate grid%spforcs(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcs=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcs' grid%tail_statevars%DataName = 'SPFORCS' grid%tail_statevars%Description = 'imag. spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcs grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcs(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13756,& 'frame/module_domain.f: Failed to allocate grid%spforcs(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sp_amp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sp_amp(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13765,& 'frame/module_domain.f: Failed to allocate grid%sp_amp(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sp_amp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sp_amp' grid%tail_statevars%DataName = 'SP_AMP' grid%tail_statevars%Description = 'amplitude of random perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sp_amp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sp_amp(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13815,& 'frame/module_domain.f: Failed to allocate grid%sp_amp(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcc2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcc2(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13824,& 'frame/module_domain.f: Failed to allocate grid%spforcc2(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcc2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcc2' grid%tail_statevars%DataName = 'SPFORCC2' grid%tail_statevars%Description = 'real spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcc2 grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcc2(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13874,& 'frame/module_domain.f: Failed to allocate grid%spforcc2(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcs2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcs2(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13883,& 'frame/module_domain.f: Failed to allocate grid%spforcs2(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcs2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcs2' grid%tail_statevars%DataName = 'SPFORCS2' grid%tail_statevars%Description = 'imag. spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcs2 grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcs2(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13933,& 'frame/module_domain.f: Failed to allocate grid%spforcs2(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sp_amp2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sp_amp2(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13942,& 'frame/module_domain.f: Failed to allocate grid%sp_amp2(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sp_amp2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sp_amp2' grid%tail_statevars%DataName = 'SP_AMP2' grid%tail_statevars%Description = 'amplitude of random perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sp_amp2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sp_amp2(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13992,& 'frame/module_domain.f: Failed to allocate grid%sp_amp2(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcc3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcc3(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14001,& 'frame/module_domain.f: Failed to allocate grid%spforcc3(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcc3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcc3' grid%tail_statevars%DataName = 'SPFORCC3' grid%tail_statevars%Description = 'real spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcc3 grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcc3(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14051,& 'frame/module_domain.f: Failed to allocate grid%spforcc3(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcs3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcs3(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14060,& 'frame/module_domain.f: Failed to allocate grid%spforcs3(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcs3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcs3' grid%tail_statevars%DataName = 'SPFORCS3' grid%tail_statevars%Description = 'imag. spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcs3 grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcs3(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14110,& 'frame/module_domain.f: Failed to allocate grid%spforcs3(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sp_amp3').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sp_amp3(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14119,& 'frame/module_domain.f: Failed to allocate grid%sp_amp3(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sp_amp3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sp_amp3' grid%tail_statevars%DataName = 'SP_AMP3' grid%tail_statevars%Description = 'amplitude of random perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sp_amp3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sp_amp3(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14169,& 'frame/module_domain.f: Failed to allocate grid%sp_amp3(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcc4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcc4(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14178,& 'frame/module_domain.f: Failed to allocate grid%spforcc4(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcc4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcc4' grid%tail_statevars%DataName = 'SPFORCC4' grid%tail_statevars%Description = 'real spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcc4 grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcc4(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14228,& 'frame/module_domain.f: Failed to allocate grid%spforcc4(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcs4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcs4(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14237,& 'frame/module_domain.f: Failed to allocate grid%spforcs4(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcs4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcs4' grid%tail_statevars%DataName = 'SPFORCS4' grid%tail_statevars%Description = 'imag. spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcs4 grid%tail_statevars%streams(1) = 33554433 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcs4(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14287,& 'frame/module_domain.f: Failed to allocate grid%spforcs4(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sp_amp4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sp_amp4(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14296,& 'frame/module_domain.f: Failed to allocate grid%sp_amp4(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sp_amp4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sp_amp4' grid%tail_statevars%DataName = 'SP_AMP4' grid%tail_statevars%Description = 'amplitude of random perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sp_amp4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sp_amp4(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14346,& 'frame/module_domain.f: Failed to allocate grid%sp_amp4(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcc5').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcc5(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14355,& 'frame/module_domain.f: Failed to allocate grid%spforcc5(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcc5=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcc5' grid%tail_statevars%DataName = 'SPFORCC5' grid%tail_statevars%Description = 'real spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcc5 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcc5(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14405,& 'frame/module_domain.f: Failed to allocate grid%spforcc5(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spforcs5').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spforcs5(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14414,& 'frame/module_domain.f: Failed to allocate grid%spforcs5(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spforcs5=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spforcs5' grid%tail_statevars%DataName = 'SPFORCS5' grid%tail_statevars%Description = 'imag. spect. coeff. of randomn perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spforcs5 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spforcs5(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14464,& 'frame/module_domain.f: Failed to allocate grid%spforcs5(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sp_amp5').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sp_amp5(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14473,& 'frame/module_domain.f: Failed to allocate grid%sp_amp5(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sp_amp5=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sp_amp5' grid%tail_statevars%DataName = 'SP_AMP5' grid%tail_statevars%Description = 'amplitude of random perturbation field' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sp_amp5 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sp_amp5(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14523,& 'frame/module_domain.f: Failed to allocate grid%sp_amp5(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spptforcc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spptforcc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14532,& 'frame/module_domain.f: Failed to allocate grid%spptforcc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spptforcc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spptforcc' grid%tail_statevars%DataName = 'SPPTFORCC' grid%tail_statevars%Description = 'real spect. coeff. of randomn perturbation field in SPPT' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spptforcc grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spptforcc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14582,& 'frame/module_domain.f: Failed to allocate grid%spptforcc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'spptforcs').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%spptforcs(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14591,& 'frame/module_domain.f: Failed to allocate grid%spptforcs(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%spptforcs=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'spptforcs' grid%tail_statevars%DataName = 'SPPTFORCS' grid%tail_statevars%Description = 'imag. spect. coeff. of randomn perturbation field in SPPT' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = 'XY' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%spptforcs grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = jde grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( ide, ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( jde, jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'south_north_stag' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%spptforcs(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14641,& 'frame/module_domain.f: Failed to allocate grid%spptforcs(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sppt_amp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sppt_amp(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14650,& 'frame/module_domain.f: Failed to allocate grid%sppt_amp(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sppt_amp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sppt_amp' grid%tail_statevars%DataName = 'SPPT_AMP' grid%tail_statevars%Description = 'amplitude of random perturbation field in SPPT' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%sppt_amp grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%sppt_amp(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14700,& 'frame/module_domain.f: Failed to allocate grid%sppt_amp(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'vertampt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%vertampt(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14709,& 'frame/module_domain.f: Failed to allocate grid%vertampt(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vertampt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vertampt' grid%tail_statevars%DataName = 'VERTAMPT' grid%tail_statevars%Description = 'vert. amplitude of stoch. temperature perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%vertampt grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%vertampt(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14757,& 'frame/module_domain.f: Failed to allocate grid%vertampt(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'vertampuv').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%vertampuv(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14766,& 'frame/module_domain.f: Failed to allocate grid%vertampuv(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%vertampuv=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'vertampuv' grid%tail_statevars%DataName = 'VERTAMPUV' grid%tail_statevars%Description = 'vert. amplitude of stoch. u,v perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_1d => grid%vertampuv grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%vertampuv(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14814,& 'frame/module_domain.f: Failed to allocate grid%vertampuv(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'iseedarr_sppt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%iseedarr_sppt(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14823,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_sppt(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%iseedarr_sppt=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'iseedarr_sppt' grid%tail_statevars%DataName = 'ISEEDARR_SPPT' grid%tail_statevars%Description = 'Array to hold seed for restart, SPPT' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_1d => grid%iseedarr_sppt grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%iseedarr_sppt(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14871,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_sppt(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'iseedarr_skebs').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%iseedarr_skebs(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14880,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_skebs(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%iseedarr_skebs=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'iseedarr_skebs' grid%tail_statevars%DataName = 'ISEEDARR_SKEBS' grid%tail_statevars%Description = 'Array to hold seed for restart, SKEBS' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_1d => grid%iseedarr_skebs grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%iseedarr_skebs(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14928,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_skebs(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'iseedarr_rand_pert').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%iseedarr_rand_pert(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14937,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_rand_pert(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%iseedarr_rand_pert=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'iseedarr_rand_pert' grid%tail_statevars%DataName = 'ISEEDARR_RAND_PERTURB' grid%tail_statevars%Description = 'Array to hold seed for restart, RAND_PERT' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_1d => grid%iseedarr_rand_pert grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%iseedarr_rand_pert(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14985,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_rand_pert(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'iseedarr_spp_conv').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%iseedarr_spp_conv(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14994,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_spp_conv(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%iseedarr_spp_conv=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'iseedarr_spp_conv' grid%tail_statevars%DataName = 'ISEEDARRAY_SPP_CONV' grid%tail_statevars%Description = 'Array to hold seed for restart, RAND_PERT2' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_1d => grid%iseedarr_spp_conv grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%iseedarr_spp_conv(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15042,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_spp_conv(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'iseedarr_spp_pbl').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%iseedarr_spp_pbl(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15051,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_spp_pbl(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%iseedarr_spp_pbl=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'iseedarr_spp_pbl' grid%tail_statevars%DataName = 'ISEEDARRAY_SPP_PBL' grid%tail_statevars%Description = 'Array to hold seed for restart, RAND_PERT3' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_1d => grid%iseedarr_spp_pbl grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%iseedarr_spp_pbl(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15099,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_spp_pbl(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'iseedarr_spp_lsm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em32)-(sm32)+1))) * 4 ALLOCATE(grid%iseedarr_spp_lsm(sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15108,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_spp_lsm(sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%iseedarr_spp_lsm=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'iseedarr_spp_lsm' grid%tail_statevars%DataName = 'ISEEDARRAY_SPP_LSM' grid%tail_statevars%Description = 'Array to hold seed for restart, RAND_PERT4' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'Z' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 1 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_1d => grid%iseedarr_spp_lsm grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = kds grid%tail_statevars%ed1 = (kde-1) grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = 1 grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = kms grid%tail_statevars%em1 = kme grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = 1 grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = kps grid%tail_statevars%ep1 = MIN( (kde-1), kpe ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = 'bottom_top' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%iseedarr_spp_lsm(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15156,& 'frame/module_domain.f: Failed to allocate grid%iseedarr_spp_lsm(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_real_xxx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31x)-(sm31x)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33x)-(sm33x)+1))) * 4 ALLOCATE(grid%rand_real_xxx(sm31x:em31x,1:model_config_rec%num_stoch_levels,sm33x:em33x),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15165,& 'frame/module_domain.f: Failed to allocate grid%rand_real_xxx(sm31x:em31x,1:model_config_rec%num_stoch_levels,sm33x:em33x). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_real_xxx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_real_xxx' grid%tail_statevars%DataName = 'RAND_REAL_XXX' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = 'X' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'XYZ' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_real_xxx grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = imsx grid%tail_statevars%em1 = imex grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jmsx grid%tail_statevars%em3 = jmex grid%tail_statevars%sp1 = ipsx grid%tail_statevars%ep1 = MIN( ide, ipex ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jpsx grid%tail_statevars%ep3 = MIN( jde, jpex ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels_stag' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rand_real_xxx(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15215,& 'frame/module_domain.f: Failed to allocate grid%rand_real_xxx(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_real_yyy').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31y)-(sm31y)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33y)-(sm33y)+1))) * 4 ALLOCATE(grid%rand_real_yyy(sm31y:em31y,1:model_config_rec%num_stoch_levels,sm33y:em33y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15224,& 'frame/module_domain.f: Failed to allocate grid%rand_real_yyy(sm31y:em31y,1:model_config_rec%num_stoch_levels,sm33y:em33y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_real_yyy=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_real_yyy' grid%tail_statevars%DataName = 'RAND_REAL_YYY' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = 'Y' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'XYZ' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_real_yyy grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = imsy grid%tail_statevars%em1 = imey grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jmsy grid%tail_statevars%em3 = jmey grid%tail_statevars%sp1 = ipsy grid%tail_statevars%ep1 = MIN( ide, ipey ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jpsy grid%tail_statevars%ep3 = MIN( jde, jpey ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels_stag' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rand_real_yyy(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15274,& 'frame/module_domain.f: Failed to allocate grid%rand_real_yyy(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_imag_xxx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31x)-(sm31x)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33x)-(sm33x)+1))) * 4 ALLOCATE(grid%rand_imag_xxx(sm31x:em31x,1:model_config_rec%num_stoch_levels,sm33x:em33x),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15283,& 'frame/module_domain.f: Failed to allocate grid%rand_imag_xxx(sm31x:em31x,1:model_config_rec%num_stoch_levels,sm33x:em33x). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_imag_xxx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_imag_xxx' grid%tail_statevars%DataName = 'RAND_IMAG_XXX' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = 'X' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'XYZ' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_imag_xxx grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = imsx grid%tail_statevars%em1 = imex grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jmsx grid%tail_statevars%em3 = jmex grid%tail_statevars%sp1 = ipsx grid%tail_statevars%ep1 = MIN( ide, ipex ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jpsx grid%tail_statevars%ep3 = MIN( jde, jpex ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels_stag' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rand_imag_xxx(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15333,& 'frame/module_domain.f: Failed to allocate grid%rand_imag_xxx(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rand_imag_yyy').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31y)-(sm31y)+1))*(((model_config_rec%num_stoch_levels)-(1)+1))*(((em33y)-(sm33y)+1))) * 4 ALLOCATE(grid%rand_imag_yyy(sm31y:em31y,1:model_config_rec%num_stoch_levels,sm33y:em33y),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15342,& 'frame/module_domain.f: Failed to allocate grid%rand_imag_yyy(sm31y:em31y,1:model_config_rec%num_stoch_levels,sm33y:em33y). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rand_imag_yyy=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rand_imag_yyy' grid%tail_statevars%DataName = 'RAND_IMAG_YYY' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = 'Y' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'XYZ' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rand_imag_yyy grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = ide grid%tail_statevars%sd2 = 1 grid%tail_statevars%ed2 = config_flags%num_stoch_levels grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = jde grid%tail_statevars%sm1 = imsy grid%tail_statevars%em1 = imey grid%tail_statevars%sm2 = 1 grid%tail_statevars%em2 = config_flags%num_stoch_levels grid%tail_statevars%sm3 = jmsy grid%tail_statevars%em3 = jmey grid%tail_statevars%sp1 = ipsy grid%tail_statevars%ep1 = MIN( ide, ipey ) grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = config_flags%num_stoch_levels grid%tail_statevars%sp3 = jpsy grid%tail_statevars%ep3 = MIN( jde, jpey ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east_stag' grid%tail_statevars%dimname2 = 'num_stoch_levels_stag' grid%tail_statevars%dimname3 = 'south_north_stag' ENDIF ELSE ALLOCATE(grid%rand_imag_yyy(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15392,& 'frame/module_domain.f: Failed to allocate grid%rand_imag_yyy(1,1,1). ') endif ENDIF IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_t' grid%tail_statevars%DataName = 'ALPH_TAU ' grid%tail_statevars%Description = 'autoregressive coeff. for theta perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_t grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_t=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_psi' grid%tail_statevars%DataName = 'ALPH_PSI ' grid%tail_statevars%Description = 'autoregressive coeff. for psi perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_psi grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_psi=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_sppt' grid%tail_statevars%DataName = 'ALPH_SPPT' grid%tail_statevars%Description = 'autoregressive coeff. for tendf perturb.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_sppt grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_sppt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_rand' grid%tail_statevars%DataName = 'ALPH_RAND ' grid%tail_statevars%Description = 'autoregressive coeff. for generic rand. pert.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_rand grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_rand=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_rand2' grid%tail_statevars%DataName = 'ALPH_RAND2' grid%tail_statevars%Description = 'autoregressive coeff. for generic rand. pert.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_rand2 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_rand2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_rand3' grid%tail_statevars%DataName = 'ALPH_RAND3' grid%tail_statevars%Description = 'autoregressive coeff. for generic rand. pert.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_rand3 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_rand3=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'alph_rand4' grid%tail_statevars%DataName = 'ALPH_RAND4' grid%tail_statevars%Description = 'autoregressive coeff. for generic rand. pert.' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%alph_rand4 grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%alph_rand4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%VarName = 'did_stoch' grid%tail_statevars%DataName = 'DID_STOCH' grid%tail_statevars%Description = 'Logical to tell us that we already did the initialization for dom 1' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'l' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%lfield_0d => grid%did_stoch grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%did_stoch=.FALSE. IF ( setinitval .EQ. 3 ) grid%nens=0 IF ( setinitval .EQ. 3 ) grid%skebs=0 IF ( setinitval .EQ. 3 ) grid%stoch_force_opt=0 IF ( setinitval .EQ. 3 ) grid%skebs_vertstruc=0 IF ( setinitval .EQ. 3 ) grid%stoch_vertstruc_opt=0 IF ( setinitval .EQ. 3 ) grid%tot_backscat_psi=initial_data_value IF ( setinitval .EQ. 3 ) grid%tot_backscat_t=initial_data_value IF ( setinitval .EQ. 3 ) grid%ztau_psi=initial_data_value IF ( setinitval .EQ. 3 ) grid%ztau_t=initial_data_value IF ( setinitval .EQ. 3 ) grid%rexponent_psi=initial_data_value IF ( setinitval .EQ. 3 ) grid%rexponent_t=initial_data_value IF ( setinitval .EQ. 3 ) grid%zsigma2_eps=initial_data_value IF ( setinitval .EQ. 3 ) grid%zsigma2_eta=initial_data_value IF ( setinitval .EQ. 3 ) grid%kminforc=0 IF ( setinitval .EQ. 3 ) grid%lminforc=0 IF ( setinitval .EQ. 3 ) grid%kminforct=0 IF ( setinitval .EQ. 3 ) grid%lminforct=0 IF ( setinitval .EQ. 3 ) grid%kmaxforc=0 IF ( setinitval .EQ. 3 ) grid%lmaxforc=0 IF ( setinitval .EQ. 3 ) grid%kmaxforct=0 IF ( setinitval .EQ. 3 ) grid%lmaxforct=0 IF ( setinitval .EQ. 3 ) grid%iseed_skebs=0 IF ( setinitval .EQ. 3 ) grid%kmaxforch=0 IF ( setinitval .EQ. 3 ) grid%lmaxforch=0 IF ( setinitval .EQ. 3 ) grid%kmaxforcth=0 IF ( setinitval .EQ. 3 ) grid%lmaxforcth=0 IF ( setinitval .EQ. 3 ) grid%sppt=0 IF ( setinitval .EQ. 3 ) grid%gridpt_stddev_sppt=initial_data_value IF ( setinitval .EQ. 3 ) grid%stddev_cutoff_sppt=initial_data_value IF ( setinitval .EQ. 3 ) grid%lengthscale_sppt=initial_data_value IF ( setinitval .EQ. 3 ) grid%timescale_sppt=initial_data_value IF ( setinitval .EQ. 3 ) grid%sppt_vertstruc=0 IF ( setinitval .EQ. 3 ) grid%iseed_sppt=0 IF ( setinitval .EQ. 3 ) grid%rand_perturb=0 IF ( setinitval .EQ. 3 ) grid%gridpt_stddev_rand_pert=initial_data_value IF ( setinitval .EQ. 3 ) grid%stddev_cutoff_rand_pert=initial_data_value IF ( setinitval .EQ. 3 ) grid%lengthscale_rand_pert=initial_data_value IF ( setinitval .EQ. 3 ) grid%timescale_rand_pert=initial_data_value IF ( setinitval .EQ. 3 ) grid%rand_pert_vertstruc=0 IF ( setinitval .EQ. 3 ) grid%iseed_rand_pert=0 IF ( setinitval .EQ. 3 ) grid%spp=0 IF ( setinitval .EQ. 3 ) grid%hrrr_cycling=.FALSE. IF ( setinitval .EQ. 3 ) grid%spp_conv=0 IF ( setinitval .EQ. 3 ) grid%gridpt_stddev_spp_conv=initial_data_value IF ( setinitval .EQ. 3 ) grid%stddev_cutoff_spp_conv=initial_data_value IF ( setinitval .EQ. 3 ) grid%lengthscale_spp_conv=initial_data_value IF ( setinitval .EQ. 3 ) grid%timescale_spp_conv=initial_data_value IF ( setinitval .EQ. 3 ) grid%vertstruc_spp_conv=0 IF ( setinitval .EQ. 3 ) grid%iseed_spp_conv=0 IF ( setinitval .EQ. 3 ) grid%spp_pbl=0 IF ( setinitval .EQ. 3 ) grid%gridpt_stddev_spp_pbl=initial_data_value IF ( setinitval .EQ. 3 ) grid%stddev_cutoff_spp_pbl=initial_data_value IF ( setinitval .EQ. 3 ) grid%lengthscale_spp_pbl=initial_data_value IF ( setinitval .EQ. 3 ) grid%timescale_spp_pbl=initial_data_value IF ( setinitval .EQ. 3 ) grid%vertstruc_spp_pbl=0 IF ( setinitval .EQ. 3 ) grid%iseed_spp_pbl=0 IF ( setinitval .EQ. 3 ) grid%spp_lsm=0 IF ( setinitval .EQ. 3 ) grid%gridpt_stddev_spp_lsm=initial_data_value IF ( setinitval .EQ. 3 ) grid%stddev_cutoff_spp_lsm=initial_data_value IF ( setinitval .EQ. 3 ) grid%lengthscale_spp_lsm=initial_data_value IF ( setinitval .EQ. 3 ) grid%timescale_spp_lsm=initial_data_value IF ( setinitval .EQ. 3 ) grid%vertstruc_spp_lsm=0 IF ( setinitval .EQ. 3 ) grid%iseed_spp_lsm=0 IF ( setinitval .EQ. 3 ) grid%skebs_on=0 IF ( setinitval .EQ. 3 ) grid%sppt_on=0 IF ( setinitval .EQ. 3 ) grid%spp_on=0 IF ( setinitval .EQ. 3 ) grid%rand_perturb_on=0 IF ( setinitval .EQ. 3 ) grid%num_stoch_levels=0 IF(okay_to_alloc.AND.in_use_for_config(id,'nba_mij'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_nba_mij)) * 4 ALLOCATE(grid%nba_mij(sm31:em31,sm32:em32,sm33:em33,num_nba_mij),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15621,& 'frame/module_domain.f: Failed to allocate grid%nba_mij(sm31:em31,sm32:em32,sm33:em33,num_nba_mij). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nba_mij=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nba_mij' grid%tail_statevars%DataName = 'NBA_MIJ' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%nba_mij grid%tail_statevars%num_table => nba_mij_num_table grid%tail_statevars%index_table => nba_mij_index_table grid%tail_statevars%boundary_table => nba_mij_boundary_table grid%tail_statevars%dname_table => nba_mij_dname_table grid%tail_statevars%desc_table => nba_mij_desc_table grid%tail_statevars%units_table => nba_mij_units_table grid%tail_statevars%streams_table => nba_mij_streams_table grid%tail_statevars%streams(1) = 1 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nba_mij(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15678,& 'frame/module_domain.f: Failed to allocate grid%nba_mij(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'nba_rij'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_nba_rij)) * 4 ALLOCATE(grid%nba_rij(sm31:em31,sm32:em32,sm33:em33,num_nba_rij),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15687,& 'frame/module_domain.f: Failed to allocate grid%nba_rij(sm31:em31,sm32:em32,sm33:em33,num_nba_rij). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%nba_rij=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'nba_rij' grid%tail_statevars%DataName = 'NBA_RIJ' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .TRUE. grid%tail_statevars%rfield_4d => grid%nba_rij grid%tail_statevars%num_table => nba_rij_num_table grid%tail_statevars%index_table => nba_rij_index_table grid%tail_statevars%boundary_table => nba_rij_boundary_table grid%tail_statevars%dname_table => nba_rij_dname_table grid%tail_statevars%desc_table => nba_rij_desc_table grid%tail_statevars%units_table => nba_rij_units_table grid%tail_statevars%streams_table => nba_rij_streams_table grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%nba_rij(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15744,& 'frame/module_domain.f: Failed to allocate grid%nba_rij(1,1,1,1). ') endif ENDIF IF ( setinitval .EQ. 3 ) grid%sfs_opt=0 IF ( setinitval .EQ. 3 ) grid%m_opt=0 IF(okay_to_alloc.AND.in_use_for_config(id,'tauresx2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauresx2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15755,& 'frame/module_domain.f: Failed to allocate grid%tauresx2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauresx2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauresx2d' grid%tail_statevars%DataName = 'TAURESX2D' grid%tail_statevars%Description = 'X-COMP OF RESIDUAL STRESS' grid%tail_statevars%Units = 'm2 s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%tauresx2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%tauresx2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15805,& 'frame/module_domain.f: Failed to allocate grid%tauresx2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tauresy2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tauresy2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15814,& 'frame/module_domain.f: Failed to allocate grid%tauresy2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tauresy2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tauresy2d' grid%tail_statevars%DataName = 'TAURESY2D' grid%tail_statevars%Description = 'Y-COMP OF RESIDUAL STRESS' grid%tail_statevars%Units = 'm2 s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%tauresy2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%tauresy2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15864,& 'frame/module_domain.f: Failed to allocate grid%tauresy2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tpert2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tpert2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15873,& 'frame/module_domain.f: Failed to allocate grid%tpert2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tpert2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tpert2d' grid%tail_statevars%DataName = 'TPERT2D' grid%tail_statevars%Description = 'Convective temperature excess ' grid%tail_statevars%Units = 'K' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%tpert2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%tpert2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15923,& 'frame/module_domain.f: Failed to allocate grid%tpert2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qpert2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qpert2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15932,& 'frame/module_domain.f: Failed to allocate grid%qpert2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qpert2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qpert2d' grid%tail_statevars%DataName = 'QPERT2D' grid%tail_statevars%Description = 'Convective humidity excess ' grid%tail_statevars%Units = 'kg/kg' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%qpert2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%qpert2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15982,& 'frame/module_domain.f: Failed to allocate grid%qpert2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wpert2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wpert2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15991,& 'frame/module_domain.f: Failed to allocate grid%wpert2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wpert2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wpert2d' grid%tail_statevars%DataName = 'WPERT2D' grid%tail_statevars%Description = 'Turbulent velocity excess ' grid%tail_statevars%Units = 'm/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%wpert2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%wpert2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16041,& 'frame/module_domain.f: Failed to allocate grid%wpert2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'turbtype3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%turbtype3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16050,& 'frame/module_domain.f: Failed to allocate grid%turbtype3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%turbtype3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'turbtype3d' grid%tail_statevars%DataName = 'TURBTYPE3D' grid%tail_statevars%Description = 'Turbulent interface types' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%turbtype3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%turbtype3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16100,& 'frame/module_domain.f: Failed to allocate grid%turbtype3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'smaw3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%smaw3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16109,& 'frame/module_domain.f: Failed to allocate grid%smaw3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%smaw3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'smaw3d' grid%tail_statevars%DataName = 'SMAW3D' grid%tail_statevars%Description = 'Normalized Galperin instability function for momentum' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%smaw3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%smaw3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16159,& 'frame/module_domain.f: Failed to allocate grid%smaw3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wsedl3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wsedl3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16168,& 'frame/module_domain.f: Failed to allocate grid%wsedl3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wsedl3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wsedl3d' grid%tail_statevars%DataName = 'WSEDL3D' grid%tail_statevars%Description = 'Sedimentation velocity of stratiform liquid cloud droplet' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%wsedl3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%wsedl3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16218,& 'frame/module_domain.f: Failed to allocate grid%wsedl3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rliq').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rliq(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16227,& 'frame/module_domain.f: Failed to allocate grid%rliq(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rliq=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rliq' grid%tail_statevars%DataName = 'RLIQ' grid%tail_statevars%Description = 'vertically-integrated reserved cloud condensate' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%rliq grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%rliq(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16277,& 'frame/module_domain.f: Failed to allocate grid%rliq(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dlf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dlf(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16286,& 'frame/module_domain.f: Failed to allocate grid%dlf(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dlf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dlf' grid%tail_statevars%DataName = 'DLF' grid%tail_statevars%Description = 'detraining cloud water tendency from convection' grid%tail_statevars%Units = '~?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%dlf grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%dlf(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16336,& 'frame/module_domain.f: Failed to allocate grid%dlf(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'precz').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%precz(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16345,& 'frame/module_domain.f: Failed to allocate grid%precz(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%precz=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'precz' grid%tail_statevars%DataName = 'PRECZ' grid%tail_statevars%Description = 'total precipitation from ZM convection' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%precz grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%precz(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16395,& 'frame/module_domain.f: Failed to allocate grid%precz(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmdt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmdt(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16404,& 'frame/module_domain.f: Failed to allocate grid%zmdt(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmdt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmdt' grid%tail_statevars%DataName = 'ZMDT' grid%tail_statevars%Description = 'temp. tendency - Zhang-McFarlane moist convection' grid%tail_statevars%Units = 'K s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmdt grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmdt(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16454,& 'frame/module_domain.f: Failed to allocate grid%zmdt(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmdq').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmdq(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16463,& 'frame/module_domain.f: Failed to allocate grid%zmdq(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmdq=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmdq' grid%tail_statevars%DataName = 'ZMDQ' grid%tail_statevars%Description = 'specific humidity tendency - Zhang-McFarlane moist convection' grid%tail_statevars%Units = 'kg kg_wet-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmdq grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmdq(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16513,& 'frame/module_domain.f: Failed to allocate grid%zmdq(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmdice').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmdice(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16522,& 'frame/module_domain.f: Failed to allocate grid%zmdice(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmdice=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmdice' grid%tail_statevars%DataName = 'ZMDICE' grid%tail_statevars%Description = 'cloud ice tendency - Zhang-McFarlane moist convection' grid%tail_statevars%Units = 'kg kg_wet-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmdice grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmdice(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16572,& 'frame/module_domain.f: Failed to allocate grid%zmdice(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmdliq').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmdliq(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16581,& 'frame/module_domain.f: Failed to allocate grid%zmdliq(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmdliq=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmdliq' grid%tail_statevars%DataName = 'ZMDLIQ' grid%tail_statevars%Description = 'cloud liquid tendency - Zhang-McFarlane moist convection' grid%tail_statevars%Units = 'kg kg_wet-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmdliq grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmdliq(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16631,& 'frame/module_domain.f: Failed to allocate grid%zmdliq(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'evaptzm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%evaptzm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16640,& 'frame/module_domain.f: Failed to allocate grid%evaptzm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%evaptzm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'evaptzm' grid%tail_statevars%DataName = 'EVAPTZM' grid%tail_statevars%Description = 'T tendency - evaporation/snow prod from Zhang convection' grid%tail_statevars%Units = 'K s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%evaptzm grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%evaptzm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16690,& 'frame/module_domain.f: Failed to allocate grid%evaptzm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fzsntzm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%fzsntzm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16699,& 'frame/module_domain.f: Failed to allocate grid%fzsntzm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fzsntzm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fzsntzm' grid%tail_statevars%DataName = 'FZSNTZM' grid%tail_statevars%Description = 'T tendency - rain to snow conversion from Zhang convection' grid%tail_statevars%Units = 'K s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%fzsntzm grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%fzsntzm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16749,& 'frame/module_domain.f: Failed to allocate grid%fzsntzm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'evsntzm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%evsntzm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16758,& 'frame/module_domain.f: Failed to allocate grid%evsntzm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%evsntzm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'evsntzm' grid%tail_statevars%DataName = 'EVSNTZM' grid%tail_statevars%Description = 'T tendency - snow to rain prod from Zhang convection' grid%tail_statevars%Units = 'K s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%evsntzm grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%evsntzm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16808,& 'frame/module_domain.f: Failed to allocate grid%evsntzm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'evapqzm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%evapqzm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16817,& 'frame/module_domain.f: Failed to allocate grid%evapqzm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%evapqzm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'evapqzm' grid%tail_statevars%DataName = 'EVAPQZM' grid%tail_statevars%Description = 'Q tendency - evaporation from Zhang-McFarlane moist convection' grid%tail_statevars%Units = 'kg kg_wet-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%evapqzm grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%evapqzm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16867,& 'frame/module_domain.f: Failed to allocate grid%evapqzm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmflxprc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmflxprc(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16876,& 'frame/module_domain.f: Failed to allocate grid%zmflxprc(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmflxprc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmflxprc' grid%tail_statevars%DataName = 'ZMFLXPRC' grid%tail_statevars%Description = 'flux of precipitation from ZM convection' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmflxprc grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmflxprc(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16926,& 'frame/module_domain.f: Failed to allocate grid%zmflxprc(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmflxsnw').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmflxsnw(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16935,& 'frame/module_domain.f: Failed to allocate grid%zmflxsnw(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmflxsnw=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmflxsnw' grid%tail_statevars%DataName = 'ZMFLXSNW' grid%tail_statevars%Description = 'flux of snow from ZM convection' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmflxsnw grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmflxsnw(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16985,& 'frame/module_domain.f: Failed to allocate grid%zmflxsnw(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmntprpd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmntprpd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16994,& 'frame/module_domain.f: Failed to allocate grid%zmntprpd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmntprpd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmntprpd' grid%tail_statevars%DataName = 'ZMNTPRPD' grid%tail_statevars%Description = 'net precipitation production from ZM convection' grid%tail_statevars%Units = 'kg kg_wet-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmntprpd grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmntprpd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17044,& 'frame/module_domain.f: Failed to allocate grid%zmntprpd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmntsnpd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmntsnpd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17053,& 'frame/module_domain.f: Failed to allocate grid%zmntsnpd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmntsnpd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmntsnpd' grid%tail_statevars%DataName = 'ZMNTSNPD' grid%tail_statevars%Description = 'net snow production from ZM convection' grid%tail_statevars%Units = 'kg kg_wet-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmntsnpd grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmntsnpd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17103,& 'frame/module_domain.f: Failed to allocate grid%zmntsnpd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmeiheat').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmeiheat(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17112,& 'frame/module_domain.f: Failed to allocate grid%zmeiheat(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmeiheat=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmeiheat' grid%tail_statevars%DataName = 'ZMEIHEAT' grid%tail_statevars%Description = 'heating by ice and evaporation in ZM convection' grid%tail_statevars%Units = 'W kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmeiheat grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmeiheat(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17162,& 'frame/module_domain.f: Failed to allocate grid%zmeiheat(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cmfmcdzm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cmfmcdzm(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17171,& 'frame/module_domain.f: Failed to allocate grid%cmfmcdzm(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cmfmcdzm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cmfmcdzm' grid%tail_statevars%DataName = 'CMFMCDZM' grid%tail_statevars%Description = 'convection mass flux from ZM deep' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cmfmcdzm grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cmfmcdzm(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17221,& 'frame/module_domain.f: Failed to allocate grid%cmfmcdzm(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'preccdzm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%preccdzm(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17230,& 'frame/module_domain.f: Failed to allocate grid%preccdzm(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%preccdzm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'preccdzm' grid%tail_statevars%DataName = 'PRECCDZM' grid%tail_statevars%Description = 'convection precipitation rate from ZM deep' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%preccdzm grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%preccdzm(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17280,& 'frame/module_domain.f: Failed to allocate grid%preccdzm(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pconvb').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pconvb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17289,& 'frame/module_domain.f: Failed to allocate grid%pconvb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pconvb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pconvb' grid%tail_statevars%DataName = 'PCONVB' grid%tail_statevars%Description = 'convection base pressure' grid%tail_statevars%Units = 'Pa' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%pconvb grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%pconvb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17339,& 'frame/module_domain.f: Failed to allocate grid%pconvb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pconvt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pconvt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17348,& 'frame/module_domain.f: Failed to allocate grid%pconvt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pconvt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pconvt' grid%tail_statevars%DataName = 'PCONVT' grid%tail_statevars%Description = 'convection top pressure' grid%tail_statevars%Units = 'Pa' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%pconvt grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%pconvt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17398,& 'frame/module_domain.f: Failed to allocate grid%pconvt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cape').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cape(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17407,& 'frame/module_domain.f: Failed to allocate grid%cape(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cape=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cape' grid%tail_statevars%DataName = 'CAPE' grid%tail_statevars%Description = 'convectively available potential energy' grid%tail_statevars%Units = 'J kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%cape grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%cape(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17457,& 'frame/module_domain.f: Failed to allocate grid%cape(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmmtu').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmmtu(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17466,& 'frame/module_domain.f: Failed to allocate grid%zmmtu(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmmtu=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmmtu' grid%tail_statevars%DataName = 'ZMMTU' grid%tail_statevars%Description = 'U tendency - ZM convective momentum transport' grid%tail_statevars%Units = 'm s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmmtu grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmmtu(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17516,& 'frame/module_domain.f: Failed to allocate grid%zmmtu(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmmtv').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmmtv(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17525,& 'frame/module_domain.f: Failed to allocate grid%zmmtv(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmmtv=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmmtv' grid%tail_statevars%DataName = 'ZMMTV' grid%tail_statevars%Description = 'V tendency - ZM convective momentum transport' grid%tail_statevars%Units = 'm s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmmtv grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmmtv(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17575,& 'frame/module_domain.f: Failed to allocate grid%zmmtv(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmmu').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmmu(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17584,& 'frame/module_domain.f: Failed to allocate grid%zmmu(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmmu=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmmu' grid%tail_statevars%DataName = 'ZMMU' grid%tail_statevars%Description = 'ZM convection updraft mass flux' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmmu grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmmu(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17634,& 'frame/module_domain.f: Failed to allocate grid%zmmu(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmmd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmmd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17643,& 'frame/module_domain.f: Failed to allocate grid%zmmd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmmd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmmd' grid%tail_statevars%DataName = 'ZMMD' grid%tail_statevars%Description = 'ZM convection downdraft mass flux' grid%tail_statevars%Units = 'kg m-2 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmmd grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmmd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17693,& 'frame/module_domain.f: Failed to allocate grid%zmmd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmupgu').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmupgu(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17702,& 'frame/module_domain.f: Failed to allocate grid%zmupgu(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmupgu=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmupgu' grid%tail_statevars%DataName = 'ZMUPGU' grid%tail_statevars%Description = 'zonal force from ZM updraft pressure gradient term' grid%tail_statevars%Units = 'm s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmupgu grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmupgu(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17752,& 'frame/module_domain.f: Failed to allocate grid%zmupgu(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmupgd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmupgd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17761,& 'frame/module_domain.f: Failed to allocate grid%zmupgd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmupgd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmupgd' grid%tail_statevars%DataName = 'ZMUPGD' grid%tail_statevars%Description = 'zonal force from ZM downdraft pressure gradient term' grid%tail_statevars%Units = 'm s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmupgd grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmupgd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17811,& 'frame/module_domain.f: Failed to allocate grid%zmupgd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmvpgu').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmvpgu(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17820,& 'frame/module_domain.f: Failed to allocate grid%zmvpgu(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmvpgu=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmvpgu' grid%tail_statevars%DataName = 'ZMVPGU' grid%tail_statevars%Description = 'meridional force from ZM updraft pressure gradient term' grid%tail_statevars%Units = 'm s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmvpgu grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmvpgu(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17870,& 'frame/module_domain.f: Failed to allocate grid%zmvpgu(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmvpgd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmvpgd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17879,& 'frame/module_domain.f: Failed to allocate grid%zmvpgd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmvpgd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmvpgd' grid%tail_statevars%DataName = 'ZMVPGD' grid%tail_statevars%Description = 'meridional force from ZM downdraft pressure gradient term' grid%tail_statevars%Units = 'm s-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmvpgd grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmvpgd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17929,& 'frame/module_domain.f: Failed to allocate grid%zmvpgd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmicuu').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmicuu(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17938,& 'frame/module_domain.f: Failed to allocate grid%zmicuu(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmicuu=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmicuu' grid%tail_statevars%DataName = 'ZMICUU' grid%tail_statevars%Description = 'ZM in-cloud U updrafts' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmicuu grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmicuu(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17988,& 'frame/module_domain.f: Failed to allocate grid%zmicuu(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmicud').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmicud(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17997,& 'frame/module_domain.f: Failed to allocate grid%zmicud(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmicud=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmicud' grid%tail_statevars%DataName = 'ZMICUD' grid%tail_statevars%Description = 'ZM in-cloud U downdrafts' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmicud grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmicud(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18047,& 'frame/module_domain.f: Failed to allocate grid%zmicud(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmicvu').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmicvu(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18056,& 'frame/module_domain.f: Failed to allocate grid%zmicvu(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmicvu=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmicvu' grid%tail_statevars%DataName = 'ZMICVU' grid%tail_statevars%Description = 'ZM in-cloud V updrafts' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmicvu grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmicvu(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18106,& 'frame/module_domain.f: Failed to allocate grid%zmicvu(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'zmicvd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%zmicvd(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18115,& 'frame/module_domain.f: Failed to allocate grid%zmicvd(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%zmicvd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'zmicvd' grid%tail_statevars%DataName = 'ZMICVD' grid%tail_statevars%Description = 'ZM in-cloud V downdrafts' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%zmicvd grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%zmicvd(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18165,& 'frame/module_domain.f: Failed to allocate grid%zmicvd(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'evapcdp3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%evapcdp3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18174,& 'frame/module_domain.f: Failed to allocate grid%evapcdp3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%evapcdp3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'evapcdp3d' grid%tail_statevars%DataName = 'EVAPCDP3D' grid%tail_statevars%Description = 'Evaporation of deep convective precipitation' grid%tail_statevars%Units = 'kg/kg/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%evapcdp3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%evapcdp3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18224,& 'frame/module_domain.f: Failed to allocate grid%evapcdp3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'icwmrdp3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%icwmrdp3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18233,& 'frame/module_domain.f: Failed to allocate grid%icwmrdp3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%icwmrdp3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'icwmrdp3d' grid%tail_statevars%DataName = 'ICWMRDP3D' grid%tail_statevars%Description = 'Deep Convection in-cloud water mixing ratio' grid%tail_statevars%Units = 'kg/m2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%icwmrdp3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%icwmrdp3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18283,& 'frame/module_domain.f: Failed to allocate grid%icwmrdp3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rprddp3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rprddp3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18292,& 'frame/module_domain.f: Failed to allocate grid%rprddp3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rprddp3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rprddp3d' grid%tail_statevars%DataName = 'RPRDDP3D' grid%tail_statevars%Description = 'dq/dt due to deep convective rainout' grid%tail_statevars%Units = 'kg/kg/s' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rprddp3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rprddp3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18342,& 'frame/module_domain.f: Failed to allocate grid%rprddp3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dp3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dp3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18351,& 'frame/module_domain.f: Failed to allocate grid%dp3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dp3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dp3d' grid%tail_statevars%DataName = 'DP3D' grid%tail_statevars%Description = 'Layer pressure thickness between interfaces' grid%tail_statevars%Units = 'mb' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%dp3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%dp3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18401,& 'frame/module_domain.f: Failed to allocate grid%dp3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'du3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%du3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18410,& 'frame/module_domain.f: Failed to allocate grid%du3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%du3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'du3d' grid%tail_statevars%DataName = 'DU3D' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%du3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%du3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18460,& 'frame/module_domain.f: Failed to allocate grid%du3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ed3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ed3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18469,& 'frame/module_domain.f: Failed to allocate grid%ed3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ed3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ed3d' grid%tail_statevars%DataName = 'ED3D' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%ed3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ed3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18519,& 'frame/module_domain.f: Failed to allocate grid%ed3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'eu3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%eu3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18528,& 'frame/module_domain.f: Failed to allocate grid%eu3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%eu3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'eu3d' grid%tail_statevars%DataName = 'EU3D' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%eu3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%eu3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18578,& 'frame/module_domain.f: Failed to allocate grid%eu3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'md3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%md3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18587,& 'frame/module_domain.f: Failed to allocate grid%md3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%md3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'md3d' grid%tail_statevars%DataName = 'MD3D' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%md3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%md3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18637,& 'frame/module_domain.f: Failed to allocate grid%md3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mu3d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%mu3d(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18646,& 'frame/module_domain.f: Failed to allocate grid%mu3d(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mu3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'mu3d' grid%tail_statevars%DataName = 'MU3D' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%mu3d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%mu3d(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18696,& 'frame/module_domain.f: Failed to allocate grid%mu3d(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dsubcld2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dsubcld2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18705,& 'frame/module_domain.f: Failed to allocate grid%dsubcld2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dsubcld2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dsubcld2d' grid%tail_statevars%DataName = 'DSUBCLD2D' grid%tail_statevars%Description = 'Layer pres. thickness between LCL and maxi' grid%tail_statevars%Units = 'mb' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%dsubcld2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%dsubcld2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18755,& 'frame/module_domain.f: Failed to allocate grid%dsubcld2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ideep2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ideep2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18764,& 'frame/module_domain.f: Failed to allocate grid%ideep2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ideep2d=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ideep2d' grid%tail_statevars%DataName = 'IDEEP2D' grid%tail_statevars%Description = 'Holds position of gathered points' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_2d => grid%ideep2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%ideep2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18814,& 'frame/module_domain.f: Failed to allocate grid%ideep2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'jt2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%jt2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18823,& 'frame/module_domain.f: Failed to allocate grid%jt2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%jt2d=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'jt2d' grid%tail_statevars%DataName = 'JT2D' grid%tail_statevars%Description = 'Top-level index of deep cumulus convection' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_2d => grid%jt2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%jt2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18873,& 'frame/module_domain.f: Failed to allocate grid%jt2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'maxg2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%maxg2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18882,& 'frame/module_domain.f: Failed to allocate grid%maxg2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%maxg2d=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'maxg2d' grid%tail_statevars%DataName = 'MAXG2D' grid%tail_statevars%Description = 'Gathered values of maxi' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_2d => grid%maxg2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%maxg2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18932,& 'frame/module_domain.f: Failed to allocate grid%maxg2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lengath2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lengath2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18941,& 'frame/module_domain.f: Failed to allocate grid%lengath2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lengath2d=0 IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lengath2d' grid%tail_statevars%DataName = 'LENGATH2D' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%ifield_2d => grid%lengath2d grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%lengath2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18991,& 'frame/module_domain.f: Failed to allocate grid%lengath2d(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cmfsl').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cmfsl(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19000,& 'frame/module_domain.f: Failed to allocate grid%cmfsl(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cmfsl=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cmfsl' grid%tail_statevars%DataName = 'CMFSL ' grid%tail_statevars%Description = 'moist shallow convection liquid water static energy flux' grid%tail_statevars%Units = 'W m-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cmfsl grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cmfsl(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19050,& 'frame/module_domain.f: Failed to allocate grid%cmfsl(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cmflq').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cmflq(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19059,& 'frame/module_domain.f: Failed to allocate grid%cmflq(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cmflq=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cmflq' grid%tail_statevars%DataName = 'CMFLQ ' grid%tail_statevars%Description = 'moist shallow convection total water flux' grid%tail_statevars%Units = 'W m-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cmflq grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cmflq(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19109,& 'frame/module_domain.f: Failed to allocate grid%cmflq(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cmfmc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cmfmc(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19118,& 'frame/module_domain.f: Failed to allocate grid%cmfmc(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cmfmc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cmfmc' grid%tail_statevars%DataName = 'CMFMC ' grid%tail_statevars%Description = 'updraft mass flux for shallow+deep convection' grid%tail_statevars%Units = '~?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cmfmc grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cmfmc(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19168,& 'frame/module_domain.f: Failed to allocate grid%cmfmc(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cmfmc2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cmfmc2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19177,& 'frame/module_domain.f: Failed to allocate grid%cmfmc2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cmfmc2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cmfmc2' grid%tail_statevars%DataName = 'CMFMC2' grid%tail_statevars%Description = 'updraft mass flux for shallow convection' grid%tail_statevars%Units = '~?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cmfmc2 grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = kde grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( kde, kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cmfmc2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19227,& 'frame/module_domain.f: Failed to allocate grid%cmfmc2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cldfrash').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cldfrash(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19236,& 'frame/module_domain.f: Failed to allocate grid%cldfrash(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cldfrash=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cldfrash' grid%tail_statevars%DataName = 'CLDFRASH' grid%tail_statevars%Description = 'shallow convective cloud fraction' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%cldfrash grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cldfrash(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19286,& 'frame/module_domain.f: Failed to allocate grid%cldfrash(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cush').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cush(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19295,& 'frame/module_domain.f: Failed to allocate grid%cush(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cush=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cush' grid%tail_statevars%DataName = 'CUSH' grid%tail_statevars%Description = 'convective scale height' grid%tail_statevars%Units = '~?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%cush grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%cush(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19345,& 'frame/module_domain.f: Failed to allocate grid%cush(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'evapcsh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%evapcsh(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19354,& 'frame/module_domain.f: Failed to allocate grid%evapcsh(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%evapcsh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'evapcsh' grid%tail_statevars%DataName = 'EVAPCSH' grid%tail_statevars%Description = 'evaporation of shallow Cu precipitation' grid%tail_statevars%Units = 'kg kg-1 s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%evapcsh grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%evapcsh(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19404,& 'frame/module_domain.f: Failed to allocate grid%evapcsh(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'icwmrsh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%icwmrsh(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19413,& 'frame/module_domain.f: Failed to allocate grid%icwmrsh(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%icwmrsh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'icwmrsh' grid%tail_statevars%DataName = 'ICWMRSH' grid%tail_statevars%Description = 'shallow cumulus in-cloud water mixing ratio' grid%tail_statevars%Units = 'kg m-2' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%icwmrsh grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%icwmrsh(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19463,& 'frame/module_domain.f: Failed to allocate grid%icwmrsh(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snowsh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snowsh(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19472,& 'frame/module_domain.f: Failed to allocate grid%snowsh(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snowsh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snowsh' grid%tail_statevars%DataName = 'SNOWSH' grid%tail_statevars%Description = 'convective snow at surface from shallow Cu' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 2 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%snowsh grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = jds grid%tail_statevars%ed2 = (jde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = jms grid%tail_statevars%em2 = jme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = jps grid%tail_statevars%ep2 = MIN( (jde-1), jpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'south_north' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%snowsh(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19522,& 'frame/module_domain.f: Failed to allocate grid%snowsh(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rprdsh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rprdsh(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19531,& 'frame/module_domain.f: Failed to allocate grid%rprdsh(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rprdsh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rprdsh' grid%tail_statevars%DataName = 'RPRDSH' grid%tail_statevars%Description = 'dq/dt due to deep(~?) and shallow convective rainout' grid%tail_statevars%Units = '~?' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZY' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 3 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rprdsh grid%tail_statevars%streams(1) = 64 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = ids grid%tail_statevars%ed1 = (ide-1) grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = jds grid%tail_statevars%ed3 = (jde-1) grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = jms grid%tail_statevars%em3 = jme grid%tail_statevars%sp1 = ips grid%tail_statevars%ep1 = MIN( (ide-1), ipe ) grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = jps grid%tail_statevars%ep3 = MIN( (jde-1), jpe ) grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%subgrid_y = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rprdsh(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",19581,& 'frame/module_domain.f: Failed to allocate grid%rprdsh(1,1,1). ') endif ENDIF END SUBROUTINE alloc_space_field_core_6 END MODULE module_alloc_space_6