MODULE module_alloc_space_2 CONTAINS SUBROUTINE alloc_space_field_core_2 ( 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 INTEGER(KIND=8) :: nba CHARACTER(LEN=256) :: message_string 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,'twspd_01max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%twspd_01max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",169,& 'frame/module_domain.f: Failed to allocate grid%twspd_01max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%twspd_01max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'twspd_01max' grid%tail_statevars%DataName = 'TWSPD_01MAX' grid%tail_statevars%Description = 'TIME OF MAXIMUM WIND SPEED at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' grid%tail_statevars%Units = 'minute' 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%twspd_01max grid%tail_statevars%streams(1) = 8 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%twspd_01max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",219,& 'frame/module_domain.f: Failed to allocate grid%twspd_01max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_01max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_01max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",230,& 'frame/module_domain.f: Failed to allocate grid%u_01max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_01max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_01max' grid%tail_statevars%DataName = 'U_01MAX' grid%tail_statevars%Description = 'MAXIMUM ZONAL WIND at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' 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%u_01max grid%tail_statevars%streams(1) = 8 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%u_01max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",280,& 'frame/module_domain.f: Failed to allocate grid%u_01max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_01max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_01max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",291,& 'frame/module_domain.f: Failed to allocate grid%v_01max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_01max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_01max' grid%tail_statevars%DataName = 'V_01MAX' grid%tail_statevars%Description = 'MAXIMUM MERIDIONAL WIND at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' 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%v_01max grid%tail_statevars%streams(1) = 8 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%v_01max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",341,& 'frame/module_domain.f: Failed to allocate grid%v_01max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd_01max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd_01max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",352,& 'frame/module_domain.f: Failed to allocate grid%wspd_01max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd_01max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd_01max' grid%tail_statevars%DataName = 'WSPD_01MAX' grid%tail_statevars%Description = 'MAXIMUM WIND MODULE at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' 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%wspd_01max grid%tail_statevars%streams(1) = 8 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%wspd_01max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",402,& 'frame/module_domain.f: Failed to allocate grid%wspd_01max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_01std').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_01std(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",413,& 'frame/module_domain.f: Failed to allocate grid%u_01std(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_01std=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_01std' grid%tail_statevars%DataName = 'U_01STD' grid%tail_statevars%Description = 'STANDARD DEV. OF ZONAL WIND at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' 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%u_01std grid%tail_statevars%streams(1) = 8 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%u_01std(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",463,& 'frame/module_domain.f: Failed to allocate grid%u_01std(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_01std').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_01std(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",474,& 'frame/module_domain.f: Failed to allocate grid%v_01std(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_01std=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_01std' grid%tail_statevars%DataName = 'V_01STD' grid%tail_statevars%Description = 'STANDARD DEV. OF MERIDIONAL WIND at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' 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%v_01std grid%tail_statevars%streams(1) = 8 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%v_01std(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",524,& 'frame/module_domain.f: Failed to allocate grid%v_01std(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd_01std').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd_01std(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",535,& 'frame/module_domain.f: Failed to allocate grid%wspd_01std(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd_01std=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd_01std' grid%tail_statevars%DataName = 'WSPD_01STD' grid%tail_statevars%Description = 'STANDARD DEV. OF WIND MODULE at 1st level IN DIAGNOSTIC OUTPUT INTERVAL' 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%wspd_01std grid%tail_statevars%streams(1) = 8 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%wspd_01std(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",585,& 'frame/module_domain.f: Failed to allocate grid%wspd_01std(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_uo').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_uo(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",596,& 'frame/module_domain.f: Failed to allocate grid%u_uo(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_uo=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_uo' grid%tail_statevars%DataName = 'U_UO' grid%tail_statevars%Description = 'ZONAL RELATIVE WIND (relative to ocean)' 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%u_uo 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%u_uo(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",646,& 'frame/module_domain.f: Failed to allocate grid%u_uo(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_vo').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_vo(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",657,& 'frame/module_domain.f: Failed to allocate grid%v_vo(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_vo=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_vo' grid%tail_statevars%DataName = 'V_VO' grid%tail_statevars%Description = 'MERIDIONAL RELATIVE WIND (relative to ocean)' 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%v_vo 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%v_vo(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",707,& 'frame/module_domain.f: Failed to allocate grid%v_vo(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd_uo').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd_uo(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",718,& 'frame/module_domain.f: Failed to allocate grid%wspd_uo(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd_uo=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd_uo' grid%tail_statevars%DataName = 'WSPD_UO' grid%tail_statevars%Description = 'RELATIVE WIND MODULE (relative to ocean)' 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%wspd_uo 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%wspd_uo(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",768,& 'frame/module_domain.f: Failed to allocate grid%wspd_uo(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_uomean').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_uomean(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",779,& 'frame/module_domain.f: Failed to allocate grid%u_uomean(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_uomean=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_uomean' grid%tail_statevars%DataName = 'U_UOMEAN' grid%tail_statevars%Description = 'MEAN ZONAL RELATIVE WIND (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%u_uomean grid%tail_statevars%streams(1) = 8 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%u_uomean(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",829,& 'frame/module_domain.f: Failed to allocate grid%u_uomean(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_vomean').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_vomean(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",840,& 'frame/module_domain.f: Failed to allocate grid%v_vomean(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_vomean=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_vomean' grid%tail_statevars%DataName = 'V_VOMEAN' grid%tail_statevars%Description = 'MEAN MERIDIONAL RELATIVE WIND (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%v_vomean grid%tail_statevars%streams(1) = 8 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%v_vomean(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",890,& 'frame/module_domain.f: Failed to allocate grid%v_vomean(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd_uomean').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd_uomean(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",901,& 'frame/module_domain.f: Failed to allocate grid%wspd_uomean(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd_uomean=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd_uomean' grid%tail_statevars%DataName = 'WSPD_UOMEAN' grid%tail_statevars%Description = 'MEAN RELATIVE WIND MODULE (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%wspd_uomean grid%tail_statevars%streams(1) = 8 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%wspd_uomean(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",951,& 'frame/module_domain.f: Failed to allocate grid%wspd_uomean(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'twspd_uomax').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%twspd_uomax(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",962,& 'frame/module_domain.f: Failed to allocate grid%twspd_uomax(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%twspd_uomax=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'twspd_uomax' grid%tail_statevars%DataName = 'TWSPD_UOMAX' grid%tail_statevars%Description = 'TIME OF MAXIMUM RELATIVE WIND SPEED (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' grid%tail_statevars%Units = 'minute' 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%twspd_uomax grid%tail_statevars%streams(1) = 8 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%twspd_uomax(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1012,& 'frame/module_domain.f: Failed to allocate grid%twspd_uomax(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_uomax').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_uomax(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1023,& 'frame/module_domain.f: Failed to allocate grid%u_uomax(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_uomax=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_uomax' grid%tail_statevars%DataName = 'U_UOMAX' grid%tail_statevars%Description = 'MAXIMUM ZONAL RELATIVE WIND (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%u_uomax grid%tail_statevars%streams(1) = 8 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%u_uomax(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1073,& 'frame/module_domain.f: Failed to allocate grid%u_uomax(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_vomax').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_vomax(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1084,& 'frame/module_domain.f: Failed to allocate grid%v_vomax(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_vomax=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_vomax' grid%tail_statevars%DataName = 'V_UOMAX' grid%tail_statevars%Description = 'MAXIMUM MERIDIONAL RELATIVE WIND (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%v_vomax grid%tail_statevars%streams(1) = 8 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%v_vomax(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1134,& 'frame/module_domain.f: Failed to allocate grid%v_vomax(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd_uomax').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd_uomax(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1145,& 'frame/module_domain.f: Failed to allocate grid%wspd_uomax(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd_uomax=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd_uomax' grid%tail_statevars%DataName = 'WSPD_UOMAX' grid%tail_statevars%Description = 'MAXIMUM RELATIVE WIND MODULE (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%wspd_uomax grid%tail_statevars%streams(1) = 8 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%wspd_uomax(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1195,& 'frame/module_domain.f: Failed to allocate grid%wspd_uomax(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_uostd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_uostd(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1206,& 'frame/module_domain.f: Failed to allocate grid%u_uostd(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_uostd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_uostd' grid%tail_statevars%DataName = 'U_UOSTD' grid%tail_statevars%Description = 'STANDARD DEV. OF ZONAL RELATIVE WIND (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%u_uostd grid%tail_statevars%streams(1) = 8 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%u_uostd(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1256,& 'frame/module_domain.f: Failed to allocate grid%u_uostd(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_vostd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_vostd(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1267,& 'frame/module_domain.f: Failed to allocate grid%v_vostd(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_vostd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_vostd' grid%tail_statevars%DataName = 'V_VOSTD' grid%tail_statevars%Description = 'STANDARD DEV. OF MERIDIONAL RELATIVE WIND (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%v_vostd grid%tail_statevars%streams(1) = 8 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%v_vostd(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1317,& 'frame/module_domain.f: Failed to allocate grid%v_vostd(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd_uostd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd_uostd(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1328,& 'frame/module_domain.f: Failed to allocate grid%wspd_uostd(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd_uostd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd_uostd' grid%tail_statevars%DataName = 'WSPD_UOSTD' grid%tail_statevars%Description = 'STANDARD DEV. OF RELATIVE WIND MODULE (relative to ocean) IN DIAGNOSTIC OUTPUT INTERVAL' 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%wspd_uostd grid%tail_statevars%streams(1) = 8 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%wspd_uostd(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1378,& 'frame/module_domain.f: Failed to allocate grid%wspd_uostd(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswupt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswupt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1389,& 'frame/module_domain.f: Failed to allocate grid%acswupt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswupt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswupt' grid%tail_statevars%DataName = 'ACSWUPT' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%acswupt 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%acswupt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1439,& 'frame/module_domain.f: Failed to allocate grid%acswupt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswuptc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswuptc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1450,& 'frame/module_domain.f: Failed to allocate grid%acswuptc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswuptc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswuptc' grid%tail_statevars%DataName = 'ACSWUPTC' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING CLEAR SKY SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%acswuptc 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%acswuptc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1500,& 'frame/module_domain.f: Failed to allocate grid%acswuptc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswdnt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswdnt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1511,& 'frame/module_domain.f: Failed to allocate grid%acswdnt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswdnt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswdnt' grid%tail_statevars%DataName = 'ACSWDNT' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%acswdnt 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%acswdnt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1561,& 'frame/module_domain.f: Failed to allocate grid%acswdnt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswdntc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswdntc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1572,& 'frame/module_domain.f: Failed to allocate grid%acswdntc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswdntc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswdntc' grid%tail_statevars%DataName = 'ACSWDNTC' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING CLEAR SKY SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%acswdntc 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%acswdntc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1622,& 'frame/module_domain.f: Failed to allocate grid%acswdntc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswupb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswupb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1633,& 'frame/module_domain.f: Failed to allocate grid%acswupb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswupb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswupb' grid%tail_statevars%DataName = 'ACSWUPB' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%acswupb 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%acswupb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1683,& 'frame/module_domain.f: Failed to allocate grid%acswupb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswupbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswupbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1694,& 'frame/module_domain.f: Failed to allocate grid%acswupbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswupbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswupbc' grid%tail_statevars%DataName = 'ACSWUPBC' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING CLEAR SKY SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%acswupbc 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%acswupbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1744,& 'frame/module_domain.f: Failed to allocate grid%acswupbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswdnb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswdnb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1755,& 'frame/module_domain.f: Failed to allocate grid%acswdnb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswdnb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswdnb' grid%tail_statevars%DataName = 'ACSWDNB' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%acswdnb 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%acswdnb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1805,& 'frame/module_domain.f: Failed to allocate grid%acswdnb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'acswdnbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%acswdnbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1816,& 'frame/module_domain.f: Failed to allocate grid%acswdnbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%acswdnbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'acswdnbc' grid%tail_statevars%DataName = 'ACSWDNBC' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING CLEAR SKY SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%acswdnbc 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%acswdnbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1866,& 'frame/module_domain.f: Failed to allocate grid%acswdnbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwupt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwupt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1877,& 'frame/module_domain.f: Failed to allocate grid%aclwupt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwupt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwupt' grid%tail_statevars%DataName = 'ACLWUPT' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%aclwupt 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%aclwupt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1927,& 'frame/module_domain.f: Failed to allocate grid%aclwupt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwuptc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwuptc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1938,& 'frame/module_domain.f: Failed to allocate grid%aclwuptc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwuptc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwuptc' grid%tail_statevars%DataName = 'ACLWUPTC' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING CLEAR SKY LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%aclwuptc 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%aclwuptc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1988,& 'frame/module_domain.f: Failed to allocate grid%aclwuptc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwdnt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwdnt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",1999,& 'frame/module_domain.f: Failed to allocate grid%aclwdnt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwdnt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwdnt' grid%tail_statevars%DataName = 'ACLWDNT' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%aclwdnt 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%aclwdnt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2049,& 'frame/module_domain.f: Failed to allocate grid%aclwdnt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwdntc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwdntc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2060,& 'frame/module_domain.f: Failed to allocate grid%aclwdntc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwdntc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwdntc' grid%tail_statevars%DataName = 'ACLWDNTC' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING CLEAR SKY LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-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%aclwdntc 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%aclwdntc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2110,& 'frame/module_domain.f: Failed to allocate grid%aclwdntc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwupb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwupb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2121,& 'frame/module_domain.f: Failed to allocate grid%aclwupb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwupb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwupb' grid%tail_statevars%DataName = 'ACLWUPB' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%aclwupb 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%aclwupb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2171,& 'frame/module_domain.f: Failed to allocate grid%aclwupb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwupbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwupbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2182,& 'frame/module_domain.f: Failed to allocate grid%aclwupbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwupbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwupbc' grid%tail_statevars%DataName = 'ACLWUPBC' grid%tail_statevars%Description = 'ACCUMULATED UPWELLING CLEAR SKY LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%aclwupbc 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%aclwupbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2232,& 'frame/module_domain.f: Failed to allocate grid%aclwupbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwdnb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwdnb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2243,& 'frame/module_domain.f: Failed to allocate grid%aclwdnb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwdnb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwdnb' grid%tail_statevars%DataName = 'ACLWDNB' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%aclwdnb 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%aclwdnb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2293,& 'frame/module_domain.f: Failed to allocate grid%aclwdnb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclwdnbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclwdnbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2304,& 'frame/module_domain.f: Failed to allocate grid%aclwdnbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclwdnbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclwdnbc' grid%tail_statevars%DataName = 'ACLWDNBC' grid%tail_statevars%Description = 'ACCUMULATED DOWNWELLING CLEAR SKY LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-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%aclwdnbc 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%aclwdnbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2354,& 'frame/module_domain.f: Failed to allocate grid%aclwdnbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswupt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswupt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2365,& 'frame/module_domain.f: Failed to allocate grid%i_acswupt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswupt=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 = 'i_acswupt' grid%tail_statevars%DataName = 'I_ACSWUPT' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_acswupt 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%i_acswupt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2415,& 'frame/module_domain.f: Failed to allocate grid%i_acswupt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswuptc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswuptc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2426,& 'frame/module_domain.f: Failed to allocate grid%i_acswuptc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswuptc=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 = 'i_acswuptc' grid%tail_statevars%DataName = 'I_ACSWUPTC' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING CLEAR SKY SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_acswuptc 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%i_acswuptc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2476,& 'frame/module_domain.f: Failed to allocate grid%i_acswuptc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswdnt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswdnt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2487,& 'frame/module_domain.f: Failed to allocate grid%i_acswdnt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswdnt=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 = 'i_acswdnt' grid%tail_statevars%DataName = 'I_ACSWDNT' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_acswdnt 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%i_acswdnt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2537,& 'frame/module_domain.f: Failed to allocate grid%i_acswdnt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswdntc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswdntc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2548,& 'frame/module_domain.f: Failed to allocate grid%i_acswdntc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswdntc=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 = 'i_acswdntc' grid%tail_statevars%DataName = 'I_ACSWDNTC' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING CLEAR SKY SHORTWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_acswdntc 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%i_acswdntc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2598,& 'frame/module_domain.f: Failed to allocate grid%i_acswdntc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswupb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswupb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2609,& 'frame/module_domain.f: Failed to allocate grid%i_acswupb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswupb=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 = 'i_acswupb' grid%tail_statevars%DataName = 'I_ACSWUPB' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_acswupb 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%i_acswupb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2659,& 'frame/module_domain.f: Failed to allocate grid%i_acswupb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswupbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswupbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2670,& 'frame/module_domain.f: Failed to allocate grid%i_acswupbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswupbc=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 = 'i_acswupbc' grid%tail_statevars%DataName = 'I_ACSWUPBC' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING CLEAR SKY SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_acswupbc 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%i_acswupbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2720,& 'frame/module_domain.f: Failed to allocate grid%i_acswupbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswdnb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswdnb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2731,& 'frame/module_domain.f: Failed to allocate grid%i_acswdnb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswdnb=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 = 'i_acswdnb' grid%tail_statevars%DataName = 'I_ACSWDNB' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_acswdnb 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%i_acswdnb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2781,& 'frame/module_domain.f: Failed to allocate grid%i_acswdnb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_acswdnbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_acswdnbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2792,& 'frame/module_domain.f: Failed to allocate grid%i_acswdnbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_acswdnbc=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 = 'i_acswdnbc' grid%tail_statevars%DataName = 'I_ACSWDNBC' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING CLEAR SKY SHORTWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_acswdnbc 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%i_acswdnbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2842,& 'frame/module_domain.f: Failed to allocate grid%i_acswdnbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwupt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwupt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2853,& 'frame/module_domain.f: Failed to allocate grid%i_aclwupt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwupt=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 = 'i_aclwupt' grid%tail_statevars%DataName = 'I_ACLWUPT' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_aclwupt 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%i_aclwupt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2903,& 'frame/module_domain.f: Failed to allocate grid%i_aclwupt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwuptc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwuptc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2914,& 'frame/module_domain.f: Failed to allocate grid%i_aclwuptc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwuptc=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 = 'i_aclwuptc' grid%tail_statevars%DataName = 'I_ACLWUPTC' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING CLEAR SKY LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_aclwuptc 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%i_aclwuptc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2964,& 'frame/module_domain.f: Failed to allocate grid%i_aclwuptc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwdnt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwdnt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",2975,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdnt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwdnt=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 = 'i_aclwdnt' grid%tail_statevars%DataName = 'I_ACLWDNT' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_aclwdnt 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%i_aclwdnt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3025,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdnt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwdntc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwdntc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3036,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdntc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwdntc=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 = 'i_aclwdntc' grid%tail_statevars%DataName = 'I_ACLWDNTC' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING CLEAR SKY LONGWAVE FLUX AT TOP' grid%tail_statevars%Units = 'J m-2' 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%i_aclwdntc 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%i_aclwdntc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3086,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdntc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwupb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwupb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3097,& 'frame/module_domain.f: Failed to allocate grid%i_aclwupb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwupb=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 = 'i_aclwupb' grid%tail_statevars%DataName = 'I_ACLWUPB' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_aclwupb 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%i_aclwupb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3147,& 'frame/module_domain.f: Failed to allocate grid%i_aclwupb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwupbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwupbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3158,& 'frame/module_domain.f: Failed to allocate grid%i_aclwupbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwupbc=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 = 'i_aclwupbc' grid%tail_statevars%DataName = 'I_ACLWUPBC' grid%tail_statevars%Description = 'BUCKET FOR UPWELLING CLEAR SKY LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_aclwupbc 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%i_aclwupbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3208,& 'frame/module_domain.f: Failed to allocate grid%i_aclwupbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwdnb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwdnb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3219,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdnb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwdnb=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 = 'i_aclwdnb' grid%tail_statevars%DataName = 'I_ACLWDNB' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_aclwdnb 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%i_aclwdnb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3269,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdnb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'i_aclwdnbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%i_aclwdnbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3280,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdnbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%i_aclwdnbc=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 = 'i_aclwdnbc' grid%tail_statevars%DataName = 'I_ACLWDNBC' grid%tail_statevars%Description = 'BUCKET FOR DOWNWELLING CLEAR SKY LONGWAVE FLUX AT BOTTOM' grid%tail_statevars%Units = 'J m-2' 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%i_aclwdnbc 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%i_aclwdnbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3330,& 'frame/module_domain.f: Failed to allocate grid%i_aclwdnbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swupt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swupt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3341,& 'frame/module_domain.f: Failed to allocate grid%swupt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swupt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swupt' grid%tail_statevars%DataName = 'SWUPT' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING SHORTWAVE FLUX AT TOP' 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 = '' 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%swupt 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%swupt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3391,& 'frame/module_domain.f: Failed to allocate grid%swupt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swuptc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swuptc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3402,& 'frame/module_domain.f: Failed to allocate grid%swuptc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swuptc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swuptc' grid%tail_statevars%DataName = 'SWUPTC' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAR SKY SHORTWAVE FLUX AT TOP' 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 = '' 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%swuptc 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%swuptc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3452,& 'frame/module_domain.f: Failed to allocate grid%swuptc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swuptcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swuptcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3463,& 'frame/module_domain.f: Failed to allocate grid%swuptcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swuptcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swuptcln' grid%tail_statevars%DataName = 'SWUPTCLN' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAN SKY SHORTWAVE FLUX AT TOP' 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 = '' 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%swuptcln 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%swuptcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3513,& 'frame/module_domain.f: Failed to allocate grid%swuptcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swdnt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swdnt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3524,& 'frame/module_domain.f: Failed to allocate grid%swdnt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swdnt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swdnt' grid%tail_statevars%DataName = 'SWDNT' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING SHORTWAVE FLUX AT TOP' 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 = '' 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%swdnt 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%swdnt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3574,& 'frame/module_domain.f: Failed to allocate grid%swdnt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swdntc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swdntc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3585,& 'frame/module_domain.f: Failed to allocate grid%swdntc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swdntc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swdntc' grid%tail_statevars%DataName = 'SWDNTC' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAR SKY SHORTWAVE FLUX AT TOP' 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 = '' 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%swdntc 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%swdntc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3635,& 'frame/module_domain.f: Failed to allocate grid%swdntc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swdntcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swdntcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3646,& 'frame/module_domain.f: Failed to allocate grid%swdntcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swdntcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swdntcln' grid%tail_statevars%DataName = 'SWDNTCLN' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAN SKY SHORTWAVE FLUX AT TOP' 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 = '' 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%swdntcln 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%swdntcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3696,& 'frame/module_domain.f: Failed to allocate grid%swdntcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swupb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swupb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3707,& 'frame/module_domain.f: Failed to allocate grid%swupb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swupb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swupb' grid%tail_statevars%DataName = 'SWUPB' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING SHORTWAVE FLUX AT BOTTOM' 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 = '' 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%swupb 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%swupb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3757,& 'frame/module_domain.f: Failed to allocate grid%swupb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swupbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swupbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3768,& 'frame/module_domain.f: Failed to allocate grid%swupbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swupbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swupbc' grid%tail_statevars%DataName = 'SWUPBC' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAR SKY SHORTWAVE FLUX AT BOTTOM' 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 = '' 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%swupbc 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%swupbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3818,& 'frame/module_domain.f: Failed to allocate grid%swupbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swupbcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swupbcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3829,& 'frame/module_domain.f: Failed to allocate grid%swupbcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swupbcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swupbcln' grid%tail_statevars%DataName = 'SWUPBCLN' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAN SKY SHORTWAVE FLUX AT BOTTOM' 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 = '' 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%swupbcln 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%swupbcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3879,& 'frame/module_domain.f: Failed to allocate grid%swupbcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swdnb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swdnb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3890,& 'frame/module_domain.f: Failed to allocate grid%swdnb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swdnb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swdnb' grid%tail_statevars%DataName = 'SWDNB' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING SHORTWAVE FLUX AT BOTTOM' 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 = '' 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%swdnb 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%swdnb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3940,& 'frame/module_domain.f: Failed to allocate grid%swdnb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swdnbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swdnbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",3951,& 'frame/module_domain.f: Failed to allocate grid%swdnbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swdnbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swdnbc' grid%tail_statevars%DataName = 'SWDNBC' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAR SKY SHORTWAVE FLUX AT BOTTOM' 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 = '' 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%swdnbc 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%swdnbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4001,& 'frame/module_domain.f: Failed to allocate grid%swdnbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swdnbcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swdnbcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4012,& 'frame/module_domain.f: Failed to allocate grid%swdnbcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swdnbcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swdnbcln' grid%tail_statevars%DataName = 'SWDNBCLN' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAN SKY SHORTWAVE FLUX AT BOTTOM' 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 = '' 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%swdnbcln 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%swdnbcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4062,& 'frame/module_domain.f: Failed to allocate grid%swdnbcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwupt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwupt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4073,& 'frame/module_domain.f: Failed to allocate grid%lwupt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwupt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwupt' grid%tail_statevars%DataName = 'LWUPT' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING LONGWAVE FLUX AT TOP' 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 = '' 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%lwupt 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%lwupt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4123,& 'frame/module_domain.f: Failed to allocate grid%lwupt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwuptc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwuptc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4134,& 'frame/module_domain.f: Failed to allocate grid%lwuptc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwuptc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwuptc' grid%tail_statevars%DataName = 'LWUPTC' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAR SKY LONGWAVE FLUX AT TOP' 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 = '' 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%lwuptc 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%lwuptc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4184,& 'frame/module_domain.f: Failed to allocate grid%lwuptc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwuptcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwuptcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4195,& 'frame/module_domain.f: Failed to allocate grid%lwuptcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwuptcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwuptcln' grid%tail_statevars%DataName = 'LWUPTCLN' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAN SKY LONGWAVE FLUX AT TOP' 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 = '' 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%lwuptcln 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%lwuptcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4245,& 'frame/module_domain.f: Failed to allocate grid%lwuptcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwdnt'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwdnt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4256,& 'frame/module_domain.f: Failed to allocate grid%lwdnt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwdnt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwdnt' grid%tail_statevars%DataName = 'LWDNT' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING LONGWAVE FLUX AT TOP' 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 = '' 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%lwdnt 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%lwdnt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4306,& 'frame/module_domain.f: Failed to allocate grid%lwdnt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwdntc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwdntc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4317,& 'frame/module_domain.f: Failed to allocate grid%lwdntc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwdntc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwdntc' grid%tail_statevars%DataName = 'LWDNTC' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAR SKY LONGWAVE FLUX AT TOP' 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 = '' 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%lwdntc 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%lwdntc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4367,& 'frame/module_domain.f: Failed to allocate grid%lwdntc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwdntcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwdntcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4378,& 'frame/module_domain.f: Failed to allocate grid%lwdntcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwdntcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwdntcln' grid%tail_statevars%DataName = 'LWDNTCLN' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAN SKY LONGWAVE FLUX AT TOP' 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 = '' 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%lwdntcln 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%lwdntcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4428,& 'frame/module_domain.f: Failed to allocate grid%lwdntcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwupb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwupb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4439,& 'frame/module_domain.f: Failed to allocate grid%lwupb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwupb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwupb' grid%tail_statevars%DataName = 'LWUPB' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING LONGWAVE FLUX AT BOTTOM' 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 = '' 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%lwupb 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%lwupb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4489,& 'frame/module_domain.f: Failed to allocate grid%lwupb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwupbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwupbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4500,& 'frame/module_domain.f: Failed to allocate grid%lwupbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwupbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwupbc' grid%tail_statevars%DataName = 'LWUPBC' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAR SKY LONGWAVE FLUX AT BOTTOM' 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 = '' 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%lwupbc 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%lwupbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4550,& 'frame/module_domain.f: Failed to allocate grid%lwupbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwupbcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwupbcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4561,& 'frame/module_domain.f: Failed to allocate grid%lwupbcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwupbcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwupbcln' grid%tail_statevars%DataName = 'LWUPBCLN' grid%tail_statevars%Description = 'INSTANTANEOUS UPWELLING CLEAN SKY LONGWAVE FLUX AT BOTTOM' 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 = '' 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%lwupbcln 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%lwupbcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4611,& 'frame/module_domain.f: Failed to allocate grid%lwupbcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwdnb'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwdnb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4622,& 'frame/module_domain.f: Failed to allocate grid%lwdnb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwdnb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwdnb' grid%tail_statevars%DataName = 'LWDNB' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING LONGWAVE FLUX AT BOTTOM' 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 = '' 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%lwdnb 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%lwdnb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4672,& 'frame/module_domain.f: Failed to allocate grid%lwdnb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwdnbc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwdnbc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4683,& 'frame/module_domain.f: Failed to allocate grid%lwdnbc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwdnbc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwdnbc' grid%tail_statevars%DataName = 'LWDNBC' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAR SKY LONGWAVE FLUX AT BOTTOM' 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 = '' 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%lwdnbc 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%lwdnbc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4733,& 'frame/module_domain.f: Failed to allocate grid%lwdnbc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwdnbcln'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwdnbcln(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4744,& 'frame/module_domain.f: Failed to allocate grid%lwdnbcln(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwdnbcln=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwdnbcln' grid%tail_statevars%DataName = 'LWDNBCLN' grid%tail_statevars%Description = 'INSTANTANEOUS DOWNWELLING CLEAN SKY LONGWAVE FLUX AT BOTTOM' 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 = '' 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%lwdnbcln 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%lwdnbcln(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4794,& 'frame/module_domain.f: Failed to allocate grid%lwdnbcln(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'swcf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%swcf(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4805,& 'frame/module_domain.f: Failed to allocate grid%swcf(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%swcf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'swcf' grid%tail_statevars%DataName = 'SWCF' grid%tail_statevars%Description = 'SHORT WAVE CLOUD FORCING AT TOA' 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 = '' 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%swcf 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%swcf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4855,& 'frame/module_domain.f: Failed to allocate grid%swcf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lwcf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lwcf(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4866,& 'frame/module_domain.f: Failed to allocate grid%lwcf(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lwcf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lwcf' grid%tail_statevars%DataName = 'LWCF' grid%tail_statevars%Description = 'LONG WAVE CLOUD FORCING AT TOA' 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 = '' 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%lwcf 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%lwcf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4916,& 'frame/module_domain.f: Failed to allocate grid%lwcf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'olr').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%olr(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4927,& 'frame/module_domain.f: Failed to allocate grid%olr(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%olr=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'olr' grid%tail_statevars%DataName = 'OLR' grid%tail_statevars%Description = 'TOA OUTGOING LONG WAVE' 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 = '' 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%olr 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%olr(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4977,& 'frame/module_domain.f: Failed to allocate grid%olr(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xlat_u'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xlat_u(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",4988,& 'frame/module_domain.f: Failed to allocate grid%xlat_u(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xlat_u=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xlat_u' grid%tail_statevars%DataName = 'XLAT_U' grid%tail_statevars%Description = 'LATITUDE, SOUTH IS NEGATIVE' grid%tail_statevars%Units = 'degree_north' 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%xlat_u grid%tail_statevars%streams(1) = 234881025 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%xlat_u(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5038,& 'frame/module_domain.f: Failed to allocate grid%xlat_u(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xlong_u'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xlong_u(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5049,& 'frame/module_domain.f: Failed to allocate grid%xlong_u(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xlong_u=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xlong_u' grid%tail_statevars%DataName = 'XLONG_U' grid%tail_statevars%Description = 'LONGITUDE, WEST IS NEGATIVE' grid%tail_statevars%Units = 'degree_east' 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%xlong_u grid%tail_statevars%streams(1) = 234881025 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%xlong_u(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5099,& 'frame/module_domain.f: Failed to allocate grid%xlong_u(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xlat_v'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xlat_v(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5110,& 'frame/module_domain.f: Failed to allocate grid%xlat_v(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xlat_v=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xlat_v' grid%tail_statevars%DataName = 'XLAT_V' grid%tail_statevars%Description = 'LATITUDE, SOUTH IS NEGATIVE' grid%tail_statevars%Units = 'degree_north' 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%xlat_v grid%tail_statevars%streams(1) = 234881025 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%xlat_v(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5160,& 'frame/module_domain.f: Failed to allocate grid%xlat_v(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xlong_v'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xlong_v(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5171,& 'frame/module_domain.f: Failed to allocate grid%xlong_v(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xlong_v=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xlong_v' grid%tail_statevars%DataName = 'XLONG_V' grid%tail_statevars%Description = 'LONGITUDE, WEST IS NEGATIVE' grid%tail_statevars%Units = 'degree_east' 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%xlong_v grid%tail_statevars%streams(1) = 234881025 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%xlong_v(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5221,& 'frame/module_domain.f: Failed to allocate grid%xlong_v(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'albedo').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%albedo(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5232,& 'frame/module_domain.f: Failed to allocate grid%albedo(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%albedo=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'albedo' grid%tail_statevars%DataName = 'ALBEDO' grid%tail_statevars%Description = 'ALBEDO' 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%albedo 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%albedo(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5282,& 'frame/module_domain.f: Failed to allocate grid%albedo(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'clat'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%clat(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5293,& 'frame/module_domain.f: Failed to allocate grid%clat(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%clat=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'clat' grid%tail_statevars%DataName = 'CLAT' grid%tail_statevars%Description = 'COMPUTATIONAL GRID LATITUDE, SOUTH IS NEGATIVE' grid%tail_statevars%Units = 'degree_north' 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%clat grid%tail_statevars%streams(1) = 234881025 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%clat(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5343,& 'frame/module_domain.f: Failed to allocate grid%clat(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'albbck').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%albbck(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5354,& 'frame/module_domain.f: Failed to allocate grid%albbck(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%albbck=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'albbck' grid%tail_statevars%DataName = 'ALBBCK' grid%tail_statevars%Description = 'BACKGROUND ALBEDO' 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%albbck grid%tail_statevars%streams(1) = 771751937 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%albbck(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5404,& 'frame/module_domain.f: Failed to allocate grid%albbck(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'embck').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%embck(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5415,& 'frame/module_domain.f: Failed to allocate grid%embck(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%embck=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'embck' grid%tail_statevars%DataName = 'EMBCK' grid%tail_statevars%Description = 'BACKGROUND EMISSIVITY' 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%embck 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%embck(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5465,& 'frame/module_domain.f: Failed to allocate grid%embck(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'emiss').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%emiss(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5476,& 'frame/module_domain.f: Failed to allocate grid%emiss(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%emiss=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'emiss' grid%tail_statevars%DataName = 'EMISS' grid%tail_statevars%Description = 'SURFACE EMISSIVITY' 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%emiss 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%emiss(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5526,& 'frame/module_domain.f: Failed to allocate grid%emiss(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snotime').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snotime(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5537,& 'frame/module_domain.f: Failed to allocate grid%snotime(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snotime=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snotime' grid%tail_statevars%DataName = 'SNOTIME' grid%tail_statevars%Description = 'SNOTIME' 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%snotime 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%snotime(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5587,& 'frame/module_domain.f: Failed to allocate grid%snotime(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'noahres').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%noahres(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5598,& 'frame/module_domain.f: Failed to allocate grid%noahres(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%noahres=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'noahres' grid%tail_statevars%DataName = 'NOAHRES' grid%tail_statevars%Description = 'RESIDUAL OF THE NOAH SURFACE ENERGY BUDGET' 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 = '' 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%noahres 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 = 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%noahres(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5648,& 'frame/module_domain.f: Failed to allocate grid%noahres(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cldefi').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cldefi(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5659,& 'frame/module_domain.f: Failed to allocate grid%cldefi(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cldefi=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cldefi' grid%tail_statevars%DataName = 'CLDEFI' grid%tail_statevars%Description = 'precipitation efficiency in BMJ SCHEME' 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%cldefi 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%cldefi(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5709,& 'frame/module_domain.f: Failed to allocate grid%cldefi(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 = 'stepra' grid%tail_statevars%DataName = 'STEPRA' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN RADIATION CALLS' 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%stepra grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepra=0 IF(okay_to_alloc.AND.in_use_for_config(id,'rublten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rublten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5739,& 'frame/module_domain.f: Failed to allocate grid%rublten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rublten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rublten' grid%tail_statevars%DataName = 'RUBLTEN' grid%tail_statevars%Description = 'X WIND TENDENCY DUE TO PBL PARAMETERIZATION' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rublten 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%rublten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5789,& 'frame/module_domain.f: Failed to allocate grid%rublten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rvblten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rvblten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5800,& 'frame/module_domain.f: Failed to allocate grid%rvblten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rvblten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rvblten' grid%tail_statevars%DataName = 'RVBLTEN' grid%tail_statevars%Description = 'Y WIND TENDENCY DUE TO PBL PARAMETERIZATION' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rvblten 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%rvblten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5850,& 'frame/module_domain.f: Failed to allocate grid%rvblten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rthblten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rthblten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5861,& 'frame/module_domain.f: Failed to allocate grid%rthblten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rthblten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rthblten' grid%tail_statevars%DataName = 'RTHBLTEN' grid%tail_statevars%Description = 'THETA TENDENCY DUE TO PBL PARAMETERIZATION' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rthblten 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%rthblten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5911,& 'frame/module_domain.f: Failed to allocate grid%rthblten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rqvblten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rqvblten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5922,& 'frame/module_domain.f: Failed to allocate grid%rqvblten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rqvblten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rqvblten' grid%tail_statevars%DataName = 'RQVBLTEN' grid%tail_statevars%Description = 'Q_V TENDENCY DUE TO PBL PARAMETERIZATION' 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%rqvblten 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%rqvblten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5972,& 'frame/module_domain.f: Failed to allocate grid%rqvblten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rqcblten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rqcblten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",5983,& 'frame/module_domain.f: Failed to allocate grid%rqcblten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rqcblten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rqcblten' grid%tail_statevars%DataName = 'RQCBLTEN' grid%tail_statevars%Description = 'Q_C TENDENCY DUE TO PBL PARAMETERIZATION' 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%rqcblten 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%rqcblten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6033,& 'frame/module_domain.f: Failed to allocate grid%rqcblten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rqiblten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rqiblten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6044,& 'frame/module_domain.f: Failed to allocate grid%rqiblten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rqiblten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rqiblten' grid%tail_statevars%DataName = 'RQIBLTEN' grid%tail_statevars%Description = 'Q_I TENDENCY DUE TO PBL PARAMETERIZATION' 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%rqiblten 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%rqiblten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6094,& 'frame/module_domain.f: Failed to allocate grid%rqiblten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rqniblten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rqniblten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6105,& 'frame/module_domain.f: Failed to allocate grid%rqniblten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rqniblten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rqniblten' grid%tail_statevars%DataName = 'RQNIBLTEN' grid%tail_statevars%Description = 'Q_NI TENDENCY DUE TO PBL PARAMETERIZATION' grid%tail_statevars%Units = ' 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%rqniblten 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%rqniblten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6155,& 'frame/module_domain.f: Failed to allocate grid%rqniblten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'flx4').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%flx4(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6166,& 'frame/module_domain.f: Failed to allocate grid%flx4(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%flx4=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'flx4' grid%tail_statevars%DataName = 'FLX4' grid%tail_statevars%Description = 'sensible heat from canopy' 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 = '' 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%flx4 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 = 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%flx4(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6216,& 'frame/module_domain.f: Failed to allocate grid%flx4(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fvb').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%fvb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6227,& 'frame/module_domain.f: Failed to allocate grid%fvb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fvb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fvb' grid%tail_statevars%DataName = 'FVB' grid%tail_statevars%Description = 'fraction of vegetation with snow below' 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 = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fvb 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 = 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%fvb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6277,& 'frame/module_domain.f: Failed to allocate grid%fvb(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fbur').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%fbur(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6288,& 'frame/module_domain.f: Failed to allocate grid%fbur(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fbur=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fbur' grid%tail_statevars%DataName = 'FBUR' grid%tail_statevars%Description = 'fraction of vegetation covered by snow' 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 = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fbur 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 = 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%fbur(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6338,& 'frame/module_domain.f: Failed to allocate grid%fbur(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fgsn').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%fgsn(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6349,& 'frame/module_domain.f: Failed to allocate grid%fgsn(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fgsn=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fgsn' grid%tail_statevars%DataName = 'FGSN' grid%tail_statevars%Description = 'fraction of ground covered by snow' 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 = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%fgsn 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 = 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%fgsn(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6399,& 'frame/module_domain.f: Failed to allocate grid%fgsn(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tsk_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tsk_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6410,& 'frame/module_domain.f: Failed to allocate grid%tsk_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tsk_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tsk_mosaic' grid%tail_statevars%DataName = 'TSK_MOSAIC' grid%tail_statevars%Description = 'vegetation temperature' grid%tail_statevars%Units = 'K' 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%tsk_mosaic grid%tail_statevars%streams(1) = 167772160 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%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tsk_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6460,& 'frame/module_domain.f: Failed to allocate grid%tsk_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qsfc_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qsfc_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6471,& 'frame/module_domain.f: Failed to allocate grid%qsfc_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qsfc_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qsfc_mosaic' grid%tail_statevars%DataName = 'QSFC_MOSAIC' grid%tail_statevars%Description = 'SPECIFIC HUMIDITY AT LOWER BOUNDARY' 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%qsfc_mosaic grid%tail_statevars%streams(1) = 167772160 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%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%qsfc_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6521,& 'frame/module_domain.f: Failed to allocate grid%qsfc_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tslb_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tslb_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6532,& 'frame/module_domain.f: Failed to allocate grid%tslb_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tslb_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tslb_mosaic' grid%tail_statevars%DataName = 'TSLB_MOSAIC' grid%tail_statevars%Description = 'SOIL TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tslb_mosaic grid%tail_statevars%streams(1) = 167772160 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%mosaic_cat_soil 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%mosaic_cat_soil 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%mosaic_cat_soil 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 = 'mosaic_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tslb_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6582,& 'frame/module_domain.f: Failed to allocate grid%tslb_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'smois_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%smois_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6593,& 'frame/module_domain.f: Failed to allocate grid%smois_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%smois_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'smois_mosaic' grid%tail_statevars%DataName = 'SMOIS_MOSAIC' grid%tail_statevars%Description = 'SOIL MOISTURE' grid%tail_statevars%Units = 'm3 m-3' 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%smois_mosaic grid%tail_statevars%streams(1) = 167772160 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%mosaic_cat_soil 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%mosaic_cat_soil 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%mosaic_cat_soil 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 = 'mosaic_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%smois_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6643,& 'frame/module_domain.f: Failed to allocate grid%smois_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sh2o_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sh2o_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6654,& 'frame/module_domain.f: Failed to allocate grid%sh2o_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sh2o_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sh2o_mosaic' grid%tail_statevars%DataName = 'SH2O_MOSAIC' grid%tail_statevars%Description = 'SOIL LIQUID WATER' grid%tail_statevars%Units = 'm3 m-3' 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%sh2o_mosaic grid%tail_statevars%streams(1) = 167772160 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%mosaic_cat_soil 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%mosaic_cat_soil 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%mosaic_cat_soil 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 = 'mosaic_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%sh2o_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6704,& 'frame/module_domain.f: Failed to allocate grid%sh2o_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'canwat_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%canwat_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6715,& 'frame/module_domain.f: Failed to allocate grid%canwat_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%canwat_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'canwat_mosaic' grid%tail_statevars%DataName = 'CANWAT_MOSAIC' grid%tail_statevars%Description = 'CANOPY WATER' 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%canwat_mosaic grid%tail_statevars%streams(1) = 234881024 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%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%canwat_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6765,& 'frame/module_domain.f: Failed to allocate grid%canwat_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snow_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snow_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6776,& 'frame/module_domain.f: Failed to allocate grid%snow_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snow_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snow_mosaic' grid%tail_statevars%DataName = 'SNOW_MOSAIC' grid%tail_statevars%Description = 'SNOW WATER EQUIVALENT' 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%snow_mosaic grid%tail_statevars%streams(1) = 234881024 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%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%snow_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6826,& 'frame/module_domain.f: Failed to allocate grid%snow_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snowh_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snowh_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6837,& 'frame/module_domain.f: Failed to allocate grid%snowh_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snowh_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snowh_mosaic' grid%tail_statevars%DataName = 'SNOWH_MOSAIC' grid%tail_statevars%Description = 'PHYSICAL SNOW DEPTH' grid%tail_statevars%Units = 'm' 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%snowh_mosaic grid%tail_statevars%streams(1) = 234881024 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%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%snowh_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6887,& 'frame/module_domain.f: Failed to allocate grid%snowh_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snowc_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snowc_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6898,& 'frame/module_domain.f: Failed to allocate grid%snowc_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snowc_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snowc_mosaic' grid%tail_statevars%DataName = 'SNOWC_MOSAIC' grid%tail_statevars%Description = 'FLAG INDICATING SNOW COVERAGE (1 FOR SNOW COVER)' 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%snowc_mosaic grid%tail_statevars%streams(1) = 33554432 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%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%snowc_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6948,& 'frame/module_domain.f: Failed to allocate grid%snowc_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'albedo_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%albedo_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",6959,& 'frame/module_domain.f: Failed to allocate grid%albedo_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%albedo_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'albedo_mosaic' grid%tail_statevars%DataName = 'ALBEDO_MOSAIC' grid%tail_statevars%Description = '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%albedo_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%albedo_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7009,& 'frame/module_domain.f: Failed to allocate grid%albedo_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'albbck_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%albbck_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7020,& 'frame/module_domain.f: Failed to allocate grid%albbck_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%albbck_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'albbck_mosaic' grid%tail_statevars%DataName = 'ALBBCK_MOSAIC' grid%tail_statevars%Description = 'background 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%albbck_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%albbck_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7070,& 'frame/module_domain.f: Failed to allocate grid%albbck_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'emiss_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%emiss_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7081,& 'frame/module_domain.f: Failed to allocate grid%emiss_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%emiss_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'emiss_mosaic' grid%tail_statevars%DataName = 'EMISS_MOSAIC' grid%tail_statevars%Description = 'emissivity' 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%emiss_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%emiss_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7131,& 'frame/module_domain.f: Failed to allocate grid%emiss_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'embck_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%embck_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7142,& 'frame/module_domain.f: Failed to allocate grid%embck_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%embck_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'embck_mosaic' grid%tail_statevars%DataName = 'EMBCK_MOSAIC' grid%tail_statevars%Description = 'background emissivity' 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%embck_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%embck_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7192,& 'frame/module_domain.f: Failed to allocate grid%embck_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'znt_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%znt_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7203,& 'frame/module_domain.f: Failed to allocate grid%znt_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%znt_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'znt_mosaic' grid%tail_statevars%DataName = 'ZNT_MOSAIC' grid%tail_statevars%Description = 'time_varying roughness length' grid%tail_statevars%Units = 'm' 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%znt_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%znt_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7253,& 'frame/module_domain.f: Failed to allocate grid%znt_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'z0_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%z0_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7264,& 'frame/module_domain.f: Failed to allocate grid%z0_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%z0_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'z0_mosaic' grid%tail_statevars%DataName = 'Z0_MOSAIC' grid%tail_statevars%Description = 'background roughness length' grid%tail_statevars%Units = 'm' 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%z0_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%z0_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7314,& 'frame/module_domain.f: Failed to allocate grid%z0_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lai_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lai_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7325,& 'frame/module_domain.f: Failed to allocate grid%lai_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lai_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lai_mosaic' grid%tail_statevars%DataName = 'LAI_MOSAIC' grid%tail_statevars%Description = 'LEAF AREA INDEX' grid%tail_statevars%Units = 'm-2/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%lai_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%lai_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7375,& 'frame/module_domain.f: Failed to allocate grid%lai_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rs_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rs_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7386,& 'frame/module_domain.f: Failed to allocate grid%rs_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rs_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rs_mosaic' grid%tail_statevars%DataName = 'RS_MOSAIC' grid%tail_statevars%Description = 'CANOPY RESISTANCE' grid%tail_statevars%Units = 's m-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%rs_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rs_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7436,& 'frame/module_domain.f: Failed to allocate grid%rs_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hfx_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hfx_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7447,& 'frame/module_domain.f: Failed to allocate grid%hfx_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hfx_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hfx_mosaic' grid%tail_statevars%DataName = 'HFX_MOSAIC' grid%tail_statevars%Description = 'UPWARD HEAT FLUX AT THE SURFACE' 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 = '' 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%hfx_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%hfx_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7497,& 'frame/module_domain.f: Failed to allocate grid%hfx_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qfx_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qfx_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7508,& 'frame/module_domain.f: Failed to allocate grid%qfx_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qfx_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qfx_mosaic' grid%tail_statevars%DataName = 'QFX_MOSAIC' grid%tail_statevars%Description = 'UPWARD MOISTURE FLUX AT THE SURFACE' 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%qfx_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%qfx_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7558,& 'frame/module_domain.f: Failed to allocate grid%qfx_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lh_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lh_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7569,& 'frame/module_domain.f: Failed to allocate grid%lh_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lh_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lh_mosaic' grid%tail_statevars%DataName = 'LH_MOSAIC' grid%tail_statevars%Description = 'LATENT HEAT FLUX AT THE SURFACE' 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 = '' 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%lh_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%lh_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7619,& 'frame/module_domain.f: Failed to allocate grid%lh_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'grdflx_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%grdflx_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7630,& 'frame/module_domain.f: Failed to allocate grid%grdflx_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%grdflx_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'grdflx_mosaic' grid%tail_statevars%DataName = 'GRDFLX_MOSAIC' grid%tail_statevars%Description = 'GROUND HEAT 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 = '' 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%grdflx_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%grdflx_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7680,& 'frame/module_domain.f: Failed to allocate grid%grdflx_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snotime_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snotime_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7691,& 'frame/module_domain.f: Failed to allocate grid%snotime_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snotime_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snotime_mosaic' grid%tail_statevars%DataName = 'SNOTIME_MOSAIC' grid%tail_statevars%Description = 'SNOTIME' 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%snotime_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%snotime_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7741,& 'frame/module_domain.f: Failed to allocate grid%snotime_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tr_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tr_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7752,& 'frame/module_domain.f: Failed to allocate grid%tr_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tr_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tr_urb2d_mosaic' grid%tail_statevars%DataName = 'TR_URB2D_MOSAIC' grid%tail_statevars%Description = 'ROOF TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tr_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tr_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7802,& 'frame/module_domain.f: Failed to allocate grid%tr_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tb_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tb_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7813,& 'frame/module_domain.f: Failed to allocate grid%tb_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tb_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tb_urb2d_mosaic' grid%tail_statevars%DataName = 'TB_URB2D_MOSAIC' grid%tail_statevars%Description = 'WALL TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tb_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tb_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7863,& 'frame/module_domain.f: Failed to allocate grid%tb_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tg_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tg_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7874,& 'frame/module_domain.f: Failed to allocate grid%tg_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tg_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tg_urb2d_mosaic' grid%tail_statevars%DataName = 'TG_URB2D_MOSAIC' grid%tail_statevars%Description = 'GROUND TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tg_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tg_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7924,& 'frame/module_domain.f: Failed to allocate grid%tg_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tc_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tc_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7935,& 'frame/module_domain.f: Failed to allocate grid%tc_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tc_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tc_urb2d_mosaic' grid%tail_statevars%DataName = 'TC_URB2D_MOSAIC' grid%tail_statevars%Description = 'CANYON TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tc_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tc_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7985,& 'frame/module_domain.f: Failed to allocate grid%tc_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ts_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ts_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",7996,& 'frame/module_domain.f: Failed to allocate grid%ts_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ts_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ts_urb2d_mosaic' grid%tail_statevars%DataName = 'TS_URB2D_MOSAIC' grid%tail_statevars%Description = 'URBAN TEMPERATURE' grid%tail_statevars%Units = 'K' 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%ts_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ts_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8046,& 'frame/module_domain.f: Failed to allocate grid%ts_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ts_rul2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ts_rul2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8057,& 'frame/module_domain.f: Failed to allocate grid%ts_rul2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ts_rul2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ts_rul2d_mosaic' grid%tail_statevars%DataName = 'TS_RUL2D_MOSAIC' grid%tail_statevars%Description = 'RURAL TEMPERATURE' grid%tail_statevars%Units = 'K' 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%ts_rul2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%ts_rul2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8107,& 'frame/module_domain.f: Failed to allocate grid%ts_rul2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qc_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qc_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8118,& 'frame/module_domain.f: Failed to allocate grid%qc_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qc_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qc_urb2d_mosaic' grid%tail_statevars%DataName = 'TC_URB2D_MOSAIC' grid%tail_statevars%Description = 'CANYON SPECIFIC HUMIDITY' 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%qc_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%qc_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8168,& 'frame/module_domain.f: Failed to allocate grid%qc_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'uc_urb2d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%uc_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8179,& 'frame/module_domain.f: Failed to allocate grid%uc_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%uc_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'uc_urb2d_mosaic' grid%tail_statevars%DataName = 'TC_URB2D_MOSAIC' grid%tail_statevars%Description = 'CANYON WIND SPEED' 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%uc_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%uc_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8229,& 'frame/module_domain.f: Failed to allocate grid%uc_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'trl_urb3d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%trl_urb3d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8240,& 'frame/module_domain.f: Failed to allocate grid%trl_urb3d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%trl_urb3d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'trl_urb3d_mosaic' grid%tail_statevars%DataName = 'TRL_URB3D_MOSAIC' grid%tail_statevars%Description = 'ROOF LAYER TEMPERATURE' grid%tail_statevars%Units = 'K' 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%trl_urb3d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat_soil 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%mosaic_cat_soil 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%mosaic_cat_soil 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 = 'mosaic_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%trl_urb3d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8290,& 'frame/module_domain.f: Failed to allocate grid%trl_urb3d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tbl_urb3d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tbl_urb3d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8301,& 'frame/module_domain.f: Failed to allocate grid%tbl_urb3d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tbl_urb3d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tbl_urb3d_mosaic' grid%tail_statevars%DataName = 'TBL_URB3D_MOSAIC' grid%tail_statevars%Description = 'WALL LAYER TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tbl_urb3d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat_soil 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%mosaic_cat_soil 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%mosaic_cat_soil 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 = 'mosaic_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tbl_urb3d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8351,& 'frame/module_domain.f: Failed to allocate grid%tbl_urb3d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tgl_urb3d_mosaic'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat_soil)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tgl_urb3d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8362,& 'frame/module_domain.f: Failed to allocate grid%tgl_urb3d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat_soil,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tgl_urb3d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tgl_urb3d_mosaic' grid%tail_statevars%DataName = 'TGL_URB3D_MOSAIC' grid%tail_statevars%Description = 'ROAD LAYER TEMPERATURE' grid%tail_statevars%Units = 'K' 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%tgl_urb3d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat_soil 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%mosaic_cat_soil 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%mosaic_cat_soil 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 = 'mosaic_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tgl_urb3d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8412,& 'frame/module_domain.f: Failed to allocate grid%tgl_urb3d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sh_urb2d_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sh_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8423,& 'frame/module_domain.f: Failed to allocate grid%sh_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sh_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sh_urb2d_mosaic' grid%tail_statevars%DataName = 'SH_URB2D_MOSAIC' grid%tail_statevars%Description = 'UPWARD HEAT FLUX AT THE SURFACE' 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 = '' 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%sh_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%sh_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8473,& 'frame/module_domain.f: Failed to allocate grid%sh_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lh_urb2d_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lh_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8484,& 'frame/module_domain.f: Failed to allocate grid%lh_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lh_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lh_urb2d_mosaic' grid%tail_statevars%DataName = 'LH_URB2D_MOSAIC' grid%tail_statevars%Description = 'LATENT HEAT FLUX AT THE SURFACE' 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%lh_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%lh_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8534,& 'frame/module_domain.f: Failed to allocate grid%lh_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'g_urb2d_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%g_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8545,& 'frame/module_domain.f: Failed to allocate grid%g_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%g_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'g_urb2d_mosaic' grid%tail_statevars%DataName = 'G_URB2D_MOSAIC' grid%tail_statevars%Description = 'GROUND HEAT FLUX AT THE SURFACE' 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 = '' 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%g_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%g_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8595,& 'frame/module_domain.f: Failed to allocate grid%g_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rn_urb2d_mosaic').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%mosaic_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rn_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8606,& 'frame/module_domain.f: Failed to allocate grid%rn_urb2d_mosaic(sm31:em31,1:model_config_rec%mosaic_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rn_urb2d_mosaic=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rn_urb2d_mosaic' grid%tail_statevars%DataName = 'RN_URB2D_MOSAIC' grid%tail_statevars%Description = 'NET RADIATION' 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 = '' 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%rn_urb2d_mosaic 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 = 1 grid%tail_statevars%ed2 = config_flags%mosaic_cat 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%mosaic_cat 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%mosaic_cat 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 = 'mosaic' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%rn_urb2d_mosaic(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8656,& 'frame/module_domain.f: Failed to allocate grid%rn_urb2d_mosaic(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mosaic_cat_index'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_land_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%num_land_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%mosaic_cat_index(sm31:em31,1:model_config_rec%num_land_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8667,& 'frame/module_domain.f: Failed to allocate grid%mosaic_cat_index(sm31:em31,1:model_config_rec%num_land_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mosaic_cat_index=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 = 'mosaic_cat_index' grid%tail_statevars%DataName = 'MOSAIC_CAT_INDEX' grid%tail_statevars%Description = ' ' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'i' 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%ifield_3d => grid%mosaic_cat_index grid%tail_statevars%streams(1) = 234881024 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_land_cat 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_land_cat 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_land_cat 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 = 'land_cat_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%mosaic_cat_index(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8717,& 'frame/module_domain.f: Failed to allocate grid%mosaic_cat_index(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'landusef2'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_land_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%num_land_cat)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%landusef2(sm31:em31,1:model_config_rec%num_land_cat,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8728,& 'frame/module_domain.f: Failed to allocate grid%landusef2(sm31:em31,1:model_config_rec%num_land_cat,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%landusef2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'landusef2' grid%tail_statevars%DataName = 'LANDUSEF2' grid%tail_statevars%Description = 'sorted landuse fraction' 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%landusef2 grid%tail_statevars%streams(1) = 234881024 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_land_cat 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_land_cat 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_land_cat 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 = 'land_cat_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%landusef2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8778,& 'frame/module_domain.f: Failed to allocate grid%landusef2(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mp_restart_state').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((7501)-(1)+1))) * 4 nba = & ((((7501)-(1)+1))) * 4 ALLOCATE(grid%mp_restart_state(1:7501),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8789,& 'frame/module_domain.f: Failed to allocate grid%mp_restart_state(1:7501). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mp_restart_state=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'mp_restart_state' grid%tail_statevars%DataName = 'MP_RESTART_STATE' grid%tail_statevars%Description = 'STATE VECTOR FOR MICROPHYSICS RESTARTS' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'C' 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%mp_restart_state grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 7501 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 = 7501 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 = 7501 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%mp_restart_state(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8837,& 'frame/module_domain.f: Failed to allocate grid%mp_restart_state(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tbpvs_state').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((7501)-(1)+1))) * 4 nba = & ((((7501)-(1)+1))) * 4 ALLOCATE(grid%tbpvs_state(1:7501),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8848,& 'frame/module_domain.f: Failed to allocate grid%tbpvs_state(1:7501). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tbpvs_state=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tbpvs_state' grid%tail_statevars%DataName = 'TBPVS_STATE' grid%tail_statevars%Description = 'STATE FOR ETAMPNEW MICROPHYSICS' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'C' 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%tbpvs_state grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 7501 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 = 7501 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 = 7501 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%tbpvs_state(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8896,& 'frame/module_domain.f: Failed to allocate grid%tbpvs_state(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tbpvs0_state').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((7501)-(1)+1))) * 4 nba = & ((((7501)-(1)+1))) * 4 ALLOCATE(grid%tbpvs0_state(1:7501),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8907,& 'frame/module_domain.f: Failed to allocate grid%tbpvs0_state(1:7501). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tbpvs0_state=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tbpvs0_state' grid%tail_statevars%DataName = 'TBPVS0_STATE' grid%tail_statevars%Description = 'STATE FOR ETAMPNEW MICROPHYSICS' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'C' 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%tbpvs0_state grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 7501 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 = 7501 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 = 7501 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%tbpvs0_state(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",8955,& 'frame/module_domain.f: Failed to allocate grid%tbpvs0_state(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 = 'landuse_isice' grid%tail_statevars%DataName = 'LANDUSE_ISICE' grid%tail_statevars%Description = '-' 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%landuse_isice grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%landuse_isice=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 = 'landuse_lucats' grid%tail_statevars%DataName = 'LANDUSE_LUCATS' grid%tail_statevars%Description = '-' 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%landuse_lucats grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%landuse_lucats=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 = 'landuse_luseas' grid%tail_statevars%DataName = 'LANDUSE_LUSEAS' grid%tail_statevars%Description = '-' 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%landuse_luseas grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%landuse_luseas=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 = 'landuse_isn' grid%tail_statevars%DataName = 'LANDUSE_ISN' grid%tail_statevars%Description = '-' 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%landuse_isn grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%landuse_isn=0 IF(okay_to_alloc.AND.in_use_for_config(id,'lu_state').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((7501)-(1)+1))) * 4 nba = & ((((7501)-(1)+1))) * 4 ALLOCATE(grid%lu_state(1:7501),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9042,& 'frame/module_domain.f: Failed to allocate grid%lu_state(1:7501). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lu_state=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lu_state' grid%tail_statevars%DataName = 'LU_STATE' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'C' 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%lu_state grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = 7501 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 = 7501 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 = 7501 grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%lu_state(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9090,& 'frame/module_domain.f: Failed to allocate grid%lu_state(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'t_phy').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%t_phy(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9101,& 'frame/module_domain.f: Failed to allocate grid%t_phy(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%t_phy=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 't_phy' grid%tail_statevars%DataName = 'T_PHY' grid%tail_statevars%Description = 'Temperature' grid%tail_statevars%Units = 'K' 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%t_phy 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%t_phy(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9151,& 'frame/module_domain.f: Failed to allocate grid%t_phy(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_phy').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_phy(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9162,& 'frame/module_domain.f: Failed to allocate grid%u_phy(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_phy=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_phy' grid%tail_statevars%DataName = 'U_PHY' grid%tail_statevars%Description = 'x-wind component at mass point' 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%u_phy 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%u_phy(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9212,& 'frame/module_domain.f: Failed to allocate grid%u_phy(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_phy').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_phy(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9223,& 'frame/module_domain.f: Failed to allocate grid%v_phy(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_phy=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_phy' grid%tail_statevars%DataName = 'V_PHY' grid%tail_statevars%Description = 'y-wind component at mass point' 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%v_phy 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%v_phy(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9273,& 'frame/module_domain.f: Failed to allocate grid%v_phy(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u_phyl1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u_phyl1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9284,& 'frame/module_domain.f: Failed to allocate grid%u_phyl1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u_phyl1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u_phyl1' grid%tail_statevars%DataName = 'U_PHYL1' grid%tail_statevars%Description = 'x-wind component at mass point level 1' 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%u_phyl1 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 = 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%u_phyl1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9334,& 'frame/module_domain.f: Failed to allocate grid%u_phyl1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v_phyl1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v_phyl1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9345,& 'frame/module_domain.f: Failed to allocate grid%v_phyl1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v_phyl1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v_phyl1' grid%tail_statevars%DataName = 'V_PHYL1' grid%tail_statevars%Description = '-' 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 = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%v_phyl1 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 = 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%v_phyl1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9395,& 'frame/module_domain.f: Failed to allocate grid%v_phyl1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'t_phyl1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%t_phyl1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9406,& 'frame/module_domain.f: Failed to allocate grid%t_phyl1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%t_phyl1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 't_phyl1' grid%tail_statevars%DataName = 'T_PHYL1' grid%tail_statevars%Description = 'Temperature level 1' 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 = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%t_phyl1 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 = 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%t_phyl1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9456,& 'frame/module_domain.f: Failed to allocate grid%t_phyl1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qvl1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qvl1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9467,& 'frame/module_domain.f: Failed to allocate grid%qvl1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qvl1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qvl1' grid%tail_statevars%DataName = 'QVL1' grid%tail_statevars%Description = 'TWater vapor mixing ratio level 1' grid%tail_statevars%Units = 'kg 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%qvl1 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 = 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%qvl1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9517,& 'frame/module_domain.f: Failed to allocate grid%qvl1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rhol1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rhol1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9528,& 'frame/module_domain.f: Failed to allocate grid%rhol1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rhol1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rhol1' grid%tail_statevars%DataName = 'RHOL1' grid%tail_statevars%Description = 'DENSITY level 1' grid%tail_statevars%Units = 'Kg m-3' 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%rhol1 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 = 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%rhol1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9578,& 'frame/module_domain.f: Failed to allocate grid%rhol1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tmn'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tmn(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9589,& 'frame/module_domain.f: Failed to allocate grid%tmn(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tmn=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tmn' grid%tail_statevars%DataName = 'TMN' grid%tail_statevars%Description = 'SOIL TEMPERATURE AT LOWER BOUNDARY' 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%tmn grid%tail_statevars%streams(1) = 234881025 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%tmn(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9639,& 'frame/module_domain.f: Failed to allocate grid%tmn(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tyr'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tyr(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9650,& 'frame/module_domain.f: Failed to allocate grid%tyr(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tyr=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tyr' grid%tail_statevars%DataName = 'TYR' grid%tail_statevars%Description = 'ANNUAL MEAN SFC TEMPERATURE' 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%tyr 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%tyr(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9700,& 'frame/module_domain.f: Failed to allocate grid%tyr(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tyra'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tyra(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9711,& 'frame/module_domain.f: Failed to allocate grid%tyra(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tyra=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tyra' grid%tail_statevars%DataName = 'TYRA' grid%tail_statevars%Description = 'ACCUMULATED YEARLY SFC TEMPERATURE FOR CURRENT YEAR' 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%tyra 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%tyra(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9761,& 'frame/module_domain.f: Failed to allocate grid%tyra(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tdly'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tdly(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9772,& 'frame/module_domain.f: Failed to allocate grid%tdly(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tdly=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tdly' grid%tail_statevars%DataName = 'TDLY' grid%tail_statevars%Description = 'ACCUMULATED DAILY SFC TEMPERATURE FOR CURRENT DAY' 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%tdly 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%tdly(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9822,& 'frame/module_domain.f: Failed to allocate grid%tdly(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tlag'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%lagday)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%lagday)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tlag(sm31:em31,1:model_config_rec%lagday,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9833,& 'frame/module_domain.f: Failed to allocate grid%tlag(sm31:em31,1:model_config_rec%lagday,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tlag=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tlag' grid%tail_statevars%DataName = 'TLAG' grid%tail_statevars%Description = 'DAILY MEAN SFC TEMPERATURE OF PRIOR DAYS' grid%tail_statevars%Units = 'K' 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%tlag 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 = 1 grid%tail_statevars%ed2 = config_flags%lagday 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%lagday 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%lagday 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 = 'lagday' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%tlag(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9883,& 'frame/module_domain.f: Failed to allocate grid%tlag(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 = 'nyear' grid%tail_statevars%DataName = 'NYEAR' grid%tail_statevars%Description = 'ACCUM DAYS IN A YEAR' 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%nyear grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%nyear=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 = 'nday' grid%tail_statevars%DataName = 'NDAY' grid%tail_statevars%Description = 'ACCUM TIMESTEPS IN A DAY' grid%tail_statevars%Units = '' grid%tail_statevars%Type = 'r' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .TRUE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_0d => grid%nday grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%nday=initial_data_value IF(okay_to_alloc.AND.in_use_for_config(id,'xland'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xland(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9932,& 'frame/module_domain.f: Failed to allocate grid%xland(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xland=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xland' grid%tail_statevars%DataName = 'XLAND' grid%tail_statevars%Description = 'LAND MASK (1 FOR LAND, 2 FOR WATER)' 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%xland grid%tail_statevars%streams(1) = 167772161 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%xland(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9982,& 'frame/module_domain.f: Failed to allocate grid%xland(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cplmask').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((model_config_rec%num_ext_model_couple_dom)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((model_config_rec%num_ext_model_couple_dom)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cplmask(sm31:em31,1:model_config_rec%num_ext_model_couple_dom,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",9993,& 'frame/module_domain.f: Failed to allocate grid%cplmask(sm31:em31,1:model_config_rec%num_ext_model_couple_dom,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cplmask=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cplmask' grid%tail_statevars%DataName = 'CPLMASK' grid%tail_statevars%Description = 'COUPLING MASK (0:VALUE FROM SST UPDATE; 1:VALUE FROM COUPLED OCEAN), vertical dim is number of external domains' 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%cplmask grid%tail_statevars%streams(1) = 33554432 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_ext_model_couple_dom 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_ext_model_couple_dom 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_ext_model_couple_dom 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_ext_model_couple_dom_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%cplmask(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10043,& 'frame/module_domain.f: Failed to allocate grid%cplmask(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'znt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%znt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10054,& 'frame/module_domain.f: Failed to allocate grid%znt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%znt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'znt' grid%tail_statevars%DataName = 'ZNT' grid%tail_statevars%Description = 'TIME-VARYING ROUGHNESS LENGTH' grid%tail_statevars%Units = 'm' 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%znt grid%tail_statevars%streams(1) = 268435456 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%znt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10104,& 'frame/module_domain.f: Failed to allocate grid%znt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ck').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ck(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10115,& 'frame/module_domain.f: Failed to allocate grid%ck(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ck=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ck' grid%tail_statevars%DataName = 'CK' grid%tail_statevars%Description = 'ENTHALPY EXCHANGE COEFF AT 10 m' 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%ck 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%ck(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10165,& 'frame/module_domain.f: Failed to allocate grid%ck(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cka').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cka(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10176,& 'frame/module_domain.f: Failed to allocate grid%cka(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cka=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cka' grid%tail_statevars%DataName = 'CKA' grid%tail_statevars%Description = 'ENTHALPY EXCHANGE COEFF AT LOWEST MODEL LVL' 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%cka 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%cka(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10226,& 'frame/module_domain.f: Failed to allocate grid%cka(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cd').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cd(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10237,& 'frame/module_domain.f: Failed to allocate grid%cd(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cd=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cd' grid%tail_statevars%DataName = 'CD' grid%tail_statevars%Description = 'DRAG COEFF AT 10m' 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%cd 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%cd(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10287,& 'frame/module_domain.f: Failed to allocate grid%cd(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'cda').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%cda(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10298,& 'frame/module_domain.f: Failed to allocate grid%cda(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%cda=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'cda' grid%tail_statevars%DataName = 'CDA' grid%tail_statevars%Description = 'DRAG COEFF AT LOWEST MODEL LVL' 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%cda 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%cda(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10348,& 'frame/module_domain.f: Failed to allocate grid%cda(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ust').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ust(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10359,& 'frame/module_domain.f: Failed to allocate grid%ust(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ust=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ust' grid%tail_statevars%DataName = 'UST' grid%tail_statevars%Description = 'U* IN SIMILARITY THEORY' 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%ust 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%ust(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10409,& 'frame/module_domain.f: Failed to allocate grid%ust(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ustm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ustm(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10420,& 'frame/module_domain.f: Failed to allocate grid%ustm(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ustm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ustm' grid%tail_statevars%DataName = 'USTM' grid%tail_statevars%Description = 'U* IN SIMILARITY THEORY WITHOUT VCONV' 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%ustm 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%ustm(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10470,& 'frame/module_domain.f: Failed to allocate grid%ustm(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rmol').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rmol(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10481,& 'frame/module_domain.f: Failed to allocate grid%rmol(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rmol=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rmol' grid%tail_statevars%DataName = 'RMOL' grid%tail_statevars%Description = '1./Monin Ob. Length' 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%rmol 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%rmol(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10531,& 'frame/module_domain.f: Failed to allocate grid%rmol(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mol').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%mol(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10542,& 'frame/module_domain.f: Failed to allocate grid%mol(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mol=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'mol' grid%tail_statevars%DataName = 'MOL' grid%tail_statevars%Description = 'T* IN SIMILARITY THEORY' 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%mol 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%mol(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10592,& 'frame/module_domain.f: Failed to allocate grid%mol(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pblh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pblh(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10603,& 'frame/module_domain.f: Failed to allocate grid%pblh(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pblh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pblh' grid%tail_statevars%DataName = 'PBLH' grid%tail_statevars%Description = 'PBL HEIGHT' grid%tail_statevars%Units = 'm' 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%pblh 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%pblh(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10653,& 'frame/module_domain.f: Failed to allocate grid%pblh(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'capg').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%capg(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10664,& 'frame/module_domain.f: Failed to allocate grid%capg(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%capg=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'capg' grid%tail_statevars%DataName = 'CAPG' grid%tail_statevars%Description = 'HEAT CAPACITY FOR SOIL' grid%tail_statevars%Units = 'J K-1 m-3' 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%capg 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%capg(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10714,& 'frame/module_domain.f: Failed to allocate grid%capg(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'thc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%thc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10725,& 'frame/module_domain.f: Failed to allocate grid%thc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%thc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'thc' grid%tail_statevars%DataName = 'THC' grid%tail_statevars%Description = 'THERMAL INERTIA' grid%tail_statevars%Units = 'Cal cm-2 K-1 s-0.5' 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%thc 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%thc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10775,& 'frame/module_domain.f: Failed to allocate grid%thc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10786,& 'frame/module_domain.f: Failed to allocate grid%hfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hfx' grid%tail_statevars%DataName = 'HFX' grid%tail_statevars%Description = 'UPWARD HEAT FLUX AT THE SURFACE' 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 = '' 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%hfx 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%hfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10836,& 'frame/module_domain.f: Failed to allocate grid%hfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10847,& 'frame/module_domain.f: Failed to allocate grid%qfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qfx' grid%tail_statevars%DataName = 'QFX' grid%tail_statevars%Description = 'UPWARD MOISTURE FLUX AT THE SURFACE' grid%tail_statevars%Units = 'kg m-2 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%qfx 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%qfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10897,& 'frame/module_domain.f: Failed to allocate grid%qfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'lh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%lh(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10908,& 'frame/module_domain.f: Failed to allocate grid%lh(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%lh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'lh' grid%tail_statevars%DataName = 'LH' grid%tail_statevars%Description = 'LATENT HEAT FLUX AT THE SURFACE' 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 = '' 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%lh 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%lh(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10958,& 'frame/module_domain.f: Failed to allocate grid%lh(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'achfx'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%achfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",10969,& 'frame/module_domain.f: Failed to allocate grid%achfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%achfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'achfx' grid%tail_statevars%DataName = 'ACHFX' grid%tail_statevars%Description = 'ACCUMULATED UPWARD HEAT FLUX AT THE SURFACE' grid%tail_statevars%Units = 'J m-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%achfx 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%achfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11019,& 'frame/module_domain.f: Failed to allocate grid%achfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wstar').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wstar(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11030,& 'frame/module_domain.f: Failed to allocate grid%wstar(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wstar=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wstar' grid%tail_statevars%DataName = 'WSTAR' grid%tail_statevars%Description = 'DEARDORFF CONVECTIVE VELOCITY SCALE' 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%wstar 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 = 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%wstar(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11080,& 'frame/module_domain.f: Failed to allocate grid%wstar(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'aclhf'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%aclhf(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11091,& 'frame/module_domain.f: Failed to allocate grid%aclhf(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%aclhf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'aclhf' grid%tail_statevars%DataName = 'ACLHF' grid%tail_statevars%Description = 'ACCUMULATED UPWARD LATENT HEAT FLUX AT THE SURFACE' grid%tail_statevars%Units = 'J m-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%aclhf 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%aclhf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11141,& 'frame/module_domain.f: Failed to allocate grid%aclhf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'flhc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%flhc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11152,& 'frame/module_domain.f: Failed to allocate grid%flhc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%flhc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'flhc' grid%tail_statevars%DataName = 'FLHC' grid%tail_statevars%Description = 'SURFACE EXCHANGE COEFFICIENT FOR HEAT' 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%flhc 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%flhc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11202,& 'frame/module_domain.f: Failed to allocate grid%flhc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'flqc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%flqc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11213,& 'frame/module_domain.f: Failed to allocate grid%flqc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%flqc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'flqc' grid%tail_statevars%DataName = 'FLQC' grid%tail_statevars%Description = 'SURFACE EXCHANGE COEFFICIENT FOR MOISTURE' 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%flqc 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%flqc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11263,& 'frame/module_domain.f: Failed to allocate grid%flqc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qsg').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qsg(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11274,& 'frame/module_domain.f: Failed to allocate grid%qsg(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qsg=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qsg' grid%tail_statevars%DataName = 'QSG' grid%tail_statevars%Description = 'SURFACE SATURATION WATER VAPOR MIXING RATIO' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%qsg 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%qsg(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11324,& 'frame/module_domain.f: Failed to allocate grid%qsg(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qvg').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qvg(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11335,& 'frame/module_domain.f: Failed to allocate grid%qvg(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qvg=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qvg' grid%tail_statevars%DataName = 'QVG' grid%tail_statevars%Description = 'WATER VAPOR MIXING RATIO AT THE SURFACE' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%qvg 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%qvg(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11385,& 'frame/module_domain.f: Failed to allocate grid%qvg(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dfi_qvg').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dfi_qvg(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11396,& 'frame/module_domain.f: Failed to allocate grid%dfi_qvg(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dfi_qvg=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dfi_qvg' grid%tail_statevars%DataName = 'QVG_DFI' grid%tail_statevars%Description = 'WATER VAPOR MIXING RATIO AT THE SURFACE' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%dfi_qvg 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%dfi_qvg(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11446,& 'frame/module_domain.f: Failed to allocate grid%dfi_qvg(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qcg').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qcg(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11457,& 'frame/module_domain.f: Failed to allocate grid%qcg(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qcg=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qcg' grid%tail_statevars%DataName = 'QCG' grid%tail_statevars%Description = 'CLOUD WATER MIXING RATIO AT THE GROUND SURFACE' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%qcg 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%qcg(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11507,& 'frame/module_domain.f: Failed to allocate grid%qcg(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dew').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dew(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11518,& 'frame/module_domain.f: Failed to allocate grid%dew(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dew=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dew' grid%tail_statevars%DataName = 'DEW' grid%tail_statevars%Description = 'DEW MIXING RATIO AT THE SURFACE' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%dew 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%dew(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11568,& 'frame/module_domain.f: Failed to allocate grid%dew(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'soilt1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%soilt1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11579,& 'frame/module_domain.f: Failed to allocate grid%soilt1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%soilt1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'soilt1' grid%tail_statevars%DataName = 'SOILT1' grid%tail_statevars%Description = 'TEMPERATURE INSIDE SNOW ' 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%soilt1 grid%tail_statevars%streams(1) = 234881025 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%soilt1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11629,& 'frame/module_domain.f: Failed to allocate grid%soilt1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dfi_soilt1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dfi_soilt1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11640,& 'frame/module_domain.f: Failed to allocate grid%dfi_soilt1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dfi_soilt1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dfi_soilt1' grid%tail_statevars%DataName = 'SOILT1_DFI' grid%tail_statevars%Description = 'TEMPERATURE INSIDE SNOW ' 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%dfi_soilt1 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%dfi_soilt1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11690,& 'frame/module_domain.f: Failed to allocate grid%dfi_soilt1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tsnav').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tsnav(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11701,& 'frame/module_domain.f: Failed to allocate grid%tsnav(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tsnav=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tsnav' grid%tail_statevars%DataName = 'TSNAV' grid%tail_statevars%Description = 'AVERAGE SNOW TEMPERATURE ' grid%tail_statevars%Units = 'C' 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%tsnav 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%tsnav(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11751,& 'frame/module_domain.f: Failed to allocate grid%tsnav(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dfi_tsnav').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dfi_tsnav(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11762,& 'frame/module_domain.f: Failed to allocate grid%dfi_tsnav(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dfi_tsnav=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dfi_tsnav' grid%tail_statevars%DataName = 'TSNAV_DFI' grid%tail_statevars%Description = 'AVERAGE SNOW TEMPERATURE ' grid%tail_statevars%Units = 'C' 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%dfi_tsnav 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%dfi_tsnav(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11812,& 'frame/module_domain.f: Failed to allocate grid%dfi_tsnav(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'regime').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%regime(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11823,& 'frame/module_domain.f: Failed to allocate grid%regime(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%regime=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'regime' grid%tail_statevars%DataName = 'REGIME' grid%tail_statevars%Description = 'FLAGS: 1=Night/Stable, 2=Mechanical Turbulent, 3=Forced Conv, 4=Free Conv' 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%regime 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%regime(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11873,& 'frame/module_domain.f: Failed to allocate grid%regime(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snowc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snowc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11884,& 'frame/module_domain.f: Failed to allocate grid%snowc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snowc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snowc' grid%tail_statevars%DataName = 'SNOWC' grid%tail_statevars%Description = 'FLAG INDICATING SNOW COVERAGE (1 FOR SNOW COVER)' 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%snowc grid%tail_statevars%streams(1) = 234881025 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%snowc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11934,& 'frame/module_domain.f: Failed to allocate grid%snowc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dfi_snowc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dfi_snowc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11945,& 'frame/module_domain.f: Failed to allocate grid%dfi_snowc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dfi_snowc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dfi_snowc' grid%tail_statevars%DataName = 'SNOWC_DFI' grid%tail_statevars%Description = 'FLAG INDICATING SNOW COVERAGE (1 FOR SNOW COVER)' 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%dfi_snowc 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%dfi_snowc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",11995,& 'frame/module_domain.f: Failed to allocate grid%dfi_snowc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mavail').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%mavail(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12006,& 'frame/module_domain.f: Failed to allocate grid%mavail(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mavail=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'mavail' grid%tail_statevars%DataName = 'MAVAIL' grid%tail_statevars%Description = 'SURFACE MOISTURE AVAILABILITY' 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%mavail 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%mavail(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12056,& 'frame/module_domain.f: Failed to allocate grid%mavail(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tkesfcf').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tkesfcf(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12067,& 'frame/module_domain.f: Failed to allocate grid%tkesfcf(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tkesfcf=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tkesfcf' grid%tail_statevars%DataName = 'TKESFCF' grid%tail_statevars%Description = 'TKE AT THE SURFACE' 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%tkesfcf 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%tkesfcf(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12117,& 'frame/module_domain.f: Failed to allocate grid%tkesfcf(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sr').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sr(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12128,& 'frame/module_domain.f: Failed to allocate grid%sr(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sr=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sr' grid%tail_statevars%DataName = 'SR' grid%tail_statevars%Description = 'fraction of frozen precipitation' 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%sr grid%tail_statevars%streams(1) = 33554433 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%sr(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12178,& 'frame/module_domain.f: Failed to allocate grid%sr(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'potevp').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%potevp(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12189,& 'frame/module_domain.f: Failed to allocate grid%potevp(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%potevp=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'potevp' grid%tail_statevars%DataName = 'POTEVP' grid%tail_statevars%Description = 'accumulated potential evaporation' grid%tail_statevars%Units = 'm' 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%potevp 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%potevp(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12239,& 'frame/module_domain.f: Failed to allocate grid%potevp(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snopcx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snopcx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12250,& 'frame/module_domain.f: Failed to allocate grid%snopcx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snopcx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snopcx' grid%tail_statevars%DataName = 'SNOPCX' grid%tail_statevars%Description = 'snow phase change heat flux' 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 = '' 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%snopcx 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%snopcx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12300,& 'frame/module_domain.f: Failed to allocate grid%snopcx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'soiltb').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%soiltb(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12311,& 'frame/module_domain.f: Failed to allocate grid%soiltb(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%soiltb=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'soiltb' grid%tail_statevars%DataName = 'SOILTB' grid%tail_statevars%Description = 'bottom soil temperature' 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%soiltb 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%soiltb(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12361,& 'frame/module_domain.f: Failed to allocate grid%soiltb(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 = 'stepbl' grid%tail_statevars%DataName = 'STEPBL' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN PBL CALLS' 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%stepbl grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepbl=0 IF(okay_to_alloc.AND.in_use_for_config(id,'taucldi').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%taucldi(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12391,& 'frame/module_domain.f: Failed to allocate grid%taucldi(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%taucldi=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'taucldi' grid%tail_statevars%DataName = 'TAUCLDI' grid%tail_statevars%Description = 'CLOUD OPTICAL THICKNESS FOR ICE' 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%taucldi 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%taucldi(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12441,& 'frame/module_domain.f: Failed to allocate grid%taucldi(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'taucldc').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%taucldc(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12452,& 'frame/module_domain.f: Failed to allocate grid%taucldc(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%taucldc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'taucldc' grid%tail_statevars%DataName = 'TAUCLDC' grid%tail_statevars%Description = 'CLOUD OPTICAL THICKNESS FOR WATER' 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%taucldc 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%taucldc(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12502,& 'frame/module_domain.f: Failed to allocate grid%taucldc(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'defor11').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%defor11(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12513,& 'frame/module_domain.f: Failed to allocate grid%defor11(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%defor11=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'defor11' grid%tail_statevars%DataName = 'DEFOR11' grid%tail_statevars%Description = 'DEFORMATION 11' grid%tail_statevars%Units = '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%defor11 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%defor11(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12563,& 'frame/module_domain.f: Failed to allocate grid%defor11(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'defor22').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%defor22(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12574,& 'frame/module_domain.f: Failed to allocate grid%defor22(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%defor22=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'defor22' grid%tail_statevars%DataName = 'DEFOR22' grid%tail_statevars%Description = 'DEFORMATION 22' grid%tail_statevars%Units = '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%defor22 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%defor22(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12624,& 'frame/module_domain.f: Failed to allocate grid%defor22(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'defor12').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%defor12(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12635,& 'frame/module_domain.f: Failed to allocate grid%defor12(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%defor12=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'defor12' grid%tail_statevars%DataName = 'DEFOR12' grid%tail_statevars%Description = 'DEFORMATION 12' grid%tail_statevars%Units = '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%defor12 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%defor12(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12685,& 'frame/module_domain.f: Failed to allocate grid%defor12(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'defor33').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%defor33(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12696,& 'frame/module_domain.f: Failed to allocate grid%defor33(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%defor33=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'defor33' grid%tail_statevars%DataName = 'DEFOR33' grid%tail_statevars%Description = 'DEFORMATION 33' grid%tail_statevars%Units = '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%defor33 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%defor33(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12746,& 'frame/module_domain.f: Failed to allocate grid%defor33(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'defor13').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%defor13(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12757,& 'frame/module_domain.f: Failed to allocate grid%defor13(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%defor13=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'defor13' grid%tail_statevars%DataName = 'DEFOR13' grid%tail_statevars%Description = 'DEFORMATION 13' grid%tail_statevars%Units = '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%defor13 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%defor13(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12807,& 'frame/module_domain.f: Failed to allocate grid%defor13(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'defor23').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%defor23(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12818,& 'frame/module_domain.f: Failed to allocate grid%defor23(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%defor23=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'defor23' grid%tail_statevars%DataName = 'DEFOR23' grid%tail_statevars%Description = 'DEFORMATION 23' grid%tail_statevars%Units = '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%defor23 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%defor23(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12868,& 'frame/module_domain.f: Failed to allocate grid%defor23(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xkmv').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xkmv(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12879,& 'frame/module_domain.f: Failed to allocate grid%xkmv(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xkmv=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xkmv' grid%tail_statevars%DataName = 'XKMV' grid%tail_statevars%Description = 'VERTICAL EDDY VISCOSITY' grid%tail_statevars%Units = 'm2 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%xkmv 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%xkmv(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12929,& 'frame/module_domain.f: Failed to allocate grid%xkmv(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xkmh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xkmh(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12940,& 'frame/module_domain.f: Failed to allocate grid%xkmh(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xkmh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xkmh' grid%tail_statevars%DataName = 'XKMH' grid%tail_statevars%Description = 'HORIZONTAL EDDY VISCOSITY' grid%tail_statevars%Units = 'm2 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%xkmh 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%xkmh(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",12990,& 'frame/module_domain.f: Failed to allocate grid%xkmh(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xkhv').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xkhv(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13001,& 'frame/module_domain.f: Failed to allocate grid%xkhv(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xkhv=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xkhv' grid%tail_statevars%DataName = 'XKHV' grid%tail_statevars%Description = 'VERTICAL EDDY DIFFUSIVITY OF HEAT' grid%tail_statevars%Units = 'm2 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%xkhv 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%xkhv(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13051,& 'frame/module_domain.f: Failed to allocate grid%xkhv(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'xkhh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%xkhh(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13062,& 'frame/module_domain.f: Failed to allocate grid%xkhh(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%xkhh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'xkhh' grid%tail_statevars%DataName = 'XKHH' grid%tail_statevars%Description = 'HORIZONTAL EDDY DIFFUSIVITY OF HEAT' grid%tail_statevars%Units = 'm2 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%xkhh 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%xkhh(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13112,& 'frame/module_domain.f: Failed to allocate grid%xkhh(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'div').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%div(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13123,& 'frame/module_domain.f: Failed to allocate grid%div(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%div=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'div' grid%tail_statevars%DataName = 'DIV' grid%tail_statevars%Description = 'DIVERGENCE' grid%tail_statevars%Units = '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%div 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%div(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13173,& 'frame/module_domain.f: Failed to allocate grid%div(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'bn2').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%bn2(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13184,& 'frame/module_domain.f: Failed to allocate grid%bn2(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%bn2=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'bn2' grid%tail_statevars%DataName = 'BN2' grid%tail_statevars%Description = 'BRUNT-VAISALA FREQUENCY' grid%tail_statevars%Units = '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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%bn2 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%bn2(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13234,& 'frame/module_domain.f: Failed to allocate grid%bn2(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 = 'warm_rain' grid%tail_statevars%DataName = 'WARM_RAIN' grid%tail_statevars%Description = 'WARM_RAIN_LOGICAL' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'l' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%lfield_0d => grid%warm_rain grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%warm_rain=.FALSE. IF (.NOT.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 = 'adv_moist_cond' grid%tail_statevars%DataName = 'ADV_MOIST_COND' grid%tail_statevars%Description = 'ADVECT MOIST CONDENSATES LOGICAL' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'l' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%lfield_0d => grid%adv_moist_cond grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%adv_moist_cond=.FALSE. IF (.NOT.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 = 'save_topo_from_real' grid%tail_statevars%DataName = 'SAVE_TOPO_FROM_REAL' grid%tail_statevars%Description = '1=original topo from real/0=topo modified by WRF' grid%tail_statevars%Units = 'flag' 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%save_topo_from_real grid%tail_statevars%streams(1) = 167772161 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%save_topo_from_real=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 = 'stepfg' grid%tail_statevars%DataName = 'STEPFG' grid%tail_statevars%Description = 'NUMBER OF FUNDAMENTAL TIMESTEPS BETWEEN FDDA GRID CALLS' 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%stepfg grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097152 ENDIF IF ( setinitval .EQ. 3 ) grid%stepfg=0 IF(okay_to_alloc.AND.in_use_for_config(id,'rundgdten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rundgdten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13321,& 'frame/module_domain.f: Failed to allocate grid%rundgdten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rundgdten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rundgdten' grid%tail_statevars%DataName = 'RUNDGDTEN' grid%tail_statevars%Description = 'X WIND TENDENCY DUE TO FDDA GRID NUDGING' 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%rundgdten 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 = 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%rundgdten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13371,& 'frame/module_domain.f: Failed to allocate grid%rundgdten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rvndgdten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rvndgdten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13382,& 'frame/module_domain.f: Failed to allocate grid%rvndgdten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rvndgdten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rvndgdten' grid%tail_statevars%DataName = 'RVNDGDTEN' grid%tail_statevars%Description = 'Y WIND TENDENCY DUE TO FDDA GRID NUDGING' 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%rvndgdten 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 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%rvndgdten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13432,& 'frame/module_domain.f: Failed to allocate grid%rvndgdten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rthndgdten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rthndgdten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13443,& 'frame/module_domain.f: Failed to allocate grid%rthndgdten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rthndgdten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rthndgdten' grid%tail_statevars%DataName = 'RTHNDGDTEN' grid%tail_statevars%Description = 'THETA TENDENCY DUE TO FDDA GRID NUDGING' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_3d => grid%rthndgdten 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%rthndgdten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13493,& 'frame/module_domain.f: Failed to allocate grid%rthndgdten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rphndgdten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rphndgdten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13504,& 'frame/module_domain.f: Failed to allocate grid%rphndgdten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rphndgdten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rphndgdten' grid%tail_statevars%DataName = 'RPHNDGDTEN' grid%tail_statevars%Description = 'GEOPOTENTIAL TENDENCY DUE TO FDDA GRID NUDGING' grid%tail_statevars%Units = 'm2 s-3' 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%rphndgdten 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%rphndgdten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13554,& 'frame/module_domain.f: Failed to allocate grid%rphndgdten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rqvndgdten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rqvndgdten(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13565,& 'frame/module_domain.f: Failed to allocate grid%rqvndgdten(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rqvndgdten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rqvndgdten' grid%tail_statevars%DataName = 'RQVNDGDTEN' grid%tail_statevars%Description = 'Q_V TENDENCY DUE TO FDDA GRID NUDGING' 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%rqvndgdten 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%rqvndgdten(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13615,& 'frame/module_domain.f: Failed to allocate grid%rqvndgdten(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rmundgdten').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rmundgdten(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13626,& 'frame/module_domain.f: Failed to allocate grid%rmundgdten(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rmundgdten=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rmundgdten' grid%tail_statevars%DataName = 'RMUNDGDTEN' grid%tail_statevars%Description = 'MU TENDENCY DUE TO FDDA GRID NUDGING' grid%tail_statevars%Units = 'Pa 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%rmundgdten 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%rmundgdten(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13676,& 'frame/module_domain.f: Failed to allocate grid%rmundgdten(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fdda3d'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_fdda3d)) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_fdda3d)) * 4 ALLOCATE(grid%fdda3d(sm31:em31,sm32:em32,sm33:em33,num_fdda3d),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13687,& 'frame/module_domain.f: Failed to allocate grid%fdda3d(sm31:em31,sm32:em32,sm33:em33,num_fdda3d). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fdda3d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fdda3d' grid%tail_statevars%DataName = 'FDDA3D' 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%fdda3d grid%tail_statevars%num_table => fdda3d_num_table grid%tail_statevars%index_table => fdda3d_index_table grid%tail_statevars%boundary_table => fdda3d_boundary_table grid%tail_statevars%dname_table => fdda3d_dname_table grid%tail_statevars%desc_table => fdda3d_desc_table grid%tail_statevars%units_table => fdda3d_units_table grid%tail_statevars%streams_table => fdda3d_streams_table grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097168 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%fdda3d(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13744,& 'frame/module_domain.f: Failed to allocate grid%fdda3d(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'fdda2d'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((1)-(1)+1))*(((em33)-(sm33)+1)*num_fdda2d)) * 4 nba = & ((((em31)-(sm31)+1))*(((1)-(1)+1))*(((em33)-(sm33)+1)*num_fdda2d)) * 4 ALLOCATE(grid%fdda2d(sm31:em31,1:1,sm33:em33,num_fdda2d),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13755,& 'frame/module_domain.f: Failed to allocate grid%fdda2d(sm31:em31,1:1,sm33:em33,num_fdda2d). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%fdda2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'fdda2d' grid%tail_statevars%DataName = 'FDDA2D' 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 = 'Z' 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%fdda2d grid%tail_statevars%num_table => fdda2d_num_table grid%tail_statevars%index_table => fdda2d_index_table grid%tail_statevars%boundary_table => fdda2d_boundary_table grid%tail_statevars%dname_table => fdda2d_dname_table grid%tail_statevars%desc_table => fdda2d_desc_table grid%tail_statevars%units_table => fdda2d_units_table grid%tail_statevars%streams_table => fdda2d_streams_table grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097168 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_stag' grid%tail_statevars%dimname3 = 'south_north' ENDIF ELSE ALLOCATE(grid%fdda2d(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13812,& 'frame/module_domain.f: Failed to allocate grid%fdda2d(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u10_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u10_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13823,& 'frame/module_domain.f: Failed to allocate grid%u10_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u10_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u10_ndg_old' grid%tail_statevars%DataName = 'U10_NDG_OLD' grid%tail_statevars%Description = 'OLD U10 FOR SURFACE FDDA GRID NUDGING' 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 = '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%u10_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%u10_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13873,& 'frame/module_domain.f: Failed to allocate grid%u10_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'u10_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%u10_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13884,& 'frame/module_domain.f: Failed to allocate grid%u10_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%u10_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'u10_ndg_new' grid%tail_statevars%DataName = 'U10_NDG_NEW' grid%tail_statevars%Description = 'NEW U10 FOR SURFACE FDDA GRID NUDGING' 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 = '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%u10_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%u10_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13934,& 'frame/module_domain.f: Failed to allocate grid%u10_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v10_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v10_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13945,& 'frame/module_domain.f: Failed to allocate grid%v10_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v10_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v10_ndg_old' grid%tail_statevars%DataName = 'V10_NDG_OLD' grid%tail_statevars%Description = 'OLD V10 FOR SURFACE FDDA GRID NUDGING' 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 = '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%v10_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%v10_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",13995,& 'frame/module_domain.f: Failed to allocate grid%v10_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'v10_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%v10_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14006,& 'frame/module_domain.f: Failed to allocate grid%v10_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%v10_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'v10_ndg_new' grid%tail_statevars%DataName = 'V10_NDG_NEW' grid%tail_statevars%Description = 'NEW V10 FOR SURFACE FDDA GRID NUDGING' 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 = '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%v10_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%v10_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14056,& 'frame/module_domain.f: Failed to allocate grid%v10_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'t2_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%t2_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14067,& 'frame/module_domain.f: Failed to allocate grid%t2_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%t2_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 't2_ndg_old' grid%tail_statevars%DataName = 'T2_NDG_OLD' grid%tail_statevars%Description = 'OLD T2 FOR SURFACE FDDA GRID NUDGING' 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%t2_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%t2_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14117,& 'frame/module_domain.f: Failed to allocate grid%t2_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'t2_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%t2_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14128,& 'frame/module_domain.f: Failed to allocate grid%t2_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%t2_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 't2_ndg_new' grid%tail_statevars%DataName = 'T2_NDG_NEW' grid%tail_statevars%Description = 'NEW T2 FOR SURFACE FDDA GRID NUDGING' 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%t2_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%t2_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14178,& 'frame/module_domain.f: Failed to allocate grid%t2_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'th2_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%th2_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14189,& 'frame/module_domain.f: Failed to allocate grid%th2_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%th2_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'th2_ndg_old' grid%tail_statevars%DataName = 'TH2_NDG_OLD' grid%tail_statevars%Description = 'OLD TH2 FOR SURFACE FDDA GRID NUDGING' 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%th2_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%th2_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14239,& 'frame/module_domain.f: Failed to allocate grid%th2_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'th2_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%th2_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14250,& 'frame/module_domain.f: Failed to allocate grid%th2_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%th2_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'th2_ndg_new' grid%tail_statevars%DataName = 'TH2_NDG_NEW' grid%tail_statevars%Description = 'NEW TH2 FOR SURFACE FDDA GRID NUDGING' 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%th2_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%th2_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14300,& 'frame/module_domain.f: Failed to allocate grid%th2_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'q2_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%q2_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14311,& 'frame/module_domain.f: Failed to allocate grid%q2_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%q2_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'q2_ndg_old' grid%tail_statevars%DataName = 'Q2_NDG_OLD' grid%tail_statevars%Description = 'OLD Q2 FOR SURFACE FDDA GRID NUDGING' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%q2_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%q2_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14361,& 'frame/module_domain.f: Failed to allocate grid%q2_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'q2_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%q2_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14372,& 'frame/module_domain.f: Failed to allocate grid%q2_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%q2_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'q2_ndg_new' grid%tail_statevars%DataName = 'Q2_NDG_NEW' grid%tail_statevars%Description = 'NEW Q2 FOR SURFACE FDDA GRID NUDGING' grid%tail_statevars%Units = 'kg 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%q2_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%q2_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14422,& 'frame/module_domain.f: Failed to allocate grid%q2_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rh_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rh_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14433,& 'frame/module_domain.f: Failed to allocate grid%rh_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rh_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rh_ndg_old' grid%tail_statevars%DataName = 'RH_NDG_OLD' grid%tail_statevars%Description = 'OLD RH FOR SURFACE FDDA GRID NUDGING' 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%rh_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%rh_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14483,& 'frame/module_domain.f: Failed to allocate grid%rh_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'rh_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%rh_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14494,& 'frame/module_domain.f: Failed to allocate grid%rh_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%rh_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'rh_ndg_new' grid%tail_statevars%DataName = 'RH_NDG_NEW' grid%tail_statevars%Description = 'NEW RH FOR SURFACE FDDA GRID NUDGING' 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%rh_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%rh_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14544,& 'frame/module_domain.f: Failed to allocate grid%rh_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'psl_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%psl_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14555,& 'frame/module_domain.f: Failed to allocate grid%psl_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%psl_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'psl_ndg_old' grid%tail_statevars%DataName = 'PSL_NDG_OLD' grid%tail_statevars%Description = 'OLD PSL FOR SURFACE FDDA GRID NUDGING' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%psl_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%psl_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14605,& 'frame/module_domain.f: Failed to allocate grid%psl_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'psl_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%psl_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14616,& 'frame/module_domain.f: Failed to allocate grid%psl_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%psl_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'psl_ndg_new' grid%tail_statevars%DataName = 'PSL_NDG_NEW' grid%tail_statevars%Description = 'NEW PSL FOR SURFACE FDDA GRID NUDGING' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%psl_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%psl_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14666,& 'frame/module_domain.f: Failed to allocate grid%psl_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ps_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ps_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14677,& 'frame/module_domain.f: Failed to allocate grid%ps_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ps_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ps_ndg_old' grid%tail_statevars%DataName = 'PS_NDG_OLD' grid%tail_statevars%Description = 'OLD PS FOR SURFACE FDDA GRID NUDGING' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%ps_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%ps_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14727,& 'frame/module_domain.f: Failed to allocate grid%ps_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'ps_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%ps_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14738,& 'frame/module_domain.f: Failed to allocate grid%ps_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%ps_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'ps_ndg_new' grid%tail_statevars%DataName = 'PS_NDG_NEW' grid%tail_statevars%Description = 'NEW PS FOR SURFACE FDDA GRID NUDGING' 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 = .TRUE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%ps_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%ps_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14788,& 'frame/module_domain.f: Failed to allocate grid%ps_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tob_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tob_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14799,& 'frame/module_domain.f: Failed to allocate grid%tob_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tob_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tob_ndg_old' grid%tail_statevars%DataName = 'TOB_NDG_OLD' grid%tail_statevars%Description = 'OLD TOB FOR SURFACE FDDA GRID NUDGING' 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%tob_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%tob_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14849,& 'frame/module_domain.f: Failed to allocate grid%tob_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'odis_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%odis_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14860,& 'frame/module_domain.f: Failed to allocate grid%odis_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%odis_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'odis_ndg_old' grid%tail_statevars%DataName = 'ODIS_NDG_OLD' grid%tail_statevars%Description = 'OLD ODIS FOR SURFACE FDDA GRID NUDGING' grid%tail_statevars%Units = 'km' 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%odis_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%odis_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14910,& 'frame/module_domain.f: Failed to allocate grid%odis_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tob_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tob_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14921,& 'frame/module_domain.f: Failed to allocate grid%tob_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tob_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tob_ndg_new' grid%tail_statevars%DataName = 'TOB_NDG_NEW' grid%tail_statevars%Description = 'NEW TOB FOR SURFACE FDDA GRID NUDGING' 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%tob_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%tob_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14971,& 'frame/module_domain.f: Failed to allocate grid%tob_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'odis_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%odis_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",14982,& 'frame/module_domain.f: Failed to allocate grid%odis_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%odis_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'odis_ndg_new' grid%tail_statevars%DataName = 'ODIS_NDG_NEW' grid%tail_statevars%Description = 'NEW ODIS FOR SURFACE FDDA GRID NUDGING' grid%tail_statevars%Units = 'km' 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%odis_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%odis_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15032,& 'frame/module_domain.f: Failed to allocate grid%odis_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sn_ndg_new').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sn_ndg_new(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15043,& 'frame/module_domain.f: Failed to allocate grid%sn_ndg_new(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sn_ndg_new=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sn_ndg_new' grid%tail_statevars%DataName = 'SN_NDG_NEW' grid%tail_statevars%Description = 'NEW Snow Water Equivalent' grid%tail_statevars%Units = 'mm' 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%sn_ndg_new grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%sn_ndg_new(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15093,& 'frame/module_domain.f: Failed to allocate grid%sn_ndg_new(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sn_ndg_old').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sn_ndg_old(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15104,& 'frame/module_domain.f: Failed to allocate grid%sn_ndg_old(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sn_ndg_old=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sn_ndg_old' grid%tail_statevars%DataName = 'SN_NDG_OLD' grid%tail_statevars%Description = 'OLD Snow Water Equivalent' grid%tail_statevars%Units = 'mm' 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%sn_ndg_old grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 2097160 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%sn_ndg_old(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15154,& 'frame/module_domain.f: Failed to allocate grid%sn_ndg_old(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sda_hfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sda_hfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15165,& 'frame/module_domain.f: Failed to allocate grid%sda_hfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sda_hfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sda_hfx' grid%tail_statevars%DataName = 'SDA_HFX' grid%tail_statevars%Description = 'THETA TENDENCY AT THE FIRST MODEL LAYER' grid%tail_statevars%Units = 'K 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%sda_hfx 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%sda_hfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15215,& 'frame/module_domain.f: Failed to allocate grid%sda_hfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'sda_qfx').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%sda_qfx(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15226,& 'frame/module_domain.f: Failed to allocate grid%sda_qfx(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%sda_qfx=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'sda_qfx' grid%tail_statevars%DataName = 'SDA_QFX' grid%tail_statevars%Description = 'MOISTURE TENDENCY AT THE FIRST MODEL LAYER' grid%tail_statevars%Units = 'kg kg-1 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%sda_qfx 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%sda_qfx(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15276,& 'frame/module_domain.f: Failed to allocate grid%sda_qfx(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qnorm').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qnorm(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15287,& 'frame/module_domain.f: Failed to allocate grid%qnorm(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qnorm=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qnorm' grid%tail_statevars%DataName = 'QNORM' grid%tail_statevars%Description = 'NORMALIZED QV FACTOR' grid%tail_statevars%Units = 'dimless' 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%qnorm 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%qnorm(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15337,& 'frame/module_domain.f: Failed to allocate grid%qnorm(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hfx_both').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hfx_both(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15348,& 'frame/module_domain.f: Failed to allocate grid%hfx_both(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hfx_both=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hfx_both' grid%tail_statevars%DataName = 'HFX_BOTH' grid%tail_statevars%Description = 'UPWARD HEAT FLUX AT THE SURFACE' 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 = '' 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%hfx_both 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%hfx_both(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15398,& 'frame/module_domain.f: Failed to allocate grid%hfx_both(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'qfx_both').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%qfx_both(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15409,& 'frame/module_domain.f: Failed to allocate grid%qfx_both(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%qfx_both=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'qfx_both' grid%tail_statevars%DataName = 'QFX_BOTH' grid%tail_statevars%Description = 'UPWARD MOISTURE FLUX AT THE SURFACE' grid%tail_statevars%Units = 'kg m-2 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%qfx_both 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%qfx_both(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15459,& 'frame/module_domain.f: Failed to allocate grid%qfx_both(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hfx_fdda').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hfx_fdda(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15470,& 'frame/module_domain.f: Failed to allocate grid%hfx_fdda(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hfx_fdda=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hfx_fdda' grid%tail_statevars%DataName = 'HFX_FDDA' grid%tail_statevars%Description = 'PSEUDO RADIATIVE HEAT FLUX FROM TEMPERATURE FDDA' 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 = '' 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%hfx_fdda 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%hfx_fdda(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15520,& 'frame/module_domain.f: Failed to allocate grid%hfx_fdda(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 = 'moved' grid%tail_statevars%DataName = 'MOVED' grid%tail_statevars%Description = '-' grid%tail_statevars%Units = '-' grid%tail_statevars%Type = 'l' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%Ndim = 0 grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%lfield_0d => grid%moved grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%moved=.FALSE. IF(okay_to_alloc.AND.in_use_for_config(id,'abstot').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((model_config_rec%cam_abs_dim2)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((model_config_rec%cam_abs_dim2)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%abstot(sm31:em31,sm32:em32,1:model_config_rec%cam_abs_dim2,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15550,& 'frame/module_domain.f: Failed to allocate grid%abstot(sm31:em31,sm32:em32,1:model_config_rec%cam_abs_dim2,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%abstot=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'abstot' grid%tail_statevars%DataName = 'ABSTOT' grid%tail_statevars%Description = '' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZZ' grid%tail_statevars%Stagger = 'Z' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%abstot 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 = 1 grid%tail_statevars%ed3 = config_flags%cam_abs_dim2 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = config_flags%cam_abs_dim2 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 = 1 grid%tail_statevars%ep3 = config_flags%cam_abs_dim2 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top_stag' grid%tail_statevars%dimname3 = 'cam_abs_dim2_stag' ENDIF ELSE ALLOCATE(grid%abstot(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15599,& 'frame/module_domain.f: Failed to allocate grid%abstot(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'absnxt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((model_config_rec%cam_abs_dim1)-(1)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((model_config_rec%cam_abs_dim1)-(1)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%absnxt(sm31:em31,sm32:em32,1:model_config_rec%cam_abs_dim1,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15610,& 'frame/module_domain.f: Failed to allocate grid%absnxt(sm31:em31,sm32:em32,1:model_config_rec%cam_abs_dim1,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%absnxt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'absnxt' grid%tail_statevars%DataName = 'ABSNXT' grid%tail_statevars%Description = '' grid%tail_statevars%Units = ' ' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'XZC' grid%tail_statevars%Stagger = '' grid%tail_statevars%Ntl = 0 grid%tail_statevars%Ndim = 4 grid%tail_statevars%Restart = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_4d => grid%absnxt 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 = 1 grid%tail_statevars%ed3 = config_flags%cam_abs_dim1 grid%tail_statevars%sm1 = ims grid%tail_statevars%em1 = ime grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = config_flags%cam_abs_dim1 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 = 1 grid%tail_statevars%ep3 = config_flags%cam_abs_dim1 grid%tail_statevars%subgrid_x = .FALSE. grid%tail_statevars%dimname1 = 'west_east' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%absnxt(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15659,& 'frame/module_domain.f: Failed to allocate grid%absnxt(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'emstot').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%emstot(sm31:em31,sm32:em32,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15670,& 'frame/module_domain.f: Failed to allocate grid%emstot(sm31:em31,sm32:em32,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%emstot=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'emstot' grid%tail_statevars%DataName = 'EMSTOT' 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 = '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%emstot 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%emstot(1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15720,& 'frame/module_domain.f: Failed to allocate grid%emstot(1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dpsdt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dpsdt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15731,& 'frame/module_domain.f: Failed to allocate grid%dpsdt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dpsdt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dpsdt' grid%tail_statevars%DataName = 'DPSDT' grid%tail_statevars%Description = 'surface pressure tendency' grid%tail_statevars%Units = 'Pa/sec' 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%dpsdt 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 = 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%dpsdt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15781,& 'frame/module_domain.f: Failed to allocate grid%dpsdt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'dmudt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%dmudt(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15792,& 'frame/module_domain.f: Failed to allocate grid%dmudt(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%dmudt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'dmudt' grid%tail_statevars%DataName = 'DMUDT' grid%tail_statevars%Description = 'mu tendency' grid%tail_statevars%Units = 'Pa/sec' 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%dmudt 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 = 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%dmudt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15842,& 'frame/module_domain.f: Failed to allocate grid%dmudt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'pk1m').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%pk1m(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15853,& 'frame/module_domain.f: Failed to allocate grid%pk1m(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%pk1m=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'pk1m' grid%tail_statevars%DataName = 'PK1M' grid%tail_statevars%Description = 'surface pressure at previous step' 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%pk1m 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 = 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%pk1m(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15903,& 'frame/module_domain.f: Failed to allocate grid%pk1m(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'mu_2m').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%mu_2m(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15914,& 'frame/module_domain.f: Failed to allocate grid%mu_2m(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%mu_2m=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'mu_2m' grid%tail_statevars%DataName = 'MU_2M' grid%tail_statevars%Description = 'mu_2 at previous step' 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%mu_2m 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 = 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%mu_2m(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15964,& 'frame/module_domain.f: Failed to allocate grid%mu_2m(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'wspd10max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%wspd10max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",15975,& 'frame/module_domain.f: Failed to allocate grid%wspd10max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%wspd10max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'wspd10max' grid%tail_statevars%DataName = 'WSPD10MAX' grid%tail_statevars%Description = 'WIND SPD MAX 10 M' 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%wspd10max grid%tail_statevars%streams(1) = 5 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%wspd10max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16025,& 'frame/module_domain.f: Failed to allocate grid%wspd10max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'w_up_max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%w_up_max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16036,& 'frame/module_domain.f: Failed to allocate grid%w_up_max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%w_up_max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'w_up_max' grid%tail_statevars%DataName = 'W_UP_MAX' grid%tail_statevars%Description = 'MAX Z-WIND UPDRAFT' 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%w_up_max grid%tail_statevars%streams(1) = 5 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%w_up_max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16086,& 'frame/module_domain.f: Failed to allocate grid%w_up_max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'w_dn_max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%w_dn_max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16097,& 'frame/module_domain.f: Failed to allocate grid%w_dn_max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%w_dn_max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'w_dn_max' grid%tail_statevars%DataName = 'W_DN_MAX' grid%tail_statevars%Description = 'MAX Z-WIND DOWNDRAFT' 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%w_dn_max grid%tail_statevars%streams(1) = 5 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%w_dn_max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16147,& 'frame/module_domain.f: Failed to allocate grid%w_dn_max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'refd_max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%refd_max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16158,& 'frame/module_domain.f: Failed to allocate grid%refd_max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%refd_max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'refd_max' grid%tail_statevars%DataName = 'REFD_MAX' grid%tail_statevars%Description = 'MAX DERIVED RADAR REFL' grid%tail_statevars%Units = 'dbZ' 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%refd_max grid%tail_statevars%streams(1) = 5 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%refd_max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16208,& 'frame/module_domain.f: Failed to allocate grid%refd_max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'up_heli_max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%up_heli_max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16219,& 'frame/module_domain.f: Failed to allocate grid%up_heli_max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%up_heli_max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'up_heli_max' grid%tail_statevars%DataName = 'UP_HELI_MAX' grid%tail_statevars%Description = 'MAX UPDRAFT HELICITY' 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%up_heli_max grid%tail_statevars%streams(1) = 5 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%up_heli_max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16269,& 'frame/module_domain.f: Failed to allocate grid%up_heli_max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'w_mean').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%w_mean(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16280,& 'frame/module_domain.f: Failed to allocate grid%w_mean(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%w_mean=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'w_mean' grid%tail_statevars%DataName = 'W_MEAN' grid%tail_statevars%Description = 'HOURLY MEAN Z-WIND' 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%w_mean 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%w_mean(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16330,& 'frame/module_domain.f: Failed to allocate grid%w_mean(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'grpl_max').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%grpl_max(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16341,& 'frame/module_domain.f: Failed to allocate grid%grpl_max(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%grpl_max=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'grpl_max' grid%tail_statevars%DataName = 'GRPL_MAX' grid%tail_statevars%Description = 'MAX COL INT GRAUPEL' grid%tail_statevars%Units = 'kg m-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%grpl_max 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%grpl_max(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16391,& 'frame/module_domain.f: Failed to allocate grid%grpl_max(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'uh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%uh(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16402,& 'frame/module_domain.f: Failed to allocate grid%uh(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%uh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'uh' grid%tail_statevars%DataName = 'UH' grid%tail_statevars%Description = 'UPDRAFT HELICITY' 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%uh 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%uh(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16452,& 'frame/module_domain.f: Failed to allocate grid%uh(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'w_colmean').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%w_colmean(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16463,& 'frame/module_domain.f: Failed to allocate grid%w_colmean(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%w_colmean=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'w_colmean' grid%tail_statevars%DataName = 'W_COLMEAN' grid%tail_statevars%Description = 'COLUMN MEAN Z-WIND' 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%w_colmean 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 = 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%w_colmean(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16513,& 'frame/module_domain.f: Failed to allocate grid%w_colmean(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'numcolpts').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%numcolpts(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16524,& 'frame/module_domain.f: Failed to allocate grid%numcolpts(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%numcolpts=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'numcolpts' grid%tail_statevars%DataName = 'NUMCOLPTS' grid%tail_statevars%Description = 'NUMBER OF COLUMN PTS' grid%tail_statevars%Units = 'dimensionless' 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%numcolpts 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 = 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%numcolpts(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16574,& 'frame/module_domain.f: Failed to allocate grid%numcolpts(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'grpl_colint').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%grpl_colint(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16585,& 'frame/module_domain.f: Failed to allocate grid%grpl_colint(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%grpl_colint=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'grpl_colint' grid%tail_statevars%DataName = 'GRPL_COLINT' grid%tail_statevars%Description = 'COL INT GRAUPEL' grid%tail_statevars%Units = 'kg m-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 = .FALSE. grid%tail_statevars%scalar_array = .FALSE. grid%tail_statevars%rfield_2d => grid%grpl_colint 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 = 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%grpl_colint(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16635,& 'frame/module_domain.f: Failed to allocate grid%grpl_colint(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hail_maxk1').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hail_maxk1(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16646,& 'frame/module_domain.f: Failed to allocate grid%hail_maxk1(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hail_maxk1=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hail_maxk1' grid%tail_statevars%DataName = 'HAIL_MAXK1' grid%tail_statevars%Description = 'MAX HAIL DIAMETER K=1' grid%tail_statevars%Units = 'm' 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%hail_maxk1 grid%tail_statevars%streams(1) = 5 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%hail_maxk1(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16696,& 'frame/module_domain.f: Failed to allocate grid%hail_maxk1(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hail_max2d').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hail_max2d(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16707,& 'frame/module_domain.f: Failed to allocate grid%hail_max2d(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hail_max2d=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hail_max2d' grid%tail_statevars%DataName = 'HAIL_MAX2D' grid%tail_statevars%Description = 'MAX HAIL DIAMETER ENTIRE COLUMN' grid%tail_statevars%Units = 'm' 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%hail_max2d grid%tail_statevars%streams(1) = 5 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%hail_max2d(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16757,& 'frame/module_domain.f: Failed to allocate grid%hail_max2d(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 = 'max_cfl' grid%tail_statevars%DataName = 'MAX_CFL' grid%tail_statevars%Description = 'maximum CFL value in grid at a time' 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%max_cfl grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 ENDIF IF ( setinitval .EQ. 3 ) grid%max_cfl=initial_data_value IF(okay_to_alloc.AND.in_use_for_config(id,'prec_acc_c'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%prec_acc_c(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16787,& 'frame/module_domain.f: Failed to allocate grid%prec_acc_c(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%prec_acc_c=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'prec_acc_c' grid%tail_statevars%DataName = 'PREC_ACC_C' grid%tail_statevars%Description = 'ACCUMULATED CUMULUS PRECIPITATION OVER prec_acc_dt PERIODS OF TIME' grid%tail_statevars%Units = 'mm' 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%prec_acc_c 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%prec_acc_c(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16837,& 'frame/module_domain.f: Failed to allocate grid%prec_acc_c(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'prec_acc_nc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%prec_acc_nc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16848,& 'frame/module_domain.f: Failed to allocate grid%prec_acc_nc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%prec_acc_nc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'prec_acc_nc' grid%tail_statevars%DataName = 'PREC_ACC_NC' grid%tail_statevars%Description = 'ACCUMULATED GRID SCALE PRECIPITATION OVER prec_acc_dt PERIODS OF TIME' grid%tail_statevars%Units = 'mm' 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%prec_acc_nc 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%prec_acc_nc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16898,& 'frame/module_domain.f: Failed to allocate grid%prec_acc_nc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'snow_acc_nc'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%snow_acc_nc(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16909,& 'frame/module_domain.f: Failed to allocate grid%snow_acc_nc(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%snow_acc_nc=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'snow_acc_nc' grid%tail_statevars%DataName = 'SNOW_ACC_NC' grid%tail_statevars%Description = 'ACCUMULATED SNOW WATER EQUIVALENT OVER prec_acc_dt PERIODS OF TIME' grid%tail_statevars%Units = 'mm' 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%snow_acc_nc 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%snow_acc_nc(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16959,& 'frame/module_domain.f: Failed to allocate grid%snow_acc_nc(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'advh_t'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_advh_t)) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_advh_t)) * 4 ALLOCATE(grid%advh_t(sm31:em31,sm32:em32,sm33:em33,num_advh_t),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",16970,& 'frame/module_domain.f: Failed to allocate grid%advh_t(sm31:em31,sm32:em32,sm33:em33,num_advh_t). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%advh_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%VarName = 'advh_t' grid%tail_statevars%DataName = 'ADVH_T' 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%advh_t grid%tail_statevars%num_table => advh_t_num_table grid%tail_statevars%index_table => advh_t_index_table grid%tail_statevars%boundary_table => advh_t_boundary_table grid%tail_statevars%dname_table => advh_t_dname_table grid%tail_statevars%desc_table => advh_t_desc_table grid%tail_statevars%units_table => advh_t_units_table grid%tail_statevars%streams_table => advh_t_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%advh_t(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17027,& 'frame/module_domain.f: Failed to allocate grid%advh_t(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'advz_t'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_advz_t)) * 4 nba = & ((((em31)-(sm31)+1))*(((em32)-(sm32)+1))*(((em33)-(sm33)+1)*num_advz_t)) * 4 ALLOCATE(grid%advz_t(sm31:em31,sm32:em32,sm33:em33,num_advz_t),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17038,& 'frame/module_domain.f: Failed to allocate grid%advz_t(sm31:em31,sm32:em32,sm33:em33,num_advz_t). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%advz_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%VarName = 'advz_t' grid%tail_statevars%DataName = 'ADVZ_T' 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%advz_t grid%tail_statevars%num_table => advz_t_num_table grid%tail_statevars%index_table => advz_t_index_table grid%tail_statevars%boundary_table => advz_t_boundary_table grid%tail_statevars%dname_table => advz_t_dname_table grid%tail_statevars%desc_table => advz_t_desc_table grid%tail_statevars%units_table => advz_t_units_table grid%tail_statevars%streams_table => advz_t_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%advz_t(1,1,1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17095,& 'frame/module_domain.f: Failed to allocate grid%advz_t(1,1,1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17106,& 'frame/module_domain.f: Failed to allocate grid%tml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tml' grid%tail_statevars%DataName = 'TML' grid%tail_statevars%Description = 'OCEAN MIXED-LAYER TEMPERATURE' 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%tml 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%tml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17156,& 'frame/module_domain.f: Failed to allocate grid%tml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'t0ml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%t0ml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17167,& 'frame/module_domain.f: Failed to allocate grid%t0ml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%t0ml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 't0ml' grid%tail_statevars%DataName = 'T0ML' grid%tail_statevars%Description = 'INITIAL OCEAN MIXED-LAYER TEMPERATURE' 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%t0ml 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%t0ml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17217,& 'frame/module_domain.f: Failed to allocate grid%t0ml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17228,& 'frame/module_domain.f: Failed to allocate grid%hml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hml' grid%tail_statevars%DataName = 'HML' grid%tail_statevars%Description = 'OCEAN MIXED-LAYER DEPTH' grid%tail_statevars%Units = 'm' 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%hml 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%hml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17278,& 'frame/module_domain.f: Failed to allocate grid%hml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'h0ml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%h0ml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17289,& 'frame/module_domain.f: Failed to allocate grid%h0ml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%h0ml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'h0ml' grid%tail_statevars%DataName = 'H0ML' grid%tail_statevars%Description = 'INITIAL OCEAN MIXED-LAYER DEPTH' grid%tail_statevars%Units = 'm' 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%h0ml grid%tail_statevars%streams(1) = 234881025 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%h0ml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17339,& 'frame/module_domain.f: Failed to allocate grid%h0ml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'huml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%huml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17350,& 'frame/module_domain.f: Failed to allocate grid%huml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%huml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'huml' grid%tail_statevars%DataName = 'HUML' grid%tail_statevars%Description = 'OCEAN MIXED-LAYER DEPTH * U-CURRENT' grid%tail_statevars%Units = ' m2s-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%huml 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%huml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17400,& 'frame/module_domain.f: Failed to allocate grid%huml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'hvml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%hvml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17411,& 'frame/module_domain.f: Failed to allocate grid%hvml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%hvml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'hvml' grid%tail_statevars%DataName = 'HVML' grid%tail_statevars%Description = 'OCEAN MIXED-LAYER DEPTH * V-CURRENT' grid%tail_statevars%Units = ' m2s-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%hvml 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%hvml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17461,& 'frame/module_domain.f: Failed to allocate grid%hvml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'tmoml'))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%tmoml(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17472,& 'frame/module_domain.f: Failed to allocate grid%tmoml(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%tmoml=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'tmoml' grid%tail_statevars%DataName = 'TMOML' grid%tail_statevars%Description = 'OCEAN LAYER MEAN TEMPERATURE ' 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%tmoml grid%tail_statevars%streams(1) = 234881025 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%tmoml(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17522,& 'frame/module_domain.f: Failed to allocate grid%tmoml(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_z').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_z(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17533,& 'frame/module_domain.f: Failed to allocate grid%track_z(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_z=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_z' grid%tail_statevars%DataName = 'TRACK_Z' grid%tail_statevars%Description = 'mid-level Height' grid%tail_statevars%Units = 'm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_z grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_z(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17581,& 'frame/module_domain.f: Failed to allocate grid%track_z(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_t').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_t(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17592,& 'frame/module_domain.f: Failed to allocate grid%track_t(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_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%VarName = 'track_t' grid%tail_statevars%DataName = 'TRACK_T' grid%tail_statevars%Description = 'mid-level temperature' grid%tail_statevars%Units = 'K' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_t grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_t(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17640,& 'frame/module_domain.f: Failed to allocate grid%track_t(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_p').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_p(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17651,& 'frame/module_domain.f: Failed to allocate grid%track_p(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_p=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_p' grid%tail_statevars%DataName = 'TRACK_P' grid%tail_statevars%Description = 'mid-level pressure' grid%tail_statevars%Units = 'Pa' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_p grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_p(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17699,& 'frame/module_domain.f: Failed to allocate grid%track_p(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_u').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_u(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17710,& 'frame/module_domain.f: Failed to allocate grid%track_u(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_u=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_u' grid%tail_statevars%DataName = 'TRACK_U' grid%tail_statevars%Description = 'x-wind component' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_u grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_u(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17758,& 'frame/module_domain.f: Failed to allocate grid%track_u(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_v').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_v(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17769,& 'frame/module_domain.f: Failed to allocate grid%track_v(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_v=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_v' grid%tail_statevars%DataName = 'TRACK_V' grid%tail_statevars%Description = 'y-wind component' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_v grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_v(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17817,& 'frame/module_domain.f: Failed to allocate grid%track_v(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_w').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_w(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17828,& 'frame/module_domain.f: Failed to allocate grid%track_w(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_w=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_w' grid%tail_statevars%DataName = 'TRACK_W' grid%tail_statevars%Description = 'z-wind component' grid%tail_statevars%Units = 'm s-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_w grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_w(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17876,& 'frame/module_domain.f: Failed to allocate grid%track_w(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_rh').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_rh(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17887,& 'frame/module_domain.f: Failed to allocate grid%track_rh(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_rh=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_rh' grid%tail_statevars%DataName = 'TRACK_RH' grid%tail_statevars%Description = 'relative humidity' grid%tail_statevars%Units = '0 - 1 fraction' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_rh grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_rh(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17935,& 'frame/module_domain.f: Failed to allocate grid%track_rh(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_alt').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_alt(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17946,& 'frame/module_domain.f: Failed to allocate grid%track_alt(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_alt=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_alt' grid%tail_statevars%DataName = 'TRACK_ALT' grid%tail_statevars%Description = 'inverse density' grid%tail_statevars%Units = 'm3 kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_alt grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_alt(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",17994,& 'frame/module_domain.f: Failed to allocate grid%track_alt(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_ele').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))) * 4 ALLOCATE(grid%track_ele(1:model_config_rec%track_loc_in),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18005,& 'frame/module_domain.f: Failed to allocate grid%track_ele(1:model_config_rec%track_loc_in). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_ele=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_ele' grid%tail_statevars%DataName = 'TRACK_ELE' grid%tail_statevars%Description = 'elevation' grid%tail_statevars%Units = 'm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'C' 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%track_ele grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in 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 = config_flags%track_loc_in 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 = config_flags%track_loc_in grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_ele(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18053,& 'frame/module_domain.f: Failed to allocate grid%track_ele(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_aircraft').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))) * 4 ALLOCATE(grid%track_aircraft(1:model_config_rec%track_loc_in),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18064,& 'frame/module_domain.f: Failed to allocate grid%track_aircraft(1:model_config_rec%track_loc_in). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_aircraft=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_aircraft' grid%tail_statevars%DataName = 'TRACK_AIRCRAFT' grid%tail_statevars%Description = 'aircraft altitude' grid%tail_statevars%Units = 'm' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'C' 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%track_aircraft grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in 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 = config_flags%track_loc_in 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 = config_flags%track_loc_in grid%tail_statevars%sp2 = 1 grid%tail_statevars%ep2 = 1 grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = '' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_aircraft(1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18112,& 'frame/module_domain.f: Failed to allocate grid%track_aircraft(1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_qcloud').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_qcloud(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18123,& 'frame/module_domain.f: Failed to allocate grid%track_qcloud(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_qcloud=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_qcloud' grid%tail_statevars%DataName = 'TRACK_QCLOUD' grid%tail_statevars%Description = 'cloud water mixing ratio' grid%tail_statevars%Units = 'kg kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_qcloud grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_qcloud(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18171,& 'frame/module_domain.f: Failed to allocate grid%track_qcloud(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_qrain').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_qrain(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18182,& 'frame/module_domain.f: Failed to allocate grid%track_qrain(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_qrain=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_qrain' grid%tail_statevars%DataName = 'TRACK_QRAIN' grid%tail_statevars%Description = 'rain water mixing ratio' grid%tail_statevars%Units = 'kg kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_qrain grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_qrain(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18230,& 'frame/module_domain.f: Failed to allocate grid%track_qrain(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_qice').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_qice(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18241,& 'frame/module_domain.f: Failed to allocate grid%track_qice(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_qice=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_qice' grid%tail_statevars%DataName = 'TRACK_QICE' grid%tail_statevars%Description = 'ice mixing ratio' grid%tail_statevars%Units = 'kg kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_qice grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_qice(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18289,& 'frame/module_domain.f: Failed to allocate grid%track_qice(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_qsnow').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_qsnow(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18300,& 'frame/module_domain.f: Failed to allocate grid%track_qsnow(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_qsnow=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_qsnow' grid%tail_statevars%DataName = 'TRACK_QSNOW' grid%tail_statevars%Description = 'snow mixing ratio' grid%tail_statevars%Units = 'kg kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_qsnow grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_qsnow(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18348,& 'frame/module_domain.f: Failed to allocate grid%track_qsnow(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_qgraup').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_qgraup(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18359,& 'frame/module_domain.f: Failed to allocate grid%track_qgraup(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_qgraup=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_qgraup' grid%tail_statevars%DataName = 'TRACK_QGRAUP' grid%tail_statevars%Description = 'graupel mixing ratio' grid%tail_statevars%Units = 'kg kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_qgraup grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_qgraup(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18407,& 'frame/module_domain.f: Failed to allocate grid%track_qgraup(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'track_qvapor').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 nba = & ((((model_config_rec%track_loc_in)-(1)+1))*(((em32)-(sm32)+1))) * 4 ALLOCATE(grid%track_qvapor(1:model_config_rec%track_loc_in,sm32:em32),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18418,& 'frame/module_domain.f: Failed to allocate grid%track_qvapor(1:model_config_rec%track_loc_in,sm32:em32). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%track_qvapor=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'track_qvapor' grid%tail_statevars%DataName = 'TRACK_QVAPOR' grid%tail_statevars%Description = 'water vapor mixing ratio' grid%tail_statevars%Units = 'kg kg-1' grid%tail_statevars%Type = 'r' grid%tail_statevars%ProcOrient = ' ' grid%tail_statevars%MemoryOrder = 'CZ' 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%track_qvapor grid%tail_statevars%streams(1) = 0 grid%tail_statevars%streams(2) = 0 grid%tail_statevars%sd1 = 1 grid%tail_statevars%ed1 = config_flags%track_loc_in grid%tail_statevars%sd2 = kds grid%tail_statevars%ed2 = (kde-1) grid%tail_statevars%sd3 = 1 grid%tail_statevars%ed3 = 1 grid%tail_statevars%sm1 = 1 grid%tail_statevars%em1 = config_flags%track_loc_in grid%tail_statevars%sm2 = kms grid%tail_statevars%em2 = kme grid%tail_statevars%sm3 = 1 grid%tail_statevars%em3 = 1 grid%tail_statevars%sp1 = 1 grid%tail_statevars%ep1 = config_flags%track_loc_in grid%tail_statevars%sp2 = kps grid%tail_statevars%ep2 = MIN( (kde-1), kpe ) grid%tail_statevars%sp3 = 1 grid%tail_statevars%ep3 = 1 grid%tail_statevars%dimname1 = '' grid%tail_statevars%dimname2 = 'bottom_top' grid%tail_statevars%dimname3 = '' ENDIF ELSE ALLOCATE(grid%track_qvapor(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18466,& 'frame/module_domain.f: Failed to allocate grid%track_qvapor(1,1). ') endif ENDIF IF ( setinitval .EQ. 3 ) grid%run_days=0 IF ( setinitval .EQ. 3 ) grid%run_hours=0 IF ( setinitval .EQ. 3 ) grid%run_minutes=0 IF ( setinitval .EQ. 3 ) grid%run_seconds=0 IF ( setinitval .EQ. 3 ) grid%start_year=0 IF ( setinitval .EQ. 3 ) grid%start_month=0 IF ( setinitval .EQ. 3 ) grid%start_day=0 IF ( setinitval .EQ. 3 ) grid%start_hour=0 IF ( setinitval .EQ. 3 ) grid%start_minute=0 IF ( setinitval .EQ. 3 ) grid%start_second=0 IF ( setinitval .EQ. 3 ) grid%end_year=0 IF ( setinitval .EQ. 3 ) grid%end_month=0 IF ( setinitval .EQ. 3 ) grid%end_day=0 IF ( setinitval .EQ. 3 ) grid%end_hour=0 IF ( setinitval .EQ. 3 ) grid%end_minute=0 IF ( setinitval .EQ. 3 ) grid%end_second=0 IF ( setinitval .EQ. 3 ) grid%interval_seconds=0 IF ( setinitval .EQ. 3 ) grid%input_from_file=.FALSE. IF ( setinitval .EQ. 3 ) grid%fine_input_stream=0 IF ( setinitval .EQ. 3 ) grid%input_from_hires=.FALSE. IF ( setinitval .EQ. 3 ) grid%all_ic_times=.FALSE. IF ( setinitval .EQ. 3 ) grid%julyr=0 IF ( setinitval .EQ. 3 ) grid%julday=0 IF ( setinitval .EQ. 3 ) grid%gmt=initial_data_value IF ( setinitval .EQ. 3 ) grid%write_input=.FALSE. IF ( setinitval .EQ. 3 ) grid%write_restart_at_0h=.FALSE. IF ( setinitval .EQ. 3 ) grid%write_hist_at_0h_rst=.FALSE. IF ( setinitval .EQ. 3 ) grid%adjust_output_times=.FALSE. IF ( setinitval .EQ. 3 ) grid%adjust_input_times=.FALSE. IF ( setinitval .EQ. 3 ) grid%diag_print=0 IF ( setinitval .EQ. 3 ) grid%nocolons=.FALSE. IF ( setinitval .EQ. 3 ) grid%cycling=.FALSE. IF ( setinitval .EQ. 3 ) grid%output_diagnostics=0 IF ( setinitval .EQ. 3 ) grid%nwp_diagnostics=0 IF ( setinitval .EQ. 3 ) grid%output_ready_flag=.FALSE. IF ( setinitval .EQ. 3 ) grid%force_use_old_data=.FALSE. IF ( setinitval .EQ. 3 ) grid%usepio=.FALSE. IF ( setinitval .EQ. 3 ) grid%pioprocs=0 IF ( setinitval .EQ. 3 ) grid%piostart=0 IF ( setinitval .EQ. 3 ) grid%piostride=0 IF ( setinitval .EQ. 3 ) grid%pioshift=0 IF ( setinitval .EQ. 3 ) grid%dfi_opt=0 IF ( setinitval .EQ. 3 ) grid%dfi_savehydmeteors=0 IF ( setinitval .EQ. 3 ) grid%dfi_nfilter=0 IF ( setinitval .EQ. 3 ) grid%dfi_write_filtered_input=.FALSE. IF ( setinitval .EQ. 3 ) grid%dfi_write_dfi_history=.FALSE. IF ( setinitval .EQ. 3 ) grid%dfi_cutoff_seconds=0 IF ( setinitval .EQ. 3 ) grid%dfi_time_dim=0 IF ( setinitval .EQ. 3 ) grid%dfi_fwdstop_year=0 IF ( setinitval .EQ. 3 ) grid%dfi_fwdstop_month=0 IF ( setinitval .EQ. 3 ) grid%dfi_fwdstop_day=0 IF ( setinitval .EQ. 3 ) grid%dfi_fwdstop_hour=0 IF ( setinitval .EQ. 3 ) grid%dfi_fwdstop_minute=0 IF ( setinitval .EQ. 3 ) grid%dfi_fwdstop_second=0 IF ( setinitval .EQ. 3 ) grid%dfi_bckstop_year=0 IF ( setinitval .EQ. 3 ) grid%dfi_bckstop_month=0 IF ( setinitval .EQ. 3 ) grid%dfi_bckstop_day=0 IF ( setinitval .EQ. 3 ) grid%dfi_bckstop_hour=0 IF ( setinitval .EQ. 3 ) grid%dfi_bckstop_minute=0 IF ( setinitval .EQ. 3 ) grid%dfi_bckstop_second=0 IF ( setinitval .EQ. 3 ) grid%time_step=0 IF ( setinitval .EQ. 3 ) grid%time_step_fract_num=0 IF ( setinitval .EQ. 3 ) grid%time_step_fract_den=0 IF ( setinitval .EQ. 3 ) grid%time_step_dfi=0 IF ( setinitval .EQ. 3 ) grid%reasonable_time_step_ratio=initial_data_value IF ( setinitval .EQ. 3 ) grid%min_time_step=0 IF ( setinitval .EQ. 3 ) grid%min_time_step_den=0 IF ( setinitval .EQ. 3 ) grid%max_time_step=0 IF ( setinitval .EQ. 3 ) grid%max_time_step_den=0 IF ( setinitval .EQ. 3 ) grid%target_cfl=initial_data_value IF ( setinitval .EQ. 3 ) grid%target_hcfl=initial_data_value IF ( setinitval .EQ. 3 ) grid%max_step_increase_pct=0 IF ( setinitval .EQ. 3 ) grid%starting_time_step=0 IF ( setinitval .EQ. 3 ) grid%starting_time_step_den=0 IF ( setinitval .EQ. 3 ) grid%step_to_output_time=.FALSE. IF ( setinitval .EQ. 3 ) grid%adaptation_domain=0 IF ( setinitval .EQ. 3 ) grid%use_adaptive_time_step=.FALSE. IF ( setinitval .EQ. 3 ) grid%use_adaptive_time_step_dfi=.FALSE. IF ( setinitval .EQ. 3 ) grid%max_dom=0 IF ( setinitval .EQ. 3 ) grid%lats_to_mic=0 IF ( setinitval .EQ. 3 ) grid%s_we=0 IF ( setinitval .EQ. 3 ) grid%e_we=0 IF ( setinitval .EQ. 3 ) grid%s_sn=0 IF ( setinitval .EQ. 3 ) grid%e_sn=0 IF ( setinitval .EQ. 3 ) grid%s_vert=0 IF ( setinitval .EQ. 3 ) grid%e_vert=0 IF ( setinitval .EQ. 3 ) grid%num_metgrid_levels=0 IF ( setinitval .EQ. 3 ) grid%num_metgrid_soil_levels=0 IF ( setinitval .EQ. 3 ) grid%p_top_requested=initial_data_value IF ( setinitval .EQ. 3 ) grid%interp_theta=.FALSE. IF ( setinitval .EQ. 3 ) grid%interp_type=0 IF ( setinitval .EQ. 3 ) grid%rebalance=0 IF ( setinitval .EQ. 3 ) grid%vert_refine_method=0 IF ( setinitval .EQ. 3 ) grid%vert_refine_fact=0 IF ( setinitval .EQ. 3 ) grid%extrap_type=0 IF ( setinitval .EQ. 3 ) grid%t_extrap_type=0 IF ( setinitval .EQ. 3 ) grid%hypsometric_opt=0 IF ( setinitval .EQ. 3 ) grid%lowest_lev_from_sfc=.FALSE. IF ( setinitval .EQ. 3 ) grid%use_levels_below_ground=.FALSE. IF ( setinitval .EQ. 3 ) grid%use_tavg_for_tsk=.FALSE. IF ( setinitval .EQ. 3 ) grid%use_surface=.FALSE. IF ( setinitval .EQ. 3 ) grid%lagrange_order=0 IF ( setinitval .EQ. 3 ) grid%linear_interp=0 IF ( setinitval .EQ. 3 ) grid%force_sfc_in_vinterp=0 IF ( setinitval .EQ. 3 ) grid%zap_close_levels=initial_data_value IF ( setinitval .EQ. 3 ) grid%maxw_horiz_pres_diff=initial_data_value IF ( setinitval .EQ. 3 ) grid%trop_horiz_pres_diff=initial_data_value IF ( setinitval .EQ. 3 ) grid%maxw_above_this_level=initial_data_value IF ( setinitval .EQ. 3 ) grid%use_maxw_level=0 IF ( setinitval .EQ. 3 ) grid%use_trop_level=0 IF ( setinitval .EQ. 3 ) grid%sfcp_to_sfcp=.FALSE. IF ( setinitval .EQ. 3 ) grid%adjust_heights=.FALSE. IF ( setinitval .EQ. 3 ) grid%smooth_cg_topo=.FALSE. IF ( setinitval .EQ. 3 ) grid%nest_interp_coord=0 IF ( setinitval .EQ. 3 ) grid%interp_method_type=0 IF ( setinitval .EQ. 3 ) grid%aggregate_lu=.FALSE. IF ( setinitval .EQ. 3 ) grid%rh2qv_wrt_liquid=.FALSE. IF ( setinitval .EQ. 3 ) grid%rh2qv_method=0 IF ( setinitval .EQ. 3 ) grid%qv_max_p_safe=initial_data_value IF ( setinitval .EQ. 3 ) grid%qv_max_flag=initial_data_value IF ( setinitval .EQ. 3 ) grid%qv_max_value=initial_data_value IF ( setinitval .EQ. 3 ) grid%qv_min_p_safe=initial_data_value IF ( setinitval .EQ. 3 ) grid%qv_min_flag=initial_data_value IF ( setinitval .EQ. 3 ) grid%qv_min_value=initial_data_value IF ( setinitval .EQ. 3 ) grid%ideal_init_method=0 IF ( setinitval .EQ. 3 ) grid%dx=initial_data_value IF ( setinitval .EQ. 3 ) grid%dy=initial_data_value IF ( setinitval .EQ. 3 ) grid%grid_id=0 IF ( setinitval .EQ. 3 ) grid%grid_allowed=.FALSE. IF ( setinitval .EQ. 3 ) grid%parent_id=0 IF ( setinitval .EQ. 3 ) grid%i_parent_start=0 IF ( setinitval .EQ. 3 ) grid%j_parent_start=0 IF ( setinitval .EQ. 3 ) grid%parent_grid_ratio=0 IF ( setinitval .EQ. 3 ) grid%parent_time_step_ratio=0 IF ( setinitval .EQ. 3 ) grid%feedback=0 IF ( setinitval .EQ. 3 ) grid%smooth_option=0 IF ( setinitval .EQ. 3 ) grid%blend_width=0 IF ( setinitval .EQ. 3 ) grid%ztop=initial_data_value IF ( setinitval .EQ. 3 ) grid%moad_grid_ratio=0 IF ( setinitval .EQ. 3 ) grid%moad_time_step_ratio=0 IF ( setinitval .EQ. 3 ) grid%shw=0 IF ( setinitval .EQ. 3 ) grid%tile_sz_x=0 IF ( setinitval .EQ. 3 ) grid%tile_sz_y=0 IF ( setinitval .EQ. 3 ) grid%numtiles=0 IF ( setinitval .EQ. 3 ) grid%numtiles_inc=0 IF ( setinitval .EQ. 3 ) grid%numtiles_x=0 IF ( setinitval .EQ. 3 ) grid%numtiles_y=0 IF ( setinitval .EQ. 3 ) grid%tile_strategy=0 IF ( setinitval .EQ. 3 ) grid%nproc_x=0 IF ( setinitval .EQ. 3 ) grid%nproc_y=0 IF ( setinitval .EQ. 3 ) grid%irand=0 IF ( setinitval .EQ. 3 ) grid%dt=initial_data_value IF ( setinitval .EQ. 3 ) grid%fft_used=0 IF ( setinitval .EQ. 3 ) grid%cu_used=0 IF ( setinitval .EQ. 3 ) grid%shcu_used=0 IF ( setinitval .EQ. 3 ) grid%cam_used=0 IF ( setinitval .EQ. 3 ) grid%gwd_used=0 IF ( setinitval .EQ. 3 ) grid%alloc_qndropsource=0 IF ( setinitval .EQ. 3 ) grid%num_moves=0 IF ( setinitval .EQ. 3 ) grid%ts_buf_size=0 IF ( setinitval .EQ. 3 ) grid%max_ts_locs=0 IF ( setinitval .EQ. 3 ) grid%tslist_ij=.FALSE. IF ( setinitval .EQ. 3 ) grid%tslist_unstagger_winds=.FALSE. IF ( setinitval .EQ. 3 ) grid%vortex_interval=0 IF ( setinitval .EQ. 3 ) grid%max_vortex_speed=0 IF ( setinitval .EQ. 3 ) grid%corral_dist=0 IF ( setinitval .EQ. 3 ) grid%track_level=0 IF ( setinitval .EQ. 3 ) grid%time_to_move=initial_data_value IF ( setinitval .EQ. 3 ) grid%move_id=0 IF ( setinitval .EQ. 3 ) grid%move_interval=0 IF ( setinitval .EQ. 3 ) grid%move_cd_x=0 IF ( setinitval .EQ. 3 ) grid%move_cd_y=0 IF ( setinitval .EQ. 3 ) grid%swap_x=.FALSE. IF ( setinitval .EQ. 3 ) grid%swap_y=.FALSE. IF ( setinitval .EQ. 3 ) grid%cycle_x=.FALSE. IF ( setinitval .EQ. 3 ) grid%cycle_y=.FALSE. IF ( setinitval .EQ. 3 ) grid%reorder_mesh=.FALSE. IF ( setinitval .EQ. 3 ) grid%perturb_input=.FALSE. IF ( setinitval .EQ. 3 ) grid%eta_levels=initial_data_value IF ( setinitval .EQ. 3 ) grid%auto_levels_opt=0 IF ( setinitval .EQ. 3 ) grid%max_dz=initial_data_value IF ( setinitval .EQ. 3 ) grid%dzbot=initial_data_value IF ( setinitval .EQ. 3 ) grid%dzstretch_s=initial_data_value IF ( setinitval .EQ. 3 ) grid%dzstretch_u=initial_data_value IF ( setinitval .EQ. 3 ) grid%ocean_levels=0 IF ( setinitval .EQ. 3 ) grid%ocean_z=initial_data_value IF ( setinitval .EQ. 3 ) grid%ocean_t=initial_data_value IF ( setinitval .EQ. 3 ) grid%ocean_s=initial_data_value IF ( setinitval .EQ. 3 ) grid%num_traj=0 IF ( setinitval .EQ. 3 ) grid%max_ts_level=0 IF ( setinitval .EQ. 3 ) grid%track_loc_in=0 IF ( setinitval .EQ. 3 ) grid%num_ext_model_couple_dom=0 IF ( setinitval .EQ. 3 ) grid%insert_bogus_storm=.FALSE. IF ( setinitval .EQ. 3 ) grid%remove_storm=.FALSE. IF ( setinitval .EQ. 3 ) grid%num_storm=0 IF ( setinitval .EQ. 3 ) grid%latc_loc=initial_data_value IF ( setinitval .EQ. 3 ) grid%lonc_loc=initial_data_value IF ( setinitval .EQ. 3 ) grid%vmax_meters_per_second=initial_data_value IF ( setinitval .EQ. 3 ) grid%rmax=initial_data_value IF ( setinitval .EQ. 3 ) grid%vmax_ratio=initial_data_value IF ( setinitval .EQ. 3 ) grid%rankine_lid=initial_data_value IF ( setinitval .EQ. 3 ) grid%force_read_thompson=.FALSE. IF ( setinitval .EQ. 3 ) grid%write_thompson_tables=.FALSE. IF ( setinitval .EQ. 3 ) grid%mp_physics=0 IF ( setinitval .EQ. 3 ) grid%nssl_cccn=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_alphah=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_alphahl=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_cnoh=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_cnohl=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_cnor=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_cnos=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_rho_qh=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_rho_qhl=initial_data_value IF ( setinitval .EQ. 3 ) grid%nssl_rho_qs=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_isbuffer=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_isbuffer_flux=.FALSE. IF(okay_to_alloc.AND.in_use_for_config(id,'buffer_u').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%buffer_u(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18693,& 'frame/module_domain.f: Failed to allocate grid%buffer_u(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%buffer_u=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'buffer_u' grid%tail_statevars%DataName = 'U_BUFFER' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' 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%buffer_u 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-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%buffer_u(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18743,& 'frame/module_domain.f: Failed to allocate grid%buffer_u(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'buffer_v').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%buffer_v(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18754,& 'frame/module_domain.f: Failed to allocate grid%buffer_v(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%buffer_v=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'buffer_v' grid%tail_statevars%DataName = 'V_BUFFER' grid%tail_statevars%Description = '' grid%tail_statevars%Units = '' 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%buffer_v grid%tail_statevars%streams(1) = 33554433 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%buffer_v(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18804,& 'frame/module_domain.f: Failed to allocate grid%buffer_v(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'buffer_w').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%buffer_w(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18815,& 'frame/module_domain.f: Failed to allocate grid%buffer_w(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%buffer_w=initial_data_value IF (.NOT.grid%is_intermediate) THEN ALLOCATE( grid%tail_statevars%next ) grid%tail_statevars => grid%tail_statevars%next NULLIFY( grid%tail_statevars%next ) grid%tail_statevars%VarName = 'buffer_w' grid%tail_statevars%DataName = 'W_BUFFER' grid%tail_statevars%Description = '' 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%buffer_w grid%tail_statevars%streams(1) = 33554433 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%buffer_w(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18865,& 'frame/module_domain.f: Failed to allocate grid%buffer_w(1,1). ') endif ENDIF IF(okay_to_alloc.AND.in_use_for_config(id,'buffer_t').AND.(.NOT.grid%is_intermediate))THEN num_bytes_allocated = num_bytes_allocated + & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 nba = & ((((em31)-(sm31)+1))*(((em33)-(sm33)+1))) * 4 ALLOCATE(grid%buffer_t(sm31:em31,sm33:em33),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18876,& 'frame/module_domain.f: Failed to allocate grid%buffer_t(sm31:em31,sm33:em33). ') endif IF ( setinitval .EQ. 1 .OR. setinitval .EQ. 3 ) grid%buffer_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%VarName = 'buffer_t' grid%tail_statevars%DataName = 'T_BUFFER' grid%tail_statevars%Description = '' 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%buffer_t grid%tail_statevars%streams(1) = 33554433 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%buffer_t(1,1),STAT=ierr) if (ierr.ne.0) then CALL wrf_error_fatal3("",18926,& 'frame/module_domain.f: Failed to allocate grid%buffer_t(1,1). ') endif ENDIF IF ( setinitval .EQ. 3 ) grid%asiv_tau_buffer=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_width_buffer=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_drycase=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_with_currents=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_phieq=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_lbeta=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_stretch_grid=0 IF ( setinitval .EQ. 3 ) grid%asiv_z_scale=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_ybeta=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_create_sst=0 IF ( setinitval .EQ. 3 ) grid%asiv_deltath_z=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_tau0eq=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_tau0pole=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_radflin=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_is_tau_front=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_is_tau_invert=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_ytau=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_ltau=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_use_tsk_tau=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_use_tsk_rad_bc=.FALSE. IF ( setinitval .EQ. 3 ) grid%asiv_ssteq=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_sstpole=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_ysst=initial_data_value IF ( setinitval .EQ. 3 ) grid%asiv_lsst=initial_data_value IF ( setinitval .EQ. 3 ) grid%nudge_lightning=0 IF ( setinitval .EQ. 3 ) grid%nudge_light_times=0 IF ( setinitval .EQ. 3 ) grid%nudge_light_timee=0 IF ( setinitval .EQ. 3 ) grid%nudge_light_int=0 IF ( setinitval .EQ. 3 ) grid%gsfcgce_hail=0 IF ( setinitval .EQ. 3 ) grid%gsfcgce_2ice=0 IF ( setinitval .EQ. 3 ) grid%progn=0 IF ( setinitval .EQ. 3 ) grid%accum_mode=initial_data_value IF ( setinitval .EQ. 3 ) grid%aitken_mode=initial_data_value IF ( setinitval .EQ. 3 ) grid%coarse_mode=initial_data_value IF ( setinitval .EQ. 3 ) grid%do_radar_ref=0 IF ( setinitval .EQ. 3 ) grid%compute_radar_ref=0 IF ( setinitval .EQ. 3 ) grid%ra_lw_physics=0 IF ( setinitval .EQ. 3 ) grid%ra_sw_physics=0 IF ( setinitval .EQ. 3 ) grid%radt=initial_data_value IF ( setinitval .EQ. 3 ) grid%naer=initial_data_value IF ( setinitval .EQ. 3 ) grid%sf_sfclay_physics=0 IF ( setinitval .EQ. 3 ) grid%sf_surf_irr_scheme=0 IF ( setinitval .EQ. 3 ) grid%sf_surf_irr_alloc=0 END SUBROUTINE alloc_space_field_core_2 END MODULE module_alloc_space_2