Function control external circuit#
- class pybamm.external_circuit.FunctionControl(param, external_circuit_function, options, control='algebraic')#
External circuit with an arbitrary function, implemented as a control on the current either via an algebraic equation, or a differential equation.
- Parameters:
param (parameter class) – The parameters to use for this submodel
external_circuit_function (callable) – The function that controls the current
options (dict) – Dictionary of options to use for the submodel
control (str, optional) – The type of control to use. Must be one of ‘algebraic’ (default) or ‘differential’.
Extends:
pybamm.models.submodels.external_circuit.base_external_circuit.BaseModel
- get_fundamental_variables()#
A public method that creates and returns the variables in a submodel which can be created independent of other submodels. For example, the electrolyte concentration variables can be created independent of whether any other variables have been defined in the model. As a rule, if a variable can be created without variables from other submodels, then it should be placed in this method.
- Returns:
The variables created by the submodel which are independent of variables in other submodels.
- Return type:
- set_algebraic(variables)#
A method to set the differential equations which do not contain a time derivative. Note: this method modifies the state of self.algebraic. Unless overwritten by a submodel, the default behaviour of ‘pass’ is used as implemented in
pybamm.BaseSubModel
.- Parameters:
variables (dict) – The variables in the whole model.
- set_initial_conditions(variables)#
A method to set the initial conditions for the submodel. Note: this method modifies the state of self.initial_conditions. Unless overwritten by a submodel, the default behaviour of ‘pass’ is used as implemented in
pybamm.BaseSubModel
.- Parameters:
variables (dict) – The variables in the whole model.
- set_rhs(variables)#
A method to set the right hand side of the differential equations which contain a time derivative. Note: this method modifies the state of self.rhs. Unless overwritten by a submodel, the default behaviour of ‘pass’ is used as implemented in
pybamm.BaseSubModel
.- Parameters:
variables (dict) – The variables in the whole model.
- class pybamm.external_circuit.VoltageFunctionControl(param, options)#
External circuit with voltage control, implemented as an extra algebraic equation.
Extends:
pybamm.models.submodels.external_circuit.function_control_external_circuit.FunctionControl
- class pybamm.external_circuit.PowerFunctionControl(param, options, control='algebraic')#
External circuit with power control.
Extends:
pybamm.models.submodels.external_circuit.function_control_external_circuit.FunctionControl
- class pybamm.external_circuit.ResistanceFunctionControl(param, options, control='algebraic')#
External circuit with resistance control.
Extends:
pybamm.models.submodels.external_circuit.function_control_external_circuit.FunctionControl
- class pybamm.external_circuit.CCCVFunctionControl(param, options)#
External circuit with constant-current constant-voltage control, as implemented in Mohtat et al.[1].
References
Extends:
pybamm.models.submodels.external_circuit.function_control_external_circuit.FunctionControl