rompy.swan.subcomponents.startup.SPHERICAL#
- pydantic model rompy.swan.subcomponents.startup.SPHERICAL[source]#
Spherical coordinates.
SPHERICAL [->CCM|QC]
Notes
projection options:
CCM: central conformal Mercator. The horizontal and vertical scales are uniform in terms of cm/degree over the area shown. In the centre of the scale is identical to that of the conventional Mercator projection (but only at that centre). The area in the projection centre is therefore exactly conformal.
QC: the projection method is quasi-cartesian, i.e. the horizontal and vertical scales are equal to one another in terms of cm/degree.
All coordinates of locations and geographical grid sizes are given in degrees;`x` is longitude with x = 0 being the Greenwich meridian and x > 0 is East of this meridian; y is latitude with y > 0 being the Northern hemisphere. Input and output grids have to be oriented with their x-axis to the East; mesh sizes are in degrees. All other distances are in meters.
Note that spherical coordinates can also be used for relatively small areas, say 10 or 20 km horizontal dimension. This may be useful if one obtains the boundary conditions by nesting in an oceanic model which is naturally formulated in spherical coordinates. Note that in case of spherical coordinates regular grids must always be oriented E-W, N-S, i.e. alpc=0, alpinp=0, alpfr=0 (see commands CGRID, INPUT GRID and FRAME, respectively).
Examples
In [131]: from rompy.swan.components.startup import SPHERICAL In [132]: coords = SPHERICAL() In [133]: print(coords.render()) SPHERICAL CCM In [134]: coords = SPHERICAL(projection="qc") In [135]: print(coords.render()) SPHERICAL QC
Show JSON schema
{ "title": "SPHERICAL", "description": "Spherical coordinates.\n\n.. code-block:: text\n\n SPHERICAL [->CCM|QC]\n\nNotes\n-----\n\nprojection options:\n\n* CCM: central conformal Mercator. The horizontal and vertical scales are\n uniform in terms of cm/degree over the area shown. In the centre of the scale\n is identical to that of the conventional Mercator projection (but only at\n that centre). The area in the projection centre is therefore exactly conformal.\n* QC: the projection method is quasi-cartesian, i.e. the horizontal and vertical\n scales are equal to one another in terms of cm/degree.\n\nAll coordinates of locations and geographical grid sizes are given in degrees;`x`\nis longitude with `x = 0` being the Greenwich meridian and `x > 0` is East of this\nmeridian; `y` is latitude with `y > 0` being the Northern hemisphere. Input and\noutput grids have to be oriented with their x-axis to the East; mesh sizes are in\ndegrees. All other distances are in meters.\n\nNote that spherical coordinates can also be used for relatively small areas, say 10\nor 20 km horizontal dimension. This may be useful if one obtains the boundary\nconditions by nesting in an oceanic model which is naturally formulated in\nspherical coordinates. Note that in case of spherical coordinates regular grids\nmust always be oriented E-W, N-S, i.e. `alpc=0`, `alpinp=0`, `alpfr=0`\n(see commands CGRID, INPUT GRID and FRAME, respectively).\n\nExamples\n--------\n\n.. ipython:: python\n :okwarning:\n\n from rompy.swan.components.startup import SPHERICAL\n coords = SPHERICAL()\n print(coords.render())\n coords = SPHERICAL(projection=\"qc\")\n print(coords.render())", "type": "object", "properties": { "model_type": { "default": "spherical", "description": "Model type discriminator", "enum": [ "spherical", "SPHERICAL" ], "title": "Model Type", "type": "string" }, "projection": { "default": "ccm", "description": "Defines the projection method in case of spherical coordinates, `ccm` Central Conformal Mercator, `qc` means Quasi-cartesian", "enum": [ "ccm", "qc" ], "title": "Projection", "type": "string" } }, "additionalProperties": false }
- field model_type: Literal['spherical', 'SPHERICAL'] = 'spherical'#
Model type discriminator
- field projection: Literal['ccm', 'qc'] = 'ccm'#
Defines the projection method in case of spherical coordinates, ccm Central Conformal Mercator, qc means Quasi-cartesian