- Timestamp:
- 2010-11-02T08:09:00+01:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/nemo_v3_3_beta/DOC/TexFiles/Chapters/Chap_SBC.tex
r2349 r2351 641 641 if this is left as an empty string no action is taken. 642 642 In the model, weights files are read in and stored in a structured type (WGT) in the fldread module, as and when they are first required. 643 This initialisation procedure tries to determine whether the input data grid should be treated as cyclical or not. 643 This initialisation procedure determines whether the input data grid should be treated as cyclical or not by inspecting a global attribute stored in the weights input file. 644 This attribute must be called "ew_wrap" and be of integer type. 645 If it is negative, the input non-model grid is assumed not to be cyclic. 646 If zero or greater, then the value represents the number of columns that overlap. 647 E.g. if the input grid has columns at longitudes 0, 1, 2, .... , 359, then ew_wrap should be set to 0; 648 if longitudes are 0.5, 2.5, .... , 358.5, 360.5, 362.5, ew_wrap should be 2. 649 If the model does not find attribute ew_wrap, then a value of -999 is assumed. 650 In this case the fld_read routine defaults ew_wrap to value 0 and therefore the grid is assumed to be cyclic 651 with no overlapping columns. 644 652 (In fact this only matters when bicubic interpolation is required.) 645 To do this the model looks in the input data file (i.e. the data to which the weights are to be applied) for a variable with name "nav\_lon" or "lon". 646 If found, it checks the difference between the first and last values of longitude along a single row. 647 If the absolute value of this difference is close to 360 degrees or less than twice the maximum spacing from 360 degrees, the grid is assumed to be cyclical, and the difference determines whether the first column is a repeat of the last one or not. 648 If neither "nav\_lon" or "lon" can be found, the model resorts to looking at the first and last columns of data. 649 If the sum of the absolute values of the differences between the columns is very small, then the grid is assumed to be cyclical with coincident first and last columns. 650 If both of these tests fail, the grid is assumed not to be cyclical. 653 Note that no testing is done to check the validity in the model, since there is no way of knowing the name used for the longitude variable, 654 so it is up to the user to make sure his or her data is correctly represented. 651 655 652 656 Next the routine reads in the weights. … … 655 659 The size of the input data array is determined by examining the values in the "src" arrays to find the minimum and maximum i and j values required. 656 660 Since bicubic interpolation requires the calculation of gradients at each point on the grid, the corresponding arrays are dimensioned with a halo of width one grid point all the way around. 657 When the array of points from the data file is adjacent to an edge of the data grid, the halo is either a copy of the row/column next to it (non-cyclical case), or is a copy of one from the first two rows/columns on the opposite side of the grid (cyclical case with coincident end rows/columns, or cyclical case with non-coincident end rows/columns).661 When the array of points from the data file is adjacent to an edge of the data grid, the halo is either a copy of the row/column next to it (non-cyclical case), or is a copy of one from the first few columns on the opposite side of the grid (cyclical case). 658 662 659 663 \subsection{Limitations} … … 662 666 \begin{description} 663 667 \item 664 Input data grids must be logically rectangular.668 The case where input data grids are not logically rectangular has not been tested. 665 669 \item 666 670 This code is not guaranteed to produce positive definite answers from positive definite inputs.
Note: See TracChangeset
for help on using the changeset viewer.