rompy.swan.components.output.NGRID#

pydantic model rompy.swan.components.output.NGRID[source]#

Output locations for a nested grid.

NGRID 'sname' [xpn] [ypn] [alpn] [xlenn] [ylenn] [mxn] [myn]

If the user wishes to carry out nested SWAN runs, a separate coarse-grid SWAN run is required. With this optional command NGRID, the user defines in the present coarse-grid run, a set of output locations along the boundary of the subsequent nested computational grid. The set of output locations thus defined is of the type NGRID.

Note

Command NESTOUT is required after this command NGRID to generate some data for the (subsequent) nested run.

Note

Cannot be used in 1D-mode.

Examples

In [1]: from rompy.swan.components.output import NGRID

In [2]: loc = NGRID(
   ...:     sname="outnest",
   ...:     grid=dict(xp=173, yp=-40, xlen=2, ylen=2, mx=19, my=19),
   ...: )
   ...: 

In [3]: print(loc.render())
NGRID sname='outnest' xpn=173.0 ypn=-40.0 alpn=0.0 xlenn=2.0 ylenn=2.0 mxn=19 myn=19
Fields:
Validators:
field grid: GRIDREGULAR [Required]#

NGRID grid definition

Validated by:
field model_type: Literal['ngrid', 'NGRID'] = 'ngrid'#

Model type discriminator

cmd() str[source]#

Command file string for this component.

validator grid_suffix  »  grid[source]#