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
Show JSON schema
{ "title": "BOUNDNEST1", "description": "Boundary spectra from a coarser SWAN nest.\n\n.. code-block:: text\n\n BOUNDNEST1 NEST 'fname' ->CLOSED|OPEN\n\nWith this optional command a nested SWAN run can be carried out with the boundary\nconditions obtained from a coarse grid SWAN run (generated in that previous SWAN\nrun with command NESTOUT). The spectral frequencies and directions of the coarse\ngrid run do not have to coincide with the frequencies and directions used in the\nnested SWAN run; SWAN will interpolate to these frequencies and directions in the\nnested run (see Section 2.6.3). To generate the nest boundary in the coarse grid\nrun, use command NGRID. For the nested run, use the command CGRID with identical\ngeographical information except the number of meshes (which will be much higher for\nthe nested run). This BOUNDNEST1 command is not available for 1D computations; in\nsuch cases the commands SPECOUT and BOUNDSPEC can be used for the same purpose. A\nnested SWAN run must use the same coordinate system as the coarse grid SWAN run.\nFor a curvilinear grid, it is advised to use the commands POINTS or CURVE and\nSPECOUT instead of NGRID and NESTOUT.\n\nExamples\n--------\n\n.. ipython:: python\n :okwarning:\n\n from rompy.swan.components.boundary import BOUNDNEST1\n boundary = BOUNDNEST1(fname=\"boundary.swn\", rectangle=\"closed\")\n print(boundary.render())", "type": "object", "properties": { "model_type": { "default": "boundnest1", "description": "Model type discriminator", "enum": [ "boundnest1", "BOUNDNEST1" ], "title": "Model Type", "type": "string" }, "fname": { "description": "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", "maxLength": 36, "minLength": 1, "title": "Fname", "type": "string" }, "rectangle": { "default": "closed", "description": "Boundary is defined over a closed (default) or an open rectangle. Boundary generated from the NESTOUT command is aways closed", "enum": [ "closed", "open" ], "title": "Rectangle", "type": "string" } }, "additionalProperties": false, "required": [ "fname" ] }
- 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