rompy.swan.components.boundary.BOUNDNEST1#

pydantic model rompy.swan.components.boundary.BOUNDNEST1[source]#

Boundary spectra from a coarser SWAN nest.

BOUNDNEST1 NEST 'fname' ->CLOSED|OPEN

With this optional command a nested SWAN run can be carried out with the boundary conditions obtained from a coarse grid SWAN run (generated in that previous SWAN run with command NESTOUT). The spectral frequencies and directions of the coarse grid run do not have to coincide with the frequencies and directions used in the nested SWAN run; SWAN will interpolate to these frequencies and directions in the nested run (see Section 2.6.3). To generate the nest boundary in the coarse grid run, use command NGRID. For the nested run, use the command CGRID with identical geographical information except the number of meshes (which will be much higher for the nested run). This BOUNDNEST1 command is not available for 1D computations; in such cases the commands SPECOUT and BOUNDSPEC can be used for the same purpose. A nested SWAN run must use the same coordinate system as the coarse grid SWAN run. For a curvilinear grid, it is advised to use the commands POINTS or CURVE and SPECOUT instead of NGRID and NESTOUT.

Examples

In [2]: from rompy.swan.components.boundary import BOUNDNEST1

In [3]: boundary = BOUNDNEST1(fname="boundary.swn", rectangle="closed")

In [4]: print(boundary.render())
BOUNDNEST1 NEST fname='boundary.swn' CLOSED
Fields:
field fname: str [Required]#

Name of the file containing the boundary conditions for the present run, created by the previous SWAN coarse grid run. This file is structured according to the rules given in Appendix D for 2D spectra

Constraints:
  • min_length = 1

  • max_length = 36

field model_type: Literal['boundnest1', 'BOUNDNEST1'] = 'boundnest1'#

Model type discriminator

field rectangle: Literal['closed', 'open'] = 'closed'#

Boundary is defined over a closed (default) or an open rectangle. Boundary generated from the NESTOUT command is aways closed

cmd() str[source]#

Return the string or list of strings to render the component to the CMD.