{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/math.complex.input.json",
  "title": "Complex numbers — input",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "mode": {
      "type": "string",
      "enum": [
        "add",
        "sub",
        "mul",
        "div",
        "rect_to_polar",
        "polar_to_rect",
        "conjugate",
        "modulus"
      ]
    },
    "re": {
      "type": "number"
    },
    "im": {
      "type": "number"
    },
    "re2": {
      "type": "number"
    },
    "im2": {
      "type": "number"
    },
    "r": {
      "type": "number",
      "minimum": 0
    },
    "arg_deg": {
      "type": "number",
      "description": "Argument in degrees, atan2 convention (−180, 180]"
    }
  },
  "description": "Rectangular and polar complex arithmetic: add, subtract, multiply, divide, conjugate, modulus. Not a CAS. (calculation_version 1.0.0)"
}
