Changeset 1320 for trunk/DOC/TexFiles/Chapters/Chap_SBC.tex
- Timestamp:
- 2009-02-19T14:26:35+01:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DOC/TexFiles/Chapters/Chap_SBC.tex
r1224 r1320 27 27 (\np{ln\_cpl}=true). The frequency at which the six fields have to be updated is 28 28 the \np{nf\_sbc} namelist parameter. 29 When the fields are supplied from data files (flux and bulk formulations), the input fields 30 need not be supplied on the model grid. Instead a file of coordinates and weights can be supplied which 31 maps the data from the supplied grid to the model points (so called "Interpolation on the Fly"). 29 32 In addition, the resulting fields can be further modified using 30 several namelist options. These options control the addition of a surface restoring 31 term to observed SST and/or SSS (\np{ln\_ssr}=true), the modification of fluxes 33 several namelist options. These options control the rotation of vector components 34 supplied relative to an east-north coordinate system onto the local grid directions in the model; 35 the addition of a surface restoring 36 term to observed SST and/or SSS (\np{ln\_ssr}=true); the modification of fluxes 32 37 below ice-covered areas (using observed ice-cover or a sea-ice model) 33 (\np{nn\_ice}=0,1, 2 or 3) ,the addition of river runoffs as surface freshwater34 fluxes (\np{ln\_rnf}=true) ,the addition of a freshwater flux adjustment in35 order to avoid a mean sea-level drift (\np{nn\_fwb}= 0, 1 or 2) ,and the38 (\np{nn\_ice}=0,1, 2 or 3); the addition of river runoffs as surface freshwater 39 fluxes (\np{ln\_rnf}=true); the addition of a freshwater flux adjustment in 40 order to avoid a mean sea-level drift (\np{nn\_fwb}= 0, 1 or 2); and the 36 41 transformation of the solar radiation (if provided as daily mean) into a diurnal 37 42 cycle (\np{ln\_dm2dc}=true). … … 39 44 In this chapter, we first discuss where the surface boundary condition 40 45 appears in the model equations. Then we present the four ways of providing 41 the surface boundary condition. Finally, the different options that further modify 46 the surface boundary condition. Next the scheme for interpolation on the fly is described. 47 Finally, the different options that further modify 42 48 the fluxes applied to the ocean are discussed. 43 49 … … 101 107 For example: 102 108 103 When rigid-lid assumption is made, the ocean volume becomes constant and109 When the rigid-lid assumption is made, the ocean volume becomes constant and 104 110 thus, EMP$=$0, not EMP$_{S }$. 105 111 … … 110 116 only the volume flux. In addition, in the current version of \NEMO, the 111 117 sea-ice is assumed to be above the ocean. Freezing/melting does not change 112 the ocean volume (no timpact on EMP) but it modifies the SSS.118 the ocean volume (no impact on EMP) but it modifies the SSS. 113 119 %gm \colorbox{yellow}{(see {\S} on LIM sea-ice model)}. 114 120 … … 354 360 atmospheric GCM (ARPEGE, ECHAM, ECMWF, HadAM, LMDz). 355 361 362 % ================================================================ 363 % Interpolation on the Fly 364 % ================================================================ 365 366 \section [Interpolation on the Fly] {Interpolation on the Fly} 367 \label{SBC_iof} 368 369 Interpolation on the Fly allows the user to supply input files required 370 for the surface forcing on grids other than the model grid. 371 To do this he or she must supply, in addition to the source data file, 372 a file of weights to be used to interpolate from the data grid to the model 373 grid. 374 The original development of this code used the SCRIP package (freely available 375 under a copyright agreement from http://climate.lanl.gov/Software/SCRIP). 376 In principle, any package can be used to generate the weights, but the 377 variables in the input weights file must have the same names and meanings as 378 assumed by the model. 379 Two methods are currently available: bilinear and bicubic interpolation. 380 381 \subsection{Bilinear Interpolation} 382 \label{SBC_iof_bilinear} 383 384 The input weights file in this case has two sets of variables: src01, src02, 385 src03, src04 and wgt01, wgt02, wgt03, wgt04. 386 The "src" variables correspond to the point in the input grid to which the weight 387 "wgt" is to be applied. Each src value is an integer corresponding to the index of a 388 point in the input grid when written as a one dimensional array. For example, for an input grid 389 of size 5x10, point (3,2) is referenced as point 8, since (2-1)*5+3=8. 390 There are four of each variable because bilinear interpolation uses the four points defining 391 the grid box containing the point to be interpolated. 392 All of these arrays are on the model grid, so that values src01(i,j) and 393 wgt01(i,j) are used to generate a value for point (i,j) in the model. 394 395 Symbolically, the algorithm used is: 396 397 \begin{equation} 398 f_{m}(i,j) = f_{m}(i,j) + \sum_{k=1}^{4} {wgt(k)f(idx(src(k)))} 399 \end{equation} 400 where function idx() transforms a one dimensional index src(k) into a two dimensional index, 401 and wgt(1) corresponds to variable "wgt01" for example. 402 403 \subsection{Bicubic Interpolation} 404 \label{SBC_iof_bicubic} 405 406 Again there are two sets of variables: "src" and "wgt". 407 But in this case there are 16 of each. 408 The symbolic algorithm used to calculate values on the model grid is now: 409 410 \begin{multline*} 411 f_{m}(i,j) = f_{m}(i,j) + \sum_{k=1}^{4} {wgt(k)f(idx(src(k)))} 412 \\ 413 + \sum_{k=5}^{8} {wgt(k)\left.\frac{\partial f}{\partial i}\right| _{idx(src(k))} } 414 \\ 415 + \sum_{k=9}^{12} {wgt(k)\left.\frac{\partial f}{\partial j}\right| _{idx(src(k))} } 416 \\ 417 + \sum_{k=13}^{16} {wgt(k)\left.\frac{\partial ^2 f}{\partial i \partial j}\right| _{idx(src(k))} } 418 \end{multline*} 419 The gradients here are taken with respect to the horizontal indices and not distances since the spatial dependency has been absorbed into the weights. 420 421 \subsection{Implementation} 422 \label{SBC_iof_imp} 423 424 To activate this option, a non-empty string should be supplied in the weights filename column of the relevant namelist; 425 if this is left as an empty string no action is taken. 426 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. 427 This initialisation procedure tries to determine whether the input data grid should be treated as cyclical or not. 428 (In fact this only matters when bicubic interpolation is required.) 429 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". 430 If found, it checks the difference between the first and last values of longitude along a single row. 431 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. 432 If neither "nav\_lon" or "lon" can be found, the model resorts to looking at the first and last columns of data. 433 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. 434 If both of these tests fail, the grid is assumed not to be cyclical. 435 436 Next the routine reads in the weights. 437 Bicubic interpolation is assumed if it finds a variable with name "src05", otherwise bilinear interpolation is used. 438 The WGT structure includes dynamic arrays both for the storage of the weights (on the model grid), and when required, for reading in the variable to be interpolated (on the input data grid). 439 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. 440 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. 441 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). 442 443 \subsection{Limitations} 444 \label{SBC_iof_lim} 445 446 \begin{description} 447 \item 448 Input data grids must be logically rectangular. 449 \item 450 This code is not guaranteed to produce positive definite answers from positive definite inputs. 451 \item 452 The cyclic condition is only applied on left and right columns, and not to top and bottom rows. 453 \item 454 The gradients across the ends of a cyclical grid assume that the grid spacing between the two columns involved are consistent with the weights used. 455 \item 456 Neither interpolation scheme is conservative. 457 (There is a conservative scheme available in SCRIP, but this has not been implemented.) 458 \end{description} 459 460 \subsection{Utilities} 461 \label{SBC_iof_util} 462 463 % to be completed 464 A set of utilities to create a weights file for a rectilinear input grid is available. 356 465 357 466 % ================================================================ … … 360 469 \section{Miscellaneous options} 361 470 \label{SBC_misc} 471 472 % ------------------------------------------------------------------------------------------------------------- 473 % Rotation of vector pairs onto the model grid directions 474 % ------------------------------------------------------------------------------------------------------------- 475 \subsection{Rotation of vector pairs onto the model grid directions} 476 \label{SBC_rotation} 477 478 When using a flux (\np{ln\_flx}=true) or bulk (\np{ln\_clio}=true or \np{ln\_core}=true) formulation, 479 pairs of vector components can be rotated from east-north directions onto the local grid directions. 480 This is particularly useful when interpolation on the fly is used since here any vectors are likely to be defined 481 relative to a rectilinear grid. 482 To activate this option a non-empty string is supplied in the rotation pair column of the relevant namelist. 483 The eastward component must start with "U" and the northward component with "V". 484 The remaining characters in the strings are used to identify which pair of components go together. 485 So for example, strings "U1" and "V1" next to "utau" and "vtau" would pair the wind stress components together 486 and rotate them on to the model grid directions; "U2" and "V2" could be used against a second pair of components, 487 and so on. 488 The extra characters used in the strings are arbitrary. 489 The rot\_rep routine from the \mdl{geo2ocean} module is used to perform the rotation. 362 490 363 491 % -------------------------------------------------------------------------------------------------------------
Note: See TracChangeset
for help on using the changeset viewer.