Battery
Physical Networks
运行在线示例
免费 · 无需注册 · 直接在浏览器中运行
Physical battery cell (Battery) modeling State-of-Charge (SOC) dynamics via Coulomb counting, an SOC-dependent open-circuit voltage , internal ohmic resistance , and Joule heating exported to q_diss and the optional H thermal port.
数学模型
输入与输出
| Direction | ID | Label | 类型 | Status |
|---|---|---|---|---|
| → In | p |
+ | number | Required |
| → In | n |
- | number | Required |
| → In | H |
H | number | Optional |
| ← Out | soc |
SOC | number | Output |
| ← Out | q_diss |
Q_diss | number | Output |
参数
| 参数 | Label | 类型 | 默认值 | 描述 |
|---|---|---|---|---|
nominalVoltage |
Nominal Voltage | number | 12 |
Nominal battery pack voltage [V] |
capacityAh |
Capacity | number | 5 |
Ampere-hour charge capacity [Ah] |
initialSoc |
Initial SOC | number | 0.8 |
Starting State of Charge (0..1) |
internalResistance |
Internal Resistance (R0) | number | 0.05 |
Internal ohmic resistance [Ω] |
emptyVoltage |
Empty Voltage (SOC=0) | number | 10.2 |
Open-circuit voltage at 0% SOC [V] |
fullVoltage |
Full Voltage (SOC=1) | number | 13.8 |
Open-circuit voltage at 100% SOC [V] |
使用示例
Example 1: Battery Discharging into Resistive Load
Connect Battery (capacityAh = 0.01) to a 10 Ω Resistor and Ground to observe terminal voltage sag and falling soc.
Example 2: EV / Drone Drivetrain
Power a DCMotor via a ControlledSwitch H-bridge directly from a Battery with H connected to a ThermalMass.
说明与最佳实践
- Thermal Self-Heating: Connect
Hto aThermalMassto model battery temperature rise . - SOC Clamping: SOC is clamped smoothly to so the cell cannot over-discharge below 0% or over-charge above 100%.
相关模块
- VoltageSource/docs.md" class="bw-link">VoltageSource
- BatterySocEkf/docs.md" class="bw-link">BatterySocEkf
- DCMotor/docs.md" class="bw-link">DCMotor