{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/math.special.agent.input.json",
  "title": "Special functions — agent input",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "mode": {
      "type": "string",
      "minLength": 1,
      "maxLength": 80,
      "description": "Default erf only when absent. Canonical choices erf, erfc, gamma, lgamma, bessel_j, bessel_y, bessel_i, bessel_k, lambert_w, lambert_wm1, beta, incomplete_beta, sinc, normalized_sinc. Case/space/hyphen normalized; documented legacy mode aliases accepted."
    },
    "x": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "z": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "t": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "y": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "a": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "b": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "n": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "nu": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    },
    "order": {
      "oneOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "maxLength": 1024,
          "pattern": "^\\s*[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?\\s*$"
        }
      ],
      "description": "Finite decimal binary64 input. Nonzero text rounding to zero => NUMERIC_UNDERFLOW. Domain, alias agreement and numerical range checked after parsing."
    }
  },
  "description": "Raw Special Functions inputs: x (z/t scalar aliases; beta also a); beta requires y or b, incomplete_beta requires a and b or y. Bessel n (nu/order) defaults0 only when absent. Known irrelevant scalar fields are validated then ignored. Named aliases must agree. Full mode-dependent domains are enforced after normalization; schema-only success does not prove semantic validity. (calculation_version 1.10.6)",
  "oneOf": [
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[eE][rR][fF]|[eE][rR][rR][oO][rR]|[eE][rR][rR][oO][rR][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN]|[eE][rR][rR][oO][rR][fF][uU][nN][cC][tT][iI][oO][nN])\\s*$"
        }
      },
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[eE][rR][fF][cC]|[cC][oO][mM][pP][lL][eE][mM][eE][nN][tT][aA][rR][yY]|[cC][oO][mM][pP][lL][eE][mM][eE][nN][tT][aA][rR][yY][-\\s_]+[eE][rR][rR][oO][rR])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[gG][aA][mM][mM][aA]|[gG][aA][mM][mM][aA][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN]|[gG][aA][mM][mM][aA][fF][uU][nN][cC][tT][iI][oO][nN])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[lL][gG][aA][mM][mM][aA]|[lL][oO][gG][-\\s_]+[gG][aA][mM][mM][aA]|[lL][oO][gG][gG][aA][mM][mM][aA]|[lL][nN][gG][aA][mM][mM][aA]|[lL][nN][-\\s_]+[gG][aA][mM][mM][aA])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[bB][eE][sS][sS][eE][lL][-\\s_]+[jJ]|[bB][eE][sS][sS][eE][lL]|[jJ][nN]|[jJ][vV]|[bB][eE][sS][sS][eE][lL][jJ]|[bB][eE][sS][sS][eE][lL][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN]|[cC][yY][lL][iI][nN][dD][eE][rR])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[bB][eE][sS][sS][eE][lL][-\\s_]+[yY]|[bB][eE][sS][sS][eE][lL][yY]|[yY][nN]|[yY][vV]|[nN][eE][uU][mM][aA][nN][nN]|[wW][eE][bB][eE][rR]|[bB][eE][sS][sS][eE][lL][-\\s_]+[yY][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[bB][eE][sS][sS][eE][lL][-\\s_]+[iI]|[bB][eE][sS][sS][eE][lL][iI]|[iI][nN]|[iI][vV]|[mM][oO][dD][iI][fF][iI][eE][dD][-\\s_]+[bB][eE][sS][sS][eE][lL]|[mM][oO][dD][iI][fF][iI][eE][dD][bB][eE][sS][sS][eE][lL]|[bB][eE][sS][sS][eE][lL][-\\s_]+[iI][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[bB][eE][sS][sS][eE][lL][-\\s_]+[kK]|[bB][eE][sS][sS][eE][lL][kK]|[kK][nN]|[kK][vV]|[mM][aA][cC][dD][oO][nN][aA][lL][dD]|[mM][oO][dD][iI][fF][iI][eE][dD][-\\s_]+[bB][eE][sS][sS][eE][lL][-\\s_]+[kK]|[bB][eE][sS][sS][eE][lL][-\\s_]+[kK][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[lL][aA][mM][bB][eE][rR][tT][-\\s_]+[wW]|[lL][aA][mM][bB][eE][rR][tT]|[lL][aA][mM][bB][eE][rR][tT][wW]|[wW]0|[pP][rR][oO][dD][uU][cC][tT][-\\s_]+[lL][oO][gG]|[pP][rR][oO][dD][uU][cC][tT][lL][oO][gG]|[oO][mM][eE][gG][aA])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[lL][aA][mM][bB][eE][rR][tT][-\\s_]+[wW][mM]1|[lL][aA][mM][bB][eE][rR][tT][-\\s_]+[wW][-\\s_]+[mM]1|[wW][mM]1|[wW][-\\s_]+[mM][iI][nN][uU][sS][-\\s_]+1|[lL][aA][mM][bB][eE][rR][tT][-\\s_]+[wW][-\\s_]+[mM][iI][nN][uU][sS][-\\s_]+1|[pP][rR][oO][dD][uU][cC][tT][-\\s_]+[lL][oO][gG][-\\s_]+[mM]1|[pP][rR][oO][dD][uU][cC][tT][lL][oO][gG][mM]1)\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[bB][eE][tT][aA]|[bB][eE][tT][aA][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN]|[bB][eE][tT][aA][fF][uU][nN][cC][tT][iI][oO][nN]|[eE][uU][lL][eE][rR][-\\s_]+[bB][eE][tT][aA]|[eE][uU][lL][eE][rR][bB][eE][tT][aA]|[bB][-\\s_]+[xX][yY])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "a"
              ]
            }
          ]
        },
        {
          "anyOf": [
            {
              "required": [
                "y"
              ]
            },
            {
              "required": [
                "b"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[iI][nN][cC][oO][mM][pP][lL][eE][tT][eE][-\\s_]+[bB][eE][tT][aA]|[iI][bB][eE][tT][aA]|[bB][eE][tT][aA][iI][nN][cC]|[iI][nN][cC][oO][mM][pP][lL][eE][tT][eE][bB][eE][tT][aA]|[iI][nN][cC][oO][mM][pP][lL][eE][tT][eE][-\\s_]+[bB][eE][tT][aA][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN]|[bB][eE][tT][aA][iI][nN][cC][oO][mM][pP][lL][eE][tT][eE])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            }
          ]
        },
        {
          "required": [
            "a"
          ]
        },
        {
          "anyOf": [
            {
              "required": [
                "b"
              ]
            },
            {
              "required": [
                "y"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[sS][iI][nN][cC]|[sS][iI][nN][cC][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN]|[sS][iI][nN][cC][fF][uU][nN][cC][tT][iI][oO][nN]|[cC][aA][rR][dD][iI][nN][aA][lL][-\\s_]+[sS][iI][nN][eE]|[cC][aA][rR][dD][iI][nN][aA][lL][sS][iI][nN][eE]|[sS][aA])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    },
    {
      "properties": {
        "mode": {
          "type": "string",
          "pattern": "^\\s*(?:[nN][oO][rR][mM][aA][lL][iI][zZ][eE][dD][-\\s_]+[sS][iI][nN][cC]|[nN][sS][iI][nN][cC]|[sS][iI][nN][cC][nN]|[nN][oO][rR][mM][aA][lL][iI][zZ][eE][dD][sS][iI][nN][cC]|[sS][iI][nN][cC][-\\s_]+[nN][oO][rR][mM][aA][lL][iI][zZ][eE][dD]|[nN][oO][rR][mM][aA][lL][iI][zZ][eE][dD][-\\s_]+[sS][iI][nN][cC][-\\s_]+[fF][uU][nN][cC][tT][iI][oO][nN])\\s*$"
        }
      },
      "required": [
        "mode"
      ],
      "allOf": [
        {
          "anyOf": [
            {
              "required": [
                "x"
              ]
            },
            {
              "required": [
                "z"
              ]
            },
            {
              "required": [
                "t"
              ]
            }
          ]
        }
      ]
    }
  ]
}
