{
  "node": {
    "id": "block:battery-thermal-state-space",
    "type": "Block",
    "label": "Thermal state-space model",
    "properties": {
      "id": "battery-thermal-state-space",
      "name": "Thermal state-space model",
      "kind": "studio",
      "summary": "Linear thermal rise model with a positive diagonal heat-capacity descriptor. User supplies validated matrices.",
      "behavior": "Solves a linear temperature-rise model with positive diagonal heat capacities. Heat inputs drive the state; output temperatures add the configured ambient temperature to the linear result.",
      "ports": [
        {
          "name": "input",
          "direction": "input",
          "unit": "W",
          "description": "Heat inputs; 2 channels at the default configuration.",
          "shape": [
            2
          ],
          "elementType": "real",
          "quantity": "heat"
        },
        {
          "name": "output",
          "direction": "output",
          "unit": "K",
          "description": "Temperature outputs; 2 channels at the default configuration.",
          "shape": [
            2
          ],
          "elementType": "real",
          "quantity": "temperature"
        }
      ],
      "parameters": [
        {
          "key": "ambientK",
          "label": "Ambient temperature (K)",
          "unit": "K",
          "default": 298.15,
          "description": "Ambient temperature (K). This is an editable model input; the default belongs to the synthetic worked example."
        },
        {
          "key": "A",
          "label": "State matrix A",
          "unit": "Model-dependent",
          "default": [
            [
              -2,
              1
            ],
            [
              1,
              -2
            ]
          ],
          "description": "Row-oriented state matrix. Dimensions must agree with B, C, D and the initial state."
        },
        {
          "key": "B",
          "label": "Input matrix B",
          "unit": "Model-dependent",
          "default": [
            [
              1,
              0
            ],
            [
              0,
              1
            ]
          ],
          "description": "Row-oriented input matrix. One column per input channel."
        },
        {
          "key": "C",
          "label": "Output matrix C",
          "unit": "Model-dependent",
          "default": [
            [
              1,
              0
            ],
            [
              0,
              1
            ]
          ],
          "description": "Row-oriented output matrix. One row per output channel."
        },
        {
          "key": "D",
          "label": "Feedthrough matrix D",
          "unit": "Model-dependent",
          "default": [
            [
              0,
              0
            ],
            [
              0,
              0
            ]
          ],
          "description": "Row-oriented direct feedthrough matrix; output rows by input columns."
        },
        {
          "key": "initial",
          "label": "Initial state vector",
          "unit": "See field order",
          "default": [
            0,
            0
          ],
          "description": "Initial state vector, with one value per state."
        },
        {
          "key": "capacityDiagonal",
          "label": "Node heat capacities (J/K)",
          "unit": "See field order",
          "default": [
            100,
            100
          ],
          "description": "Node heat capacities (J/K). This is an editable model input; the default belongs to the synthetic worked example."
        }
      ],
      "equations": [
        "diag(capacity)*dx/dt = A*x + B*Q",
        "Toutput = ambientK + C*x + D*Q"
      ],
      "example": {
        "title": "Thermal state-space model worked example",
        "text": "Use the defaults below with Heat inputs = [10, 0] W. At 0 s, Temperature outputs is [298.15, 298.15] K. Additional checks are listed below.",
        "url": "https://design.lemonergy.com/cosim.html?example=block-battery-thermal-state-space",
        "label": "Open Studio example",
        "checks": [
          {
            "port": "output",
            "atS": 0,
            "value": [
              298.15,
              298.15
            ],
            "tolerance": 1e-08,
            "label": "Temperature outputs",
            "unit": "K"
          }
        ],
        "inputs": [
          {
            "port": "input",
            "label": "Heat inputs",
            "value": [
              10,
              0
            ],
            "unit": "W"
          }
        ]
      },
      "limits": [
        "Supports a positive diagonal descriptor, not an arbitrary descriptor matrix. No finite-element import or conserving thermal adapter; supplied matrices determine heat conservation and stability.",
        "The example verifies numerical behavior for synthetic parameters. Cell characterization and validation for an intended use are separate tasks."
      ],
      "availability": {
        "status": "released",
        "label": "Available in Lemonergy Studio",
        "detail": "The bundled example is available in the production release verified on 28 October 2026. The parameters and examples here are synthetic teaching fixtures, not a characterized cell or a validated operating limit."
      },
      "references": [
        "openstax-heat",
        "astrom-murray-feedback"
      ],
      "evidence": [
        "docs/glossary/native-block-verification.json"
      ],
      "sourceRepository": "Lemonergy Studio public contract",
      "sourceRevision": "verification-2026-10-27",
      "caseIds": [
        "native-battery-thermal-state-space"
      ],
      "exampleTraces": [
        {
          "id": "battery-thermal-state-space",
          "url": "https://lemonergy.com/learn/glossary/api/traces/battery-thermal-state-space.json?v=e398d07c9249",
          "title": "Thermal state-space model recorded example",
          "exampleId": "block-battery-thermal-state-space",
          "source": "Executed synthetic Lemonergy Studio example",
          "recordedOn": "2026-10-28",
          "points": 103,
          "channels": 2,
          "omittedChannels": 0,
          "interpolation": "linear",
          "solver": {
            "method": "dormand-prince-45",
            "reason": "non-stiff-time-scales"
          }
        }
      ],
      "type": "battery-thermal-state-space",
      "implementationId": "battery-thermal-state-space",
      "url": "https://lemonergy.com/learn/glossary/blocks/battery-thermal-state-space/",
      "documentationUrl": "https://lemonergy.com/learn/glossary/blocks/battery-thermal-state-space/",
      "sourceFile": "block-library.json",
      "reviewed": "2026-10-27",
      "releaseEvidence": {
        "environment": "production",
        "status": "verified",
        "revision": "e76cadfc203e15eb41f3478d8b1044a5b851953d",
        "verifiedOn": "2026-10-28",
        "exampleUrls": [
          "https://design.lemonergy.com/cosim.html?example=block-battery-thermal-state-space"
        ]
      }
    }
  },
  "incoming": [
    {
      "id": "edge:usesBlock/native-battery-thermal-state-space/0",
      "type": "usesBlock",
      "source": "workflow:native-battery-thermal-state-space",
      "target": "block:battery-thermal-state-space",
      "properties": {
        "sourceFile": "wiki-blocks.json",
        "position": 0,
        "name": "Thermal state-space model",
        "type": "battery-thermal-state-space",
        "role": "Solves a linear temperature-rise model with positive diagonal heat capacities. Heat inputs drive the state; output temperatures add the configured ambient temperature to the linear result.",
        "settings": [
          "Use the parameter values in the block reference.",
          "Bundled example verified on the production release of 28 October 2026."
        ]
      }
    }
  ],
  "outgoing": [
    {
      "id": "edge:cites/block:battery-thermal-state-space/reference:astrom-murray-feedback",
      "type": "cites",
      "source": "block:battery-thermal-state-space",
      "target": "reference:astrom-murray-feedback",
      "properties": {
        "sourceFile": "block-library.json",
        "scope": "Scientific or mathematical background; implementation scope is stated by the block contract"
      }
    },
    {
      "id": "edge:cites/block:battery-thermal-state-space/reference:openstax-heat",
      "type": "cites",
      "source": "block:battery-thermal-state-space",
      "target": "reference:openstax-heat",
      "properties": {
        "sourceFile": "block-library.json",
        "scope": "Scientific or mathematical background; implementation scope is stated by the block contract"
      }
    }
  ],
  "neighbors": [
    {
      "id": "workflow:native-battery-thermal-state-space",
      "type": "Workflow",
      "label": "Thermal state-space model worked example",
      "properties": {
        "id": "native-battery-thermal-state-space",
        "title": "Thermal state-space model worked example",
        "kind": "studio",
        "summary": "Linear thermal rise model with a positive diagonal heat-capacity descriptor. User supplies validated matrices.",
        "steps": [
          "Review the block inputs, units and model limits.",
          "Open the Studio example and run its bundled model.",
          "Compare the output channels with the numerical checks; change one input and run again."
        ],
        "example": "Use the defaults below with Heat inputs = [10, 0] W. At 0 s, Temperature outputs is [298.15, 298.15] K. Additional checks are listed below.",
        "observe": "Inspect the outputs and numerical checks on the block reference page.",
        "limits": "Supports a positive diagonal descriptor, not an arbitrary descriptor matrix. No finite-element import or conserving thermal adapter; supplied matrices determine heat conservation and stability. The example verifies numerical behavior for synthetic parameters. Cell characterization and validation for an intended use are separate tasks.",
        "url": "https://design.lemonergy.com/cosim.html?example=block-battery-thermal-state-space",
        "label": "Open Studio example",
        "evidence": [
          "docs/glossary/native-block-verification.json"
        ]
      }
    },
    {
      "id": "reference:astrom-murray-feedback",
      "type": "Reference",
      "label": "Feedback Systems: An Introduction for Scientists and Engineers, second edition",
      "properties": {
        "title": "Feedback Systems: An Introduction for Scientists and Engineers, second edition",
        "publisher": "Princeton University Press; author-maintained FBSwiki",
        "url": "https://fbswiki.org/wiki/index.php/Feedback_Systems%3A_An_Introduction_for_Scientists_and_Engineers",
        "type": "Textbook",
        "scope": "State-space modeling, feedback and PID control. These mathematical foundations do not establish a particular software implementation.",
        "year": 2021,
        "authors": [
          "Karl J. Åström",
          "Richard M. Murray"
        ],
        "accessed": "2026-10-27"
      }
    },
    {
      "id": "reference:openstax-heat",
      "type": "Reference",
      "label": "University Physics Volume 2, §1.6: Mechanisms of Heat Transfer",
      "properties": {
        "title": "University Physics Volume 2, §1.6: Mechanisms of Heat Transfer",
        "publisher": "OpenStax, Rice University",
        "url": "https://openstax.org/books/university-physics-volume-2/pages/1-6-mechanisms-of-heat-transfer",
        "type": "Textbook section",
        "scope": "Conduction, convection, radiation and thermal resistance.",
        "accessed": "2026-10-27"
      }
    }
  ]
}
