{
  "node": {
    "id": "block:ficks_first_law_flux",
    "type": "Block",
    "label": "ficks_first_law_flux",
    "properties": {
      "id": "ficks_first_law_flux",
      "name": "ficks_first_law_flux",
      "kind": "core",
      "summary": "One-dimensional diffusive molar flux for a supplied concentration gradient.",
      "behavior": "Diffusivity must be finite and nonnegative; the gradient must be finite. Scalar and broadcastable array inputs are supported. This evaluates a constitutive law, not a spatial PDE, gradient estimator or boundary-condition solver.",
      "ports": [
        {
          "name": "return",
          "direction": "output",
          "unit": "mol/(m^2 s)",
          "description": "Scalar float or NumPy array following broadcasting."
        }
      ],
      "parameters": [
        {
          "key": "diffusivity",
          "label": "diffusivity",
          "unit": "m^2/s",
          "description": "Finite nonnegative diffusion coefficient."
        },
        {
          "key": "concentration_gradient",
          "label": "concentration gradient",
          "unit": "mol/m^4",
          "description": "Finite spatial concentration gradient."
        }
      ],
      "equations": [
        "J = -D * dc/dx"
      ],
      "example": {
        "title": "Calculate diffusion flux",
        "text": "For D = 1 × 10⁻¹⁰ m²/s and dc/dx = 2 × 10⁶ mol/m⁴, J = −2 × 10⁻⁴ mol/(m²·s).",
        "url": "https://lemonergy.com/learn/transport/ficks-first-law/",
        "label": "Open the worked lesson"
      },
      "limits": [
        "This does not solve second-law time evolution or specify boundary conditions."
      ],
      "evidence": [
        "src/battery_core/diffusion.py"
      ],
      "caseIds": [
        "fick-flux"
      ],
      "type": "ficks_first_law_flux",
      "implementationId": "ficks_first_law_flux",
      "url": "https://lemonergy.com/learn/glossary/blocks/ficks_first_law_flux/",
      "documentationUrl": "https://lemonergy.com/learn/glossary/blocks/ficks_first_law_flux/",
      "sourceFile": "block-library.json",
      "sourceRepository": "battery-core",
      "sourceRevision": "main",
      "reviewed": "2026-10-27"
    }
  },
  "incoming": [
    {
      "id": "edge:usesBlock/fick-flux/0",
      "type": "usesBlock",
      "source": "workflow:fick-flux",
      "target": "block:ficks_first_law_flux",
      "properties": {
        "sourceFile": "wiki-blocks.json",
        "position": 0,
        "name": "ficks_first_law_flux",
        "type": "ficks_first_law_flux",
        "role": "Core equation",
        "settings": [
          "D (m²/s)",
          "dc/dx (mol/m⁴)"
        ]
      }
    }
  ],
  "neighbors": [
    {
      "id": "workflow:fick-flux",
      "type": "Workflow",
      "label": "Calculate diffusion flux",
      "properties": {
        "id": "fick-flux",
        "title": "Calculate diffusion flux",
        "kind": "core",
        "summary": "Lemonergy Core evaluates this relation.",
        "steps": [
          "Open the lesson and inspect the equation.",
          "Change one input while holding the others fixed."
        ],
        "example": "For D = 1 × 10⁻¹⁰ m²/s and dc/dx = 2 × 10⁶ mol/m⁴, J = −2 × 10⁻⁴ mol/(m²·s).",
        "observe": "Compare the result with the equation and units.",
        "limits": "This does not solve second-law time evolution or specify boundary conditions.",
        "url": "https://lemonergy.com/learn/transport/ficks-first-law/",
        "label": "Open the worked lesson",
        "evidence": [
          "src/battery_core/diffusion.py"
        ]
      }
    }
  ]
}
