{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/math.pythagorean/1.2.0/input.json",
  "title": "Pythagorean theorem — input",
  "type": "object",
  "properties": {
    "a": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": [
        1,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "x-unit-policy": "arbitrary_consistent_length",
      "x-uuce-role": "scalar"
    },
    "aInput": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": [
        1,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "x-unit-policy": "arbitrary_consistent_length",
      "x-uuce-role": "scalar"
    },
    "leg_a": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": "L",
      "x-unit-policy": "arbitrary_consistent_length"
    },
    "legA": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": "L",
      "x-unit-policy": "arbitrary_consistent_length"
    },
    "b": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": [
        1,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "x-unit-policy": "arbitrary_consistent_length",
      "x-uuce-role": "scalar"
    },
    "bInput": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": [
        1,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "x-unit-policy": "arbitrary_consistent_length",
      "x-uuce-role": "scalar"
    },
    "leg_b": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": "L",
      "x-unit-policy": "arbitrary_consistent_length"
    },
    "legB": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "leg",
      "x-dimension": "L",
      "x-unit-policy": "arbitrary_consistent_length"
    },
    "c": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "hypotenuse",
      "x-dimension": [
        1,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "x-unit-policy": "arbitrary_consistent_length",
      "x-uuce-role": "scalar"
    },
    "cInput": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "hypotenuse",
      "x-dimension": [
        1,
        0,
        0,
        0,
        0,
        0,
        0
      ],
      "x-unit-policy": "arbitrary_consistent_length",
      "x-uuce-role": "scalar"
    },
    "hypotenuse": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "hypotenuse",
      "x-dimension": "L",
      "x-unit-policy": "arbitrary_consistent_length"
    },
    "hyp": {
      "oneOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "string",
          "maxLength": 512,
          "pattern": "^\\s*(?:[+-]?(?:[0-9]+(?:\\.[0-9]*)?|\\.[0-9]+)(?:[eE][+-]?[0-9]+)?)?\\s*$"
        }
      ],
      "x-quantity-kind": "length",
      "x-role": "hypotenuse",
      "x-dimension": "L",
      "x-unit-policy": "arbitrary_consistent_length"
    },
    "mode": {
      "type": "string",
      "maxLength": 512,
      "pattern": "^\\s*(?:[sS][oO][lL][vV][eE]|[vV][eE][rR][iI][fF][yY]|[cC][hH][eE][cC][kK])\\s*$"
    },
    "solveFor": {
      "type": "string",
      "maxLength": 512,
      "pattern": "^\\s*(?:[aA]|[bB]|[cC]|[hH][yY][pP]|[hH][yY][pP][oO][tT][eE][nN][uU][sS][eE])\\s*$"
    },
    "solve_for": {
      "type": "string",
      "maxLength": 512,
      "pattern": "^\\s*(?:[aA]|[bB]|[cC]|[hH][yY][pP]|[hH][yY][pP][oO][tT][eE][nN][uU][sS][eE])\\s*$"
    }
  },
  "anyOf": [
    {
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "a"
              ]
            },
            {
              "required": [
                "aInput"
              ]
            },
            {
              "required": [
                "leg_a"
              ]
            },
            {
              "required": [
                "legA"
              ]
            }
          ]
        },
        {
          "anyOf": [
            {
              "required": [
                "b"
              ]
            },
            {
              "required": [
                "bInput"
              ]
            },
            {
              "required": [
                "leg_b"
              ]
            },
            {
              "required": [
                "legB"
              ]
            }
          ]
        }
      ]
    },
    {
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "a"
              ]
            },
            {
              "required": [
                "aInput"
              ]
            },
            {
              "required": [
                "leg_a"
              ]
            },
            {
              "required": [
                "legA"
              ]
            }
          ]
        },
        {
          "anyOf": [
            {
              "required": [
                "c"
              ]
            },
            {
              "required": [
                "cInput"
              ]
            },
            {
              "required": [
                "hypotenuse"
              ]
            },
            {
              "required": [
                "hyp"
              ]
            }
          ]
        }
      ]
    },
    {
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "b"
              ]
            },
            {
              "required": [
                "bInput"
              ]
            },
            {
              "required": [
                "leg_b"
              ]
            },
            {
              "required": [
                "legB"
              ]
            }
          ]
        },
        {
          "anyOf": [
            {
              "required": [
                "c"
              ]
            },
            {
              "required": [
                "cInput"
              ]
            },
            {
              "required": [
                "hypotenuse"
              ]
            },
            {
              "required": [
                "hyp"
              ]
            }
          ]
        }
      ]
    }
  ],
  "additionalProperties": false,
  "description": "Raw decimal inputs; blanks count as absent at semantic validation. At least two positive finite sides,matching aliases; explicit solve_for selects ignored output,all three otherwise verify. Numeric underflow/overflow,geometry,mode conflicts and unknown fields reject. All supplied side tokens are validated,including an explicit output. (calculation_version 1.2.0)",
  "x-unit-contract": {
    "protocol": "calculatorx-field-unit-contract-v1",
    "capability_id": "math.pythagorean",
    "registry_version": "0.3.0-preview.3",
    "declaration_scope": "Field/branch declarations only; inactive fields are not asserted to exist. No conversion-engine migration or new numerical certification.",
    "path_format": "Paths relative to inputs or result_detail.value; dot separates properties, * denotes array items, $ denotes a scalar result.",
    "inputs": {},
    "outputs": {},
    "quantity_policy": {
      "physical_unit_id": null,
      "input_policy": "Abstract consistent coordinate/length units; no physical unit is selected by this calculator.",
      "derived_policy": "Lengths inherit the input length unit U; areas U^2; volumes U^3. No implicit conversion or fixed metre binding.",
      "coefficient_policy": "Normalized implicit line/equation coefficients have equation-scale conventions, not universal physical unit IDs.",
      "model_roles": "leg/hypotenuse are geometric model roles, distinct from the UUCE scalar unit role."
    }
  }
}
