modelBattery
Simple battery model
Extends from Modelica.Electrical.Analog.Interfaces.TwoPin (Component with two electrical pins).
Information
A simple battery model: SOC (state of charge) is tracked by measuring the current and integrating to achieve charge.
For simplicity reasons the prescribed open-circuit voltage depends linearly on state of charge between
Voc at SOC=1 and Vmin at SOCmin.
Additionally the internal resistance (computed from short-circuit current Isc at SOC=1) is taken into account.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Units.SI.Voltage | Voc | 60 | Open circuit voltage at SOC=1 |
| Modelica.Units.SI.Voltage | Vmin | 48 | Minimum open-circuit voltage at SOCmin |
| Modelica.Units.SI.Current | Isc | 250 | Short-circuit current at SOC=1 |
| Modelica.Units.SI.ElectricCharge | Qnom | 20*3600 | Nominal (maximum) charge |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| PositivePin | p (from TwoPin) | Positive electrical pin | |
| NegativePin | n (from TwoPin) | Negative electrical pin |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| SI.Voltage | v (from TwoPin) | Voltage drop of the two pins (= p.v - n.v) | |
| Modelica.Units.SI.Current | i | p.i | Current consumed by battery |
| Modelica.Units.SI.Power | power | v*i | Power consumed by battery |
| Real | SOC | soc.y | State of charge |
| Modelica.Electrical.Analog.Sensors.CurrentSensor | currentSensor | ||
| Modelica.Electrical.Analog.Sources.SignalVoltage | signalVoltage | ||
| Modelica.Electrical.Analog.Basic.Resistor | resistor | ||
| Modelica.Blocks.Continuous.Integrator | soc | ||
| Subcomponents.Soc2v | soc2v |