rompy.swan.subcomponents.spectrum.JONSWAP#

pydantic model rompy.swan.subcomponents.spectrum.JONSWAP[source]#

Jonswap spectral shape.

JONSWAP [gamma]

Examples

In [109]: from rompy.swan.subcomponents.spectrum import JONSWAP

In [110]: shape = JONSWAP(gamma=3.3)

In [111]: print(shape.render())
JONSWAP gamma=3.3

Show JSON schema
{
   "title": "JONSWAP",
   "description": "Jonswap spectral shape.\n\n.. code-block:: text\n\n    JONSWAP [gamma]\n\nExamples\n--------\n\n.. ipython:: python\n    :okwarning:\n\n    from rompy.swan.subcomponents.spectrum import JONSWAP\n    shape = JONSWAP(gamma=3.3)\n    print(shape.render())",
   "type": "object",
   "properties": {
      "model_type": {
         "default": "jonswap",
         "description": "Model type discriminator",
         "enum": [
            "jonswap",
            "JONSWAP"
         ],
         "title": "Model Type",
         "type": "string"
      },
      "gamma": {
         "default": 3.3,
         "description": "Peak enhancement parameter of the JONSWAP spectrum.",
         "exclusiveMinimum": 0.0,
         "title": "Gamma",
         "type": "number"
      }
   },
   "additionalProperties": false
}

Fields:
field gamma: float = 3.3#

Peak enhancement parameter of the JONSWAP spectrum.

Constraints:
  • gt = 0.0

field model_type: Literal['jonswap', 'JONSWAP'] = 'jonswap'#

Model type discriminator

cmd() str[source]#