Changeset 5951 for branches/2014/dev_r4650_UKMO14.4_OBS_GENERAL_VINTERP/NEMOGCM/TOOLS/SIREN/src/create_coord.f90
- Timestamp:
- 2015-11-30T12:48:01+01:00 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2014/dev_r4650_UKMO14.4_OBS_GENERAL_VINTERP/NEMOGCM/TOOLS/SIREN/src/create_coord.f90
r5950 r5951 24 24 !> @endcode 25 25 !> 26 !> @note 27 !> you could find a template of the namelist in templates directory. 28 !> 26 29 !> create_coord.nam comprise 6 namelists:<br/> 27 30 !> - logger namelist (namlog) … … 39 42 !> - cn_logfile : log filename 40 43 !> - cn_verbosity : verbosity ('trace','debug','info', 41 !> 'warning','error','fatal' )44 !> 'warning','error','fatal','none') 42 45 !> - in_maxerror : maximum number of error allowed 43 46 !> … … 54 57 !> - cn_varinfo : list of variable and extra information about request(s) 55 58 !> to be used.<br/> 56 !> each elements of *cn_varinfo* is a string character.<br/> 59 !> each elements of *cn_varinfo* is a string character 60 !> (separated by ',').<br/> 57 61 !> it is composed of the variable name follow by ':', 58 62 !> then request(s) to be used on this variable.<br/> 59 63 !> request could be: 60 !> - int erpolation method61 !> - ext rapolation method62 !> - f ilter method64 !> - int = interpolation method 65 !> - ext = extrapolation method 66 !> - flt = filter method 63 67 !> 64 68 !> requests must be separated by ';' .<br/> … … 68 72 !> @ref extrap and @ref filter modules.<br/> 69 73 !> 70 !> Example: 'votemper: linear; hann(2,3);dist_weight',71 !> 'vosaline: cubic'<br/>74 !> Example: 'votemper: int=linear; flt=hann(2,3); ext=dist_weight', 75 !> 'vosaline: int=cubic'<br/> 72 76 !> @note 73 77 !> If you do not specify a method which is required, … … 90 94 !> 91 95 !> * _output namelist (namout)_: 92 !> - cn_fileout : output coordinate file 96 !> - cn_fileout : output coordinate file name 93 97 !> 94 98 !> @author J.Paul … … 152 156 TYPE(TFILE) :: tl_fileout 153 157 154 ! check155 ! INTEGER(i4) :: il_imin0156 ! INTEGER(i4) :: il_imax0157 ! INTEGER(i4) :: il_jmin0158 ! INTEGER(i4) :: il_jmax0159 ! INTEGER(i4) , DIMENSION(2,2) :: il_ind2160 ! TYPE(TMPP) :: tl_mppout161 162 158 ! loop indices 163 159 INTEGER(i4) :: ji … … 165 161 166 162 ! namelist variable 163 ! namlog 167 164 CHARACTER(LEN=lc) :: cn_logfile = 'create_coord.log' 168 165 CHARACTER(LEN=lc) :: cn_verbosity = 'warning' 169 166 INTEGER(i4) :: in_maxerror = 5 170 167 168 ! namcfg 169 CHARACTER(LEN=lc) :: cn_varcfg = '../cfg/variable.cfg' 170 171 ! namcrs 171 172 CHARACTER(LEN=lc) :: cn_coord0 = '' 172 173 INTEGER(i4) :: in_perio0 = -1 173 174 174 CHARACTER(LEN=lc) :: cn_varcfg = '../cfg/variable.cfg' 175 175 ! namvar 176 176 CHARACTER(LEN=lc), DIMENSION(ip_maxvar) :: cn_varinfo = '' 177 177 178 !namnst 178 179 INTEGER(i4) :: in_imin0 = 0 179 180 INTEGER(i4) :: in_imax0 = 0 … … 183 184 INTEGER(i4) :: in_rhoj = 1 184 185 186 !namout 185 187 CHARACTER(LEN=lc) :: cn_fileout= 'coord_fine.nc' 186 188 !------------------------------------------------------------------- … … 305 307 306 308 il_offset(:,:,:)=create_coord_get_offset(il_rho(:)) 307 308 309 ENDIF 309 310 … … 348 349 CALL dom_del_extra( tl_var(ji), tl_dom, il_rho(:), .true. ) 349 350 350 ! do not add ghost cell.351 ! ghost cell already replace by value for coordinates352 ! CALL grid_add_ghost(tl_var(ji),tl_dom%i_ghost(:,:))353 354 351 ! filter 355 352 CALL filter_fill_value(tl_var(ji)) … … 375 372 376 373 ! add variables 377 DO ji= 1,il_nvar374 DO ji=il_nvar,1,-1 378 375 CALL file_add_var(tl_fileout, tl_var(ji)) 376 CALL var_clean(tl_var(ji)) 379 377 ENDDO 380 381 ! recompute some attribute382 378 383 379 ! add some attribute … … 440 436 441 437 CALL file_clean(tl_fileout) 442 443 ! ! check domain444 ! tl_coord0=mpp_init( file_init(TRIM(cn_coord0)), id_perio=in_perio0)445 ! tl_mppout=mpp_init( file_init(TRIM(cn_fileout)) )446 ! CALL grid_get_info(tl_coord0)447 ! CALL iom_mpp_open(tl_mppout)448 !449 ! il_ind2(:,:)=grid_get_coarse_index( tl_coord0, tl_mppout, &450 ! & id_rho=il_rho(:) )451 !452 ! il_imin0=il_ind2(1,1) ; il_imax0=il_ind2(1,2)453 ! il_jmin0=il_ind2(2,1) ; il_jmax0=il_ind2(2,2)454 !455 ! IF( il_imin0 /= in_imin0 .OR. &456 ! & il_imax0 /= in_imax0 .OR. &457 ! & il_jmin0 /= in_jmin0 .OR. &458 ! & il_jmax0 /= in_jmax0 )THEN459 ! CALL logger_debug("CREATE COORD: output indices ("//&460 ! & TRIM(fct_str(il_imin0))//","//&461 ! & TRIM(fct_str(il_imax0))//") ("//&462 ! & TRIM(fct_str(il_jmin0))//","//&463 ! & TRIM(fct_str(il_jmax0))//")" )464 ! CALL logger_debug("CREATE COORD: input indices ("//&465 ! & TRIM(fct_str(in_imin0))//","//&466 ! & TRIM(fct_str(in_imax0))//") ("//&467 ! & TRIM(fct_str(in_jmin0))//","//&468 ! & TRIM(fct_str(in_jmax0))//")" )469 ! CALL logger_fatal("CREATE COORD: output domain not confrom "//&470 ! & "with input indices")471 ! ENDIF472 !473 ! CALL iom_mpp_close(tl_coord0)474 ! CALL iom_mpp_close(tl_mppout)475 438 476 439 ! close log file … … 539 502 !> @param[in] id_iext number of points to be extrapolated in i-direction 540 503 !> @param[in] id_jext number of points to be extrapolated in j-direction 504 !> 505 !> @todo check if mask is really needed 541 506 !------------------------------------------------------------------- 542 507 SUBROUTINE create_coord_interp( td_var, & … … 626 591 627 592 ! extrapolate variable 628 CALL extrap_fill_value( td_var , id_iext=il_iext, id_jext=il_jext)593 CALL extrap_fill_value( td_var ) 629 594 630 595 ! interpolate variable
Note: See TracChangeset
for help on using the changeset viewer.