{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/physics.fluid.drowned_sluice.input.json",
  "title": "Drowned sluice — input",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "mode": {
      "type": "string",
      "enum": [
        "flow",
        "opening"
      ],
      "description": "flow (default, Q) or opening (invert a). Not free-flow sluice head."
    },
    "a": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Gate opening in m. Required for flow. Alternatives: a_m, opening, gate_opening. Not orifice A."
    },
    "b": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Gate width in m. Required. Alternatives: b_m, width, gate_width. Not weir L, not side-weir B."
    },
    "y1": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Upstream depth in m. Required. Alternatives: y_1, upstream_depth. Not weir H or H1."
    },
    "y2": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Downstream depth in m. Required. Alternatives: y_2, downstream_depth. Drowned when y1 < 0.81 y2 (y2/a)^{0.72}."
    },
    "Q": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Volume flow in m³/s. Required for opening. Alternatives: flow, Q_m3_s."
    }
  },
  "required": [
    "b",
    "y1",
    "y2"
  ],
  "description": "Swamee 1992 drowned undershot sluice: Q=C_d a b √(2g y1) with C_d from y1, a, and y2. Not free-flow sluice, not Villemonte H1+H2, not tank orifice, not Manning n, not Q=Av. (calculation_version 1.0.0)"
}
