How to define the input forcing files when having many?

General scientific issues regarding ROMS

Moderators: arango, robertson

Post Reply
Message
Author
User avatar
LiangPeng
Posts: 11
Joined: Wed Aug 21, 2013 2:38 pm
Location: Guangdong Ocean University

How to define the input forcing files when having many?

#1 Unread post by LiangPeng »

Hi everyone!
Now I'm using ROMS to simulate the ocean circulation on a very high resolution. Because of the limited size of the netcdf file that can be created by Matlab I have to split the forcing and climatory file into many smaller files. The way I'm using is to create one file for each variable (u_stress,v_stress,dqdsst etc.)and each file has its own time for its variable,then I define the forcing files as below:

NFFILES == 9 ! number of forcing files
FRCNAME == ./input/surface_1949_1959_srf.nc /
./input/-5_30_pac_tide.nc /
./input/surface_1949_1959_dqdsst.nc /
./input/surface_1949_1959_shf.nc /
./input/surface_1949_1959_sss.nc /
./input/surface_1949_1959_sst.nc /
./input/surface_1949_1959_swf.nc /
./input/surface_1949_1959_ustress.nc /
./input/surface_1949_1959_vstress.nc
And the error is bellow:
Input Forcing File 01: ./input/-5_30_pac_tide.nc
Input Forcing File 02: ./input/surface_1949_1959_srf.nc
Input Forcing File 03: ./input/surface_1949_1959_dqdsst.nc
Input Forcing File 04: ./input/surface_1949_1959_shf.nc

READ_PHYPAR - could not find input file: ./input/surface_1949_1959_sss.nc
but in fact that file is under the ./input directory.
So I want to know whether the forcing files can be created in this way (one file for each variable) and how to define them in the ocean.in. If the forcing files can't be created in this way then how to create the small file ?

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: How to define the input forcing files when having many?

#2 Unread post by kate »

This should work with the many small files, but you need a backslash (\) at the ends of the lines instead of the forward slash (/).

User avatar
arango
Site Admin
Posts: 1367
Joined: Wed Feb 26, 2003 4:41 pm
Location: DMCS, Rutgers University
Contact:

Re: How to define the input forcing files when having many?

#3 Unread post by arango »

:idea: The instructions are very clear in all input scripts. You just have to read :!:

Code: Select all

! Input parameters can be entered in ANY order, provided that the parameter   !
! KEYWORD (usually, upper case) is typed correctly followed by "="  or "=="   !
! symbols. Any comment lines are allowed and must begin with an exclamation   !
! mark (!) in column one.  Comments may  appear to the right of a parameter   !
! specification to improve documentation.  Comments will be ignored  during   !
! reading.  Blank lines are also allowed and ignored. Continuation lines in   !
! a parameter specification are allowed and must be preceded by a backslash   !
! (\).  In some instances, more than one value is required for a parameter.   !
! If fewer values are provided, the  last value  is assigned for the entire   !
! parameter array.  The multiplication symbol (*),  without blank spaces in   !
! between, is allowed for a parameter specification.
...
! Multiple NetCDF files are allowed for input field(s).  This is useful when  !
! splitting input data (climatology,  boundary,  forcing)  time records into  !
! several files (say monthly, annual, etc). In this case, each multiple file  !
! entry line needs to be ended by the vertical bar (|) symbol. For example:   !
!                                                                             !
!    NFFILES == 7                          ! number of forcing files          !
!                                                                             !
!    FRCNAME == my_tides.nc       \                                           !
!               my_lwrad_year1.nc |                                           !
!               my_lwrad_year2.nc \                                           !
!               my_swrad_year1.nc |                                           !
!               my_swrad_year2.nc \                                           !
!               my_winds_year1.nc |                                           !
!               my_winds_year2.nc \                                           !
!               my_Pair_year1.nc  |                                           !
!               my_Pair_year2.nc  \                                           !
!               my_Qair_year1.nc  |                                           !
!               my_Qair_year2.nc  \                                           !
!               my_Tair_year1.nc  |                                           !
!               my_Tair_year2.nc                                              !
!                                                                             !
! Notice that NFFILES is 7 and not 13. There are 7 uniquely different fields  !
! in the file list,  we  DO NOT  count file entries followed by the vertical  !
! bar symbol.  This is because  multiple file  entries are processed in ROMS  !
! with derived type structures.                                               !
 

Post Reply