{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/electrical.power/1.3.0/input.json",
  "title": "Electric power — input",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "mode": {
      "type": "string",
      "enum": [
        "power-vi",
        "power-ir",
        "power-energy",
        "vi",
        "vi_dc",
        "vi_ac_single",
        "vi_ac_three_phase_ll",
        "i2r",
        "energy_average"
      ],
      "description": "power-vi (default) with phase; or semantic vi_dc / vi_ac_single / vi_ac_three_phase_ll / i2r / energy_average"
    },
    "a": {
      "type": "number",
      "description": "Share-URL alias: V (V×I), R (I²R), or E (energy)"
    },
    "b": {
      "type": "number",
      "description": "Share-URL alias: I (V×I / I²R) or Δt (energy)"
    },
    "V": {
      "type": "number",
      "minimum": 0,
      "description": "Voltage (V); L-L RMS when phase=three"
    },
    "I": {
      "type": "number",
      "minimum": 0,
      "description": "Current (A)"
    },
    "R": {
      "type": "number",
      "minimum": 0,
      "description": "Resistance (Ω) on I²R path"
    },
    "E": {
      "type": "number",
      "minimum": 0,
      "description": "Energy (J) on energy path"
    },
    "dt": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Time interval Δt (s); must be > 0"
    },
    "phase": {
      "type": "string",
      "enum": [
        "single",
        "three"
      ],
      "description": "Used with mode=power-vi; three = balanced L-L"
    },
    "power_factor": {
      "type": "number",
      "minimum": 0,
      "maximum": 1,
      "description": "Total power factor λ in [0, 1]. Blank/omitted defaults to 1. PF=0 is valid (P=0). Legacy alias pf accepted by the API adapter."
    }
  },
  "description": "Real power in watts from V×I×PF (DC / 1φ / balanced 3φ L-L), from I²R, or average power E/Δt. PF=0 is valid (P=0); blank PF defaults to 1. Δt=0 is INVALID_TIME_INTERVAL. (calculation_version 1.3.0)"
}
