SCALE-RM
scale_landuse.F90
Go to the documentation of this file.
1 !-------------------------------------------------------------------------------
17 !-------------------------------------------------------------------------------
18 #include "scalelib.h"
20  !-----------------------------------------------------------------------------
21  !
22  !++ used modules
23  !
24  use scale_precision
25  use scale_io
26  use scale_prof
28  !-----------------------------------------------------------------------------
29  implicit none
30  private
31  !-----------------------------------------------------------------------------
32  !
33  !++ Public procedure
34  !
35  public :: landuse_setup
36  public :: landuse_calc_fact
37  public :: landuse_fillhalo
38  public :: landuse_write
39 
40  !-----------------------------------------------------------------------------
41  !
42  !++ Public parameters & variables
43  !
44  real(RP), public, allocatable :: landuse_fact_ocean(:,:)
45  real(RP), public, allocatable :: landuse_fact_land (:,:)
46  real(RP), public, allocatable :: landuse_fact_urban(:,:)
47  real(RP), public, allocatable :: landuse_fact_lake (:,:)
48 
49  logical, public, allocatable :: landuse_exists_ocean(:,:)
50  logical, public, allocatable :: landuse_exists_land (:,:)
51  logical, public, allocatable :: landuse_exists_urban(:,:)
52  logical, public, allocatable :: landuse_exists_lake (:,:)
53 
54  real(RP), public, allocatable :: landuse_frac_land (:,:)
55  real(RP), public, allocatable :: landuse_frac_urban(:,:)
56  real(RP), public, allocatable :: landuse_frac_lake (:,:)
57 
58  integer, public, parameter :: landuse_index_ocean = 0
59  integer, public, parameter :: landuse_index_urban = -1
60  integer, public, parameter :: landuse_index_lake = -2
61 
62  integer, public, parameter :: landuse_pft_nmin = -2
63  integer, public :: landuse_pft_nmax = 17
64  integer, public :: landuse_pft_mosaic = 2
65 
66  real(RP), public, allocatable :: landuse_frac_pft (:,:,:)
67  integer, public, allocatable :: landuse_index_pft(:,:,:)
68 
69  !-----------------------------------------------------------------------------
70  !
71  !++ Private procedure
72  !
73  private :: landuse_read
74 
75  !-----------------------------------------------------------------------------
76  !
77  !++ Private parameters & variables
78  !
79  character(len=H_LONG), private :: landuse_in_basename = ''
80  logical, private :: landuse_in_aggregate
81  logical, private :: landuse_in_check_coordinates = .true.
82  character(len=H_LONG), private :: landuse_out_basename = ''
83  logical, private :: landuse_out_aggregate
84  character(len=H_MID), private :: landuse_out_title = 'SCALE-RM LANDUSE'
85  character(len=H_SHORT), private :: landuse_out_dtype = 'DEFAULT'
86  logical, private :: landuse_allocean = .false.
87  logical, private :: landuse_allland = .false.
88  logical, private :: landuse_allurban = .false.
89  logical, private :: landuse_alllake = .false.
90  logical, private :: landuse_ignore_lake = .false.
91  logical, private :: landuse_mosaicworld = .false.
92 
93  !-----------------------------------------------------------------------------
94 contains
95  !-----------------------------------------------------------------------------
97  subroutine landuse_setup( &
98  OCEAN_do, &
99  URBAN_do, &
100  LAKE_do )
101  use scale_prc, only: &
102  prc_abort
103  use scale_file, only: &
105  implicit none
106 
107  logical, intent(in) :: OCEAN_do
108  logical, intent(in) :: URBAN_do
109  logical, intent(in) :: LAKE_do
110 
111  namelist / param_landuse / &
112  landuse_in_basename, &
113  landuse_in_aggregate, &
114  landuse_in_check_coordinates, &
115  landuse_out_basename, &
116  landuse_out_aggregate, &
117  landuse_out_dtype, &
120  landuse_allocean, &
121  landuse_allland, &
122  landuse_allurban, &
123  landuse_alllake, &
124  landuse_ignore_lake, &
125  landuse_mosaicworld
126 
127  integer :: ierr
128  !---------------------------------------------------------------------------
129 
130  log_newline
131  log_info("LANDUSE_setup",*) 'Setup'
132 
133  landuse_in_aggregate = file_aggregate
134  landuse_out_aggregate = file_aggregate
135 
136  !--- read namelist
137  rewind(io_fid_conf)
138  read(io_fid_conf,nml=param_landuse,iostat=ierr)
139  if( ierr < 0 ) then !--- missing
140  log_info("LANDUSE_setup",*) 'Not found namelist. Default used.'
141  elseif( ierr > 0 ) then !--- fatal error
142  log_error("LANDUSE_setup",*) 'Not appropriate names in namelist PARAM_LANDUSE. Check!'
143  call prc_abort
144  endif
145  log_nml(param_landuse)
146 
147  allocate( landuse_frac_land(ia,ja) )
148  allocate( landuse_frac_urban(ia,ja) )
149  allocate( landuse_frac_lake(ia,ja) )
150  landuse_frac_land(:,:) = 0.0_rp
151  landuse_frac_urban(:,:) = 0.0_rp
152  landuse_frac_lake(:,:) = 0.0_rp
153 
156  landuse_frac_pft(:,:,:) = 0.0_rp
157  landuse_frac_pft(:,:,1) = 1.0_rp ! tentative, mosaic is off
158  landuse_index_pft(:,:,:) = 1 ! default
159 
160  allocate( landuse_fact_ocean(ia,ja) )
161  allocate( landuse_fact_land(ia,ja) )
162  allocate( landuse_fact_urban(ia,ja) )
163  allocate( landuse_fact_lake(ia,ja) )
164  landuse_fact_ocean(:,:) = 0.0_rp
165  landuse_fact_land(:,:) = 0.0_rp
166  landuse_fact_urban(:,:) = 0.0_rp
167  landuse_fact_lake(:,:) = 0.0_rp
168 
169  allocate( landuse_exists_ocean(ia,ja) )
170  allocate( landuse_exists_land(ia,ja) )
171  allocate( landuse_exists_urban(ia,ja) )
172  allocate( landuse_exists_lake(ia,ja) )
173  landuse_exists_ocean(:,:) = .false.
174  landuse_exists_land(:,:) = .false.
175  landuse_exists_urban(:,:) = .false.
176  landuse_exists_lake(:,:) = .false.
177 
178 
179 
180  if ( landuse_allocean ) then
181 
182  log_info("LANDUSE_setup",*) 'Assume all grids are ocean'
183 
184  call landuse_calc_fact
185 
186  elseif( landuse_allland ) then
187 
188  log_info("LANDUSE_setup",*) 'Assume all grids are land'
189  log_info("LANDUSE_setup",*) 'Assume land PFT is 1 (bare ground)'
190  landuse_frac_land(:,:) = 1.0_rp
191 
192  call landuse_calc_fact
193 
194  elseif( landuse_allurban ) then
195 
196  log_info("LANDUSE_setup",*) 'Assume all grids are land'
197  log_info("LANDUSE_setup",*) 'Assume all lands are urban'
198  log_info("LANDUSE_setup",*) 'Assume land PFT is urban: ', landuse_index_urban
199  landuse_frac_land(:,:) = 1.0_rp
200  landuse_frac_urban(:,:) = 1.0_rp
202 
203  call landuse_calc_fact
204 
205  elseif( landuse_alllake ) then
206 
207  log_info("LANDUSE_setup",*) 'Assume all grids are land'
208  log_info("LANDUSE_setup",*) 'Assume all lands are lake'
209  log_info("LANDUSE_setup",*) 'Assume land PFT is lake: ', landuse_index_lake
210  landuse_frac_land(:,:) = 1.0_rp
211  landuse_frac_lake(:,:) = 1.0_rp
213 
214  call landuse_calc_fact
215 
216  elseif( landuse_mosaicworld ) then
217 
218  log_info("LANDUSE_setup",*) 'Assume all grids have ocean, land, and urban'
219 ! LOG_INFO("LANDUSE_setup",*) 'Assume all grids have ocean, land, urban, and lake'
220  log_info("LANDUSE_setup",*) 'Assume land PFT is 1 (bare ground)'
221  landuse_frac_land(:,:) = 0.5_rp
222  landuse_frac_urban(:,:) = 0.5_rp
223 ! LANDUSE_frac_lake (:,:) = 0.25_RP
224 
225  call landuse_calc_fact
226 
227  else ! default: read from file
228 
229  call landuse_read( ocean_do, urban_do, lake_do )
230  call landuse_calc_fact
231 
232  endif
233 
234  return
235  end subroutine landuse_setup
236 
237  !-----------------------------------------------------------------------------
238  subroutine landuse_calc_fact
239  implicit none
240 
241  real(RP) :: fact_soil
242  integer :: i, j
243  !---------------------------------------------------------------------------
244 
245  log_newline
246  log_info("LANDUSE_calc_fact",*) 'calculate landuse factor'
247 
248  ! make factors
249  !$omp parallel do private(fact_soil)
250  do j = 1, ja
251  do i = 1, ia
252  landuse_fact_ocean(i,j) = max( 1.0_rp - landuse_frac_land(i,j), 0.0_rp )
254  fact_soil = max( landuse_frac_land(i,j) - landuse_fact_lake(i,j), 0.0_rp )
255  landuse_fact_urban(i,j) = fact_soil * landuse_frac_urban(i,j)
256  landuse_fact_land(i,j) = max( fact_soil - landuse_fact_urban(i,j), 0.0_rp )
257 
258  if( landuse_fact_ocean(i,j) > 0.0_rp ) landuse_exists_ocean(i,j) = .true.
259  if( landuse_fact_land(i,j) > 0.0_rp ) landuse_exists_land(i,j) = .true.
260  if( landuse_fact_urban(i,j) > 0.0_rp ) landuse_exists_urban(i,j) = .true.
261  if( landuse_fact_lake(i,j) > 0.0_rp ) landuse_exists_lake(i,j) = .true.
262  enddo
263  enddo
264 
265  return
266  end subroutine landuse_calc_fact
267 
268  !-----------------------------------------------------------------------------
270  subroutine landuse_fillhalo( FILL_BND )
271  use scale_comm_cartesc, only: &
272  comm_vars8, &
273  comm_wait
274  implicit none
275 
276  logical, intent(in), optional :: FILL_BND
277 
278  real(RP) :: temp(ia,ja)
279 
280  logical :: FILL_BND_
281  integer :: p
282  !---------------------------------------------------------------------------
283 
284  fill_bnd_ = .true.
285  if ( present(fill_bnd) ) fill_bnd_ = fill_bnd
286 
287  call comm_vars8( landuse_frac_land(:,:), 1 )
288  call comm_vars8( landuse_frac_lake(:,:), 2 )
289  call comm_vars8( landuse_frac_urban(:,:), 3 )
290  call comm_vars8( landuse_fact_ocean(:,:), 4 )
291  call comm_vars8( landuse_fact_land(:,:), 5 )
292  call comm_vars8( landuse_fact_urban(:,:), 6 )
293  call comm_vars8( landuse_fact_lake(:,:), 7 )
294 
295  call comm_wait ( landuse_frac_land(:,:), 1, fill_bnd_ )
296  call comm_wait ( landuse_frac_lake(:,:), 2, fill_bnd_ )
297  call comm_wait ( landuse_frac_urban(:,:), 3, fill_bnd_ )
298  call comm_wait ( landuse_fact_ocean(:,:), 4, fill_bnd_ )
299  call comm_wait ( landuse_fact_land(:,:), 5, fill_bnd_ )
300  call comm_wait ( landuse_fact_urban(:,:), 6, fill_bnd_ )
301  call comm_wait ( landuse_fact_lake(:,:), 7, fill_bnd_ )
302 
303  do p = 1, landuse_pft_mosaic
304  temp(:,:) = real(LANDUSE_index_PFT(:,:,p),kind=rp)
305 
306  call comm_vars8( landuse_frac_pft(:,:,p), 8+2*(p-1) )
307  call comm_vars8( temp(:,:) , 9+2*(p-1) )
308 
309  call comm_wait ( landuse_frac_pft(:,:,p), 8+2*(p-1), fill_bnd_ )
310  call comm_wait ( temp(:,:) , 9+2*(p-1), fill_bnd_ )
311 
312  landuse_index_pft(:,:,p) = aint(temp(:,:),kind=4)
313  enddo
314 
315  return
316  end subroutine landuse_fillhalo
317 
318  !-----------------------------------------------------------------------------
320  subroutine landuse_read( &
321  OCEAN_do, &
322  URBAN_do, &
323  LAKE_do )
324  use scale_file_cartesc, only: &
326  file_cartesc_read, &
328  file_cartesc_check_coordinates, &
330  use scale_prc, only: &
331  prc_abort
332  implicit none
333 
334  logical, intent(in) :: OCEAN_do
335  logical, intent(in) :: URBAN_do
336  logical, intent(in) :: LAKE_do
337 
338  real(RP) :: temp(ia,ja)
339 
340  character(len=H_SHORT) :: varname
341 
342  integer :: fid
343  integer :: p, i, j
344  !---------------------------------------------------------------------------
345 
346  log_newline
347  log_info("LANDUSE_read",*) 'Input landuse file '
348 
349  if ( landuse_in_basename /= '' ) then
350 
351  call file_cartesc_open( landuse_in_basename, fid, aggregate=landuse_in_aggregate )
352 
353  call file_cartesc_read( fid, 'FRAC_LAND', 'XY', landuse_frac_land(:,:) )
354  call file_cartesc_read( fid, 'FRAC_LAKE', 'XY', landuse_frac_lake(:,:) )
355  call file_cartesc_read( fid, 'FRAC_URBAN', 'XY', landuse_frac_urban(:,:) )
356 
357  call file_cartesc_flush( fid )
358 
359  do p = 1, landuse_pft_mosaic
360  write(varname,'(A8,I1.1)') 'FRAC_PFT', p
361 
362  call file_cartesc_read( fid, varname, 'XY', landuse_frac_pft(:,:,p) )
363 
364  write(varname,'(A9,I1.1)') 'INDEX_PFT', p
365 
366  call file_cartesc_read( fid, varname, 'XY', temp(:,:) )
367  call file_cartesc_flush( fid ) ! for non-blocking I/O
368 
369  do j = js, je
370  do i = is, ie
371  landuse_index_pft(i,j,p) = int(temp(i,j)+1.e-3_rp,kind=4)
372  enddo
373  enddo
374  enddo
375 
376  if ( landuse_in_check_coordinates ) then
377  call file_cartesc_check_coordinates( fid )
378  end if
379 
380  call file_cartesc_close( fid )
381 
382  call landuse_fillhalo( fill_bnd=.false. )
383 
384  ! validity check
385  !$omp parallel do
386  do j = 1, ja
387  do i = 1, ia
388  if ( landuse_frac_land(i,j) < 0.0_rp .or. landuse_frac_land(i,j) > 1.0_rp ) then
389  log_error("LANDUSE_read",*) 'LANDUSE_frac_land is invalid: ', i,j, landuse_frac_land(i,j)
390  call prc_abort
391  end if
392  if ( landuse_frac_lake(i,j) < 0.0_rp .or. landuse_frac_lake(i,j) > 1.0_rp ) then
393  log_error("LANDUSE_read",*) 'LANDUSE_frac_lake is invalid: ', i,j, landuse_frac_lake(i,j)
394  call prc_abort
395  end if
396  if ( landuse_frac_urban(i,j) < 0.0_rp .or. landuse_frac_urban(i,j) > 1.0_rp ) then
397  log_error("LANDUSE_read",*) 'LANDUSE_frac_urban is invalid: ', i,j, landuse_frac_urban(i,j)
398  call prc_abort
399  end if
400  end do
401  end do
402 
403 !!$ if ( .not. OCEAN_do ) then
404 !!$ !$omp parallel do private(frac_ocean)
405 !!$ do j = 1, JA
406 !!$ do i = 1, IA
407 !!$ do p = LANDUSE_PFT_mosaic, 1, -1
408 !!$ frac_ocean = 1.0_RP - LANDUSE_frac_land(i,j)
409 !!$ if ( frac_ocean > LANDUSE_frac_PFT(i,j,p) ) then
410 !!$ if ( p < LANDUSE_PFT_mosaic ) then
411 !!$ LANDUSE_index_PFT(i,j,p+1) = LANDUSE_index_PFT(i,j,p)
412 !!$ LANDUSE_frac_PFT (i,j,p+1) = LANDUSE_frac_PFT (i,j,p)
413 !!$ end if
414 !!$ LANDUSE_index_PFT(i,j,p) = LANDUSE_index_OCEAN
415 !!$ LANDUSE_frac_PFT (i,j,p) = frac_ocean
416 !!$ else
417 !!$ exit
418 !!$ end if
419 !!$ end do
420 !!$ LANDUSE_frac_PFT(i,j,:) = LANDUSE_frac_PFT(i,j,:) / sum( LANDUSE_frac_PFT(i,j,:) )
421 !!$ end do
422 !!$ end do
423 !!$ LANDUSE_frac_land(:,:) = 1.0_RP
424 !!$ end if
425 
426  if ( .not. urban_do ) then
427  !$omp parallel do
428  do j = 1, ja
429  do i = 1, ia
430  do p = landuse_pft_mosaic, 1, -1
431  if ( landuse_frac_urban(i,j) > landuse_frac_pft(i,j,p) ) then
432  if ( p < landuse_pft_mosaic ) then
433  landuse_index_pft(i,j,p+1) = landuse_index_pft(i,j,p)
434  landuse_frac_pft(i,j,p+1) = landuse_frac_pft(i,j,p)
435  end if
438  end if
439  end do
440  landuse_frac_pft(i,j,:) = landuse_frac_pft(i,j,:) / sum( landuse_frac_pft(i,j,:) )
441  end do
442  end do
443  landuse_frac_urban(:,:) = 0.0_rp
444  end if
445 
446  if ( .not. lake_do ) then
447  if ( landuse_ignore_lake .or. (.not. ocean_do) ) then
448  !$omp parallel do
449  do j = 1, ja
450  do i = 1, ia
451  do p = landuse_pft_mosaic, 1, -1
452  if ( landuse_frac_lake(i,j) > landuse_frac_pft(i,j,p) ) then
453  if ( p < landuse_pft_mosaic ) then
454  landuse_index_pft(i,j,p+1) = landuse_index_pft(i,j,p)
455  landuse_frac_pft(i,j,p+1) = landuse_frac_pft(i,j,p)
456  end if
458  landuse_frac_pft(i,j,p) = landuse_frac_lake(i,j)
459  else
460  exit
461  end if
462  end do
463  landuse_frac_pft(i,j,:) = landuse_frac_pft(i,j,:) / sum( landuse_frac_pft(i,j,:) )
464  landuse_frac_urban(i,j) = max( landuse_frac_urban(i,j) * ( 1.0_rp - landuse_frac_lake(i,j) ), 0.0_rp )
465  end do
466  end do
467  else
468  ! lake is assumed to be ocean
469  !$omp parallel do
470  do j = 1, ja
471  do i = 1, ia
472  if( landuse_frac_land(i,j) == 0.0_rp .and. landuse_frac_urban(i,j) > 0.0_rp)then
473  log_error("LANDUSE_read",*) 'Not appropriate original landuse (w/ Lake). Bug!',i,j
474  call prc_abort
475  endif
476 
477  landuse_frac_land(i,j) = min( max( landuse_frac_land(i,j) * (1.0_rp-landuse_frac_lake(i,j)), 0.0_rp), 1.0_rp)
478 
479  if( landuse_frac_land(i,j) == 0.0_rp .and. landuse_frac_urban(i,j) > 0.0_rp)then
480  log_error("LANDUSE_read",*) 'Not appropriate replaced landuse (w/o Lake). Bug!',i,j
481  call prc_abort
482  endif
483 
484  end do
485  end do
486  end if
487  landuse_frac_lake(:,:) = 0.0_rp
488  end if
489 
490  else
491  log_info_cont(*) 'landuse file is not specified.'
492  log_info_cont(*) 'Assume all grids are ocean'
493  endif
494 
495  return
496  end subroutine landuse_read
497 
498  !-----------------------------------------------------------------------------
500  subroutine landuse_write
501  use scale_file_cartesc, only: &
505  file_cartesc_write_var, &
507  implicit none
508 
509  real(RP) :: temp(ia,ja)
510 
511  integer :: vid(7+landuse_pft_mosaic*2)
512  character(len=H_SHORT) :: varname
513 
514  integer :: fid
515  integer :: p
516  !---------------------------------------------------------------------------
517 
518  if ( landuse_out_basename /= '' .and. landuse_out_basename /= landuse_in_basename ) then
519 
520  log_newline
521  log_info("LANDUSE_write",*) 'Output landuse file '
522 
523  call landuse_fillhalo( fill_bnd=.false. )
524 
525  call file_cartesc_create( landuse_out_basename, landuse_out_title, landuse_out_dtype, & ! [IN]
526  fid, & ! [OUT]
527  haszcoord=.false., aggregate=landuse_out_aggregate ) ! [IN]
528 
529  call file_cartesc_def_var( fid, 'FRAC_LAND' , 'LAND fraction' , '1', 'XY', landuse_out_dtype, vid(1), standard_name="land_area_fraction" )
530  call file_cartesc_def_var( fid, 'FRAC_LAKE' , 'LAKE fraction' , '1', 'XY', landuse_out_dtype, vid(2) )
531  call file_cartesc_def_var( fid, 'FRAC_URBAN' , 'URBAN fraction' , '1', 'XY', landuse_out_dtype, vid(3) )
532  call file_cartesc_def_var( fid, 'FRAC_OCEAN_abs', 'absolute OCEAN fraction', '1', 'XY', landuse_out_dtype, vid(4) )
533  call file_cartesc_def_var( fid, 'FRAC_LAND_abs' , 'absolute LAND fraction' , '1', 'XY', landuse_out_dtype, vid(5) )
534  call file_cartesc_def_var( fid, 'FRAC_URBAN_abs', 'absolute URBAN fraction', '1', 'XY', landuse_out_dtype, vid(6) )
535  call file_cartesc_def_var( fid, 'FRAC_LAKE_abs' , 'absolute LAKE fraction' , '1', 'XY', landuse_out_dtype, vid(7) )
536 
537  do p = 1, landuse_pft_mosaic
538  write(varname,'(A8,I1.1)') 'FRAC_PFT', p
539  call file_cartesc_def_var( fid, varname, 'PFT fraction', '1', 'XY', landuse_out_dtype, vid(8+2*(p-1)) )
540  write(varname,'(A9,I1.1)') 'INDEX_PFT', p
541  call file_cartesc_def_var( fid, varname, 'PFT index', '1', 'XY', landuse_out_dtype, vid(9+2*(p-1)) )
542  end do
543 
544  call file_cartesc_enddef( fid )
545 
546  call file_cartesc_write_var( fid, vid(1), landuse_frac_land(:,:), 'FRAC_LAND' , 'XY' )
547  call file_cartesc_write_var( fid, vid(2), landuse_frac_lake(:,:), 'FRAC_LAKE' , 'XY' )
548  call file_cartesc_write_var( fid, vid(3), landuse_frac_urban(:,:), 'FRAC_URBAN' , 'XY' )
549  call file_cartesc_write_var( fid, vid(4), landuse_fact_ocean(:,:), 'FRAC_OCEAN_abs', 'XY' )
550  call file_cartesc_write_var( fid, vid(5), landuse_fact_land(:,:), 'FRAC_LAND_abs' , 'XY' )
551  call file_cartesc_write_var( fid, vid(6), landuse_fact_urban(:,:), 'FRAC_URBAN_abs', 'XY' )
552  call file_cartesc_write_var( fid, vid(7), landuse_fact_lake(:,:), 'FRAC_LAKE_abs' , 'XY' )
553 
554  do p = 1, landuse_pft_mosaic
555  write(varname,'(A8,I1.1)') 'FRAC_PFT', p
556  call file_cartesc_write_var( fid, vid(8+2*(p-1)), landuse_frac_pft(:,:,p), varname, 'XY' )
557  write(varname,'(A9,I1.1)') 'INDEX_PFT', p
558  temp(:,:) = real(LANDUSE_index_PFT(:,:,p),kind=rp)
559  call file_cartesc_write_var( fid, vid(9+2*(p-1)), temp(:,:), varname, 'XY' )
560  end do
561 
562  call file_cartesc_close( fid )
563 
564  end if
565 
566  return
567  end subroutine landuse_write
568 
569 end module scale_landuse
real(rp), dimension(:,:,:), allocatable, public landuse_frac_pft
fraction of PFT for each mosaic
real(rp), dimension(:,:), allocatable, public landuse_fact_urban
urban factor
subroutine, public landuse_setup(OCEAN_do, URBAN_do, LAKE_do)
Setup.
integer, parameter, public landuse_index_ocean
ocean index
integer, public ia
of whole cells: x, local, with HALO
subroutine, public landuse_fillhalo(FILL_BND)
HALO Communication.
integer, parameter, public landuse_index_urban
urban index
logical, public file_aggregate
Definition: scale_file.F90:171
subroutine, public landuse_calc_fact
integer, public ja
of whole cells: y, local, with HALO
integer, public io_fid_conf
Config file ID.
Definition: scale_io.F90:55
real(rp), dimension(:,:), allocatable, public landuse_frac_urban
urban fraction
logical, dimension(:,:), allocatable, public landuse_exists_lake
lake calculation flag
logical, dimension(:,:), allocatable, public landuse_exists_land
land calculation flag
integer, parameter, public landuse_pft_nmin
minimum number of PFT type
module COMMUNICATION
integer, public is
start point of inner domain: x, local
module file
Definition: scale_file.F90:15
integer, public ie
end point of inner domain: x, local
subroutine, public file_cartesc_create(basename, title, datatype, fid, date, subsec, haszcoord, append, aggregate, single)
Create/open a netCDF file.
module LANDUSE
module atmosphere / grid / cartesC index
module PROCESS
Definition: scale_prc.F90:11
integer, public je
end point of inner domain: y, local
subroutine, public landuse_write
Write landuse data.
real(rp), dimension(:,:), allocatable, public landuse_fact_ocean
ocean factor
subroutine, public file_cartesc_enddef(fid)
Exit netCDF file define mode.
integer, public landuse_pft_mosaic
number of PFT mosaic
real(rp), dimension(:,:), allocatable, public landuse_fact_lake
lake factor
integer, dimension(:,:,:), allocatable, public landuse_index_pft
index of PFT for each mosaic
subroutine, public prc_abort
Abort Process.
Definition: scale_prc.F90:338
integer, public js
start point of inner domain: y, local
subroutine, public file_cartesc_def_var(fid, varname, desc, unit, dim_type, datatype, vid, standard_name, timeintv, nsteps, cell_measures)
Define a variable to file.
module profiler
Definition: scale_prof.F90:11
logical, dimension(:,:), allocatable, public landuse_exists_ocean
ocean calculation flag
real(rp), dimension(:,:), allocatable, public landuse_frac_lake
lake fraction
module PRECISION
module file / cartesianC
integer, public landuse_pft_nmax
number of plant functional type(PFT)
module STDIO
Definition: scale_io.F90:10
real(rp), dimension(:,:), allocatable, public landuse_fact_land
land factor
subroutine, public file_cartesc_flush(fid)
Flush all pending requests to a netCDF file (PnetCDF only)
logical, dimension(:,:), allocatable, public landuse_exists_urban
urban calculation flag
integer, parameter, public rp
subroutine, public file_cartesc_open(basename, fid, aggregate)
open a netCDF file for read
integer, parameter, public landuse_index_lake
lake index
real(rp), dimension(:,:), allocatable, public landuse_frac_land
land fraction
subroutine, public file_cartesc_close(fid)
Close a netCDF file.