# 耦合電感 (`coupledInductor`)

> 兩個共用磁通的繞組，以耦合係數 k 表示耦合程度。

![coupledInductor](https://voltecx-web.nguyenvanqui291.workers.dev/docs/reference/img/coupledInductor.svg)

[元件參考](https://voltecx-web.nguyenvanqui291.workers.dev/zh/docs/reference/) · [English](https://voltecx-web.nguyenvanqui291.workers.dev/docs/reference/magnetics/coupledInductor/)

**分類:** 磁性元件 · **種類:** `{"kind":"coupledInductor"}`

## 何時使用

用於返馳式轉換器、耦合電感轉換器與有漏感的變壓器。要理想匝數比時用變壓器。

## 接腳

| 接腳 | 訊號域 | 意義 |
|---|---|---|
| `p1` | 電氣 | 繞組 1 的打點端；正電流由此流入 |
| `n1` | 電氣 | 繞組 1 的另一端 |
| `p2` | 電氣 | 繞組 2 的打點端；正電流由此流入 |
| `n2` | 電氣 | 繞組 2 的另一端 |

## 常用參數

- `l1`: Inductance of the first winding (預設值: 必填)
- `l2`: Inductance of the second winding (預設值: 必填)
- `k`: How tightly the two windings are linked (預設值: 0.99)

## 參數

| 鍵 | 單位 | 預設值 | 典型範圍 | 說明 |
|---|---|---|---|---|
| `l1` | H | 必填 |  | Inductance of the first winding |
| `l2` | H | 必填 |  | Inductance of the second winding |
| `k` | — | 0.99 |  | How tightly the two windings are linked |
| `coupledCurve` | — | 選填（預設關閉） |  | Incremental inductances of the two windings against the core's magnetizing current from a field solve; rows i:L11:M:L22 in A and H from 0 A, such as 0:1e-4:9.8e-5:1e-4, 2:6e-5:5.8e-5:6e-5; sets the coupling in place of k |
| `rw1` | Ω | 0 |  | Wire resistance of the first winding |
| `rw2` | Ω | 0 |  | Wire resistance of the second winding |
| `rcore` | Ω | 選填（預設關閉） |  | Resistance across the first winding that models core loss |
| `surface` | m² | 選填（預設關閉） |  | Outside surface of the wound part to the air; design.thermal gives its temperature rise from it and the loss |

_參數說明在兩種語言中都是英文。_

**適用於:** 返馳式轉換器 · 耦合電感轉換器 · 含漏感的變壓器

**不適用於:** 理想匝數比與隔離 → [`transformer`](https://voltecx-web.nguyenvanqui291.workers.dev/zh/docs/reference/magnetics/transformer/) · 共模 EMI 濾波 → [`cmChoke`](https://voltecx-web.nguyenvanqui291.workers.dev/zh/docs/reference/magnetics/cmChoke/)

## 公式

| 公式 | 方程式 | 出處 |
|---|---|---|
| 互感 | M = k·√(l1·l2) | Hayt, Kemmerly & Durbin, Engineering Circuit Analysis, 8th ed. (2012), ch. 13 (coefficient of coupling) |
| 自繞組 1 看入的漏感 | Llk = l1·(1 − k²) | Hayt, Kemmerly & Durbin, Engineering Circuit Analysis, 8th ed. (2012), ch. 13 (input impedance with the second winding shorted) |
| 匝數比 | n = √(l1 / l2) | Erickson & Maksimović, Fundamentals of Power Electronics, 3rd ed. (2020), ch. 10 (L ∝ N² on one core) |

## 快速驗算

輸入:

- `l1`: 繞組 1 電感 = 100u H, `l1`
- `l2`: 繞組 2 電感 = 25u H, `l2`
- `k`: 耦合係數 = 990m —, `k`

輸出:

- `m`: 互感 = `k*sqrt(l1*l2)` H
- `llk`: 漏感 = `l1*(1 - k^2)` H
- `n`: 匝數比 = `sqrt(l1/l2)` —

## 模型邏輯

- 兩個繞組一起以 2 乘 2 電導矩陣加電流源蓋印（梯形法或後向尤拉法），M = k·√(l1·l2)。
- k 必須滿足 0 <= k < 1，否則拒絕執行；兩個繞組電流都從零開始，沒有初始電流參數。
- 設定 coupledCurve 時，以上一個接受步電流下的電感矩陣取代 l1、l2 與 k，k 只會引起警告。
- 繞組電阻、鐵損與兩段式飽和都沒有建模；需要時請自行串聯電阻。

## 模型

繞組遵循 v1 = l1 * di1/dt + M * di2/dt 與 v2 = M * di1/dt + l2 * di2/dt，其中 M = k * sqrt(l1 * l2)。兩個電流都以流入打點端為正。k 必須滿足 0 <= k < 1（預設 0.99），繞組 1 的漏感約為 l1 * (1 - k^2)。不模擬繞組電阻、鐵損、飽和與初始電流。

## 常見錯誤

- k 等於 1 會被拒絕，接近理想的耦合請用 0.999。p1 與 p2 是打點端，把其中一個繞組的接線對調就會反轉極性。
- 沒有通往地的繞組會漂浮。電感單位是亨利，所以 100 是 100 H，不是 100u。

Problems 規則: `island.floating`, `param.out_of_range`

## 規格書與來源

l1 與 l2 取自另一個繞組開路時，各繞組量到的電感。k 由漏感量測推得：k = sqrt(1 - Lleak / l1)，Lleak 是繞組 2 短路時，在繞組 1 量到的電感。

## 範例

以指令 `file.openExample` 開啟範例，名稱為 `demo:coupledInductor`.

---
由 `cargo xtask reference` 依使用說明文字與參數規格產生，請勿手動編輯。
