{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.calculatorx.com/schemas/electrical.mosfet.vth.input.json",
  "title": "MOSFET Threshold / Overdrive — input",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "mode": {
      "type": "string",
      "enum": [
        "overdrive",
        "id",
        "vth"
      ],
      "description": "Quantity to solve for. Default overdrive. Human UI, REST, and MCP share these modes."
    },
    "Vgs_V": {
      "type": "number",
      "description": "Gate-source voltage (V)."
    },
    "Vth_V": {
      "type": "number",
      "description": "Square-law threshold parameter (V). Not datasheet VGS(th) and not recommended gate-drive voltage. Required for overdrive and id."
    },
    "Id_A": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "Drain current (A). Required for mode=vth."
    },
    "kn_A_per_V2": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "kn = μn·Cox·W/L (A/V²) such that Id_sat = ½·kn·(Vgs−Vth)². Linear Id = kn·(Vod·Vds − Vds²/2). The ½ factor is NOT included in kn. Required for id and vth."
    },
    "Vds_V": {
      "type": "number",
      "minimum": 0,
      "description": "Optional drain-source voltage (V). Classifies cutoff / linear / saturation. Omit to keep Vod-only bookkeeping; Id then uses the saturation equation."
    },
    "temperature_model": {
      "type": "string",
      "enum": [
        "none",
        "linear"
      ],
      "description": "none (default) uses Vth as entered. linear applies Vth(Tj)=Vth(Tref)+α·(Tj−Tref). Omitted infers linear if Tj_C or alpha_V_per_C is set."
    },
    "Tj_C": {
      "type": "number",
      "minimum": -273.15,
      "description": "Junction temperature (°C). Required for temperature_model=linear."
    },
    "Tref_C": {
      "type": "number",
      "minimum": -273.15,
      "description": "Reference temperature (°C) for entered Vth. Default 25."
    },
    "alpha_V_per_C": {
      "type": "number",
      "description": "dVth/dT in V/°C. Default −0.002 (≈ −2 mV/°C Si planning) when linear and omitted. Not a datasheet TCV of VGS(th)."
    }
  },
  "required": [
    "Vgs_V"
  ],
  "description": "Overdrive, square-law Id (cutoff / linear / saturation), or solve model Vth, with optional linear Vth(Tj). Vth is the long-channel square-law parameter, not datasheet VGS(th). (calculation_version 1.3.1)"
}
