{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/math.numerical.definite_integral/1.1.5/input.json",
  "title": "Definite integral — input",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "method": {
      "type": "string",
      "description": "Case insensitive; spaces/hyphens normalize to underscores. simpson, simpson13, simpsons, simpson_rule, trapezoid, trapezoidal, trap, trapezoidal_rule, gauss, gauss_legendre, gl, quadrature, gausslegendre"
    },
    "mode": {
      "type": "string",
      "description": "Alias of method; supplied aliases must agree."
    },
    "integrand": {
      "type": "string",
      "description": "poly / polynomial, sin, exp / e^x"
    },
    "f": {
      "type": "string",
      "description": "Alias of integrand; supplied aliases must agree."
    },
    "a": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "minLength": 1,
          "pattern": "^[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?$"
        }
      ]
    },
    "b": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "string",
          "minLength": 1,
          "pattern": "^[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?$"
        }
      ]
    },
    "n": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 2,
          "maximum": 10000
        },
        {
          "type": "string",
          "pattern": "^\\+?\\d+(?:\\.0*)?(?:[eE][+\\-]?\\d+)?$",
          "description": "Must evaluate to an integer in 2–10000; Gauss 2–8."
        }
      ]
    },
    "coeffs": {
      "anyOf": [
        {
          "type": "string",
          "minLength": 1,
          "description": "2–9 constant-first decimal coefficients; constants use c0,0"
        },
        {
          "type": "array",
          "minItems": 2,
          "maxItems": 9,
          "items": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "string",
                "minLength": 1,
                "pattern": "^[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?$"
              }
            ]
          }
        }
      ]
    },
    "coefficients": {
      "anyOf": [
        {
          "type": "string",
          "minLength": 1,
          "description": "2–9 constant-first decimal coefficients; constants use c0,0"
        },
        {
          "type": "array",
          "minItems": 2,
          "maxItems": 9,
          "items": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "string",
                "minLength": 1,
                "pattern": "^[+\\-−–—]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:[eE][+\\-]?\\d+)?$"
              }
            ]
          }
        }
      ]
    }
  },
  "required": [
    "a",
    "b"
  ],
  "description": "Composite trapezoid, Simpson 1/3, or Gauss–Legendre of a polynomial, sin, or exp on [a, b]. Not indefinite symbolic integrate. (calculation_version 1.1.5)"
}
