Standard calculations
Double layer capacitance
LiquidElectrolytes.dlcapsweep
— Functionfunction dlcapsweep(
sys;
electrolyte = electrolytedata(sys),
inival = nothing,
voltages = (-1:0.1:1) * ufac"V",
δ = 1.0e-4,
store_solutions = false,
solver_kwargs...
)
Calculate double layer capacitances for voltages given in voltages
. Returns a DLCapSweepResult
.
Assumptions:
- Only one double layer in the system - close to working electrode.
LiquidElectrolytes.DLCapSweepResult
— Typestruct DLCapSweepResult <: AbstractSimulationResult
Result data type for dlcapsweep
voltages::Vector
: Vector of voltages
dlcaps::Vector
: Vector of double layer capacitances
solutions::Vector
: Vector of solutions
Access methods: voltages
, voltages_solutions
, voltages_dlcaps
e
Steady state voltammetry
LiquidElectrolytes.ivsweep
— Function ivsweep(
sys;
voltages = (-0.5:0.1:0.5) * ufac"V",
store_solutions = false,
solver_kwargs...,
)
Steady state voltammetry.
Calculate molar reaction rates and bulk flux rates for each voltage in voltages
. Returns a IVSweepResult
.
LiquidElectrolytes.IVSweepResult
— Typemutable struct IVSweepResult <: AbstractSimulationResult
Result data type for ivsweep
voltages::Any
: Vector of voltages
j_reaction::Any
: Working electrode molar reaction rates
j_we::Any
: Working electrode molar fluxes
j_bulk::Any
: Bulk molar fluxes
solutions::Any
: Vector of solutions
Access methods: voltages
, currents
, voltages_currents
, voltages_solutions
Cyclic voltammetry
LiquidElectrolytes.cvsweep
— Function cvsweep(
sys;
voltages=SawTooth(),
periods=1,
solver_kwargs...,
)
Cyclic voltammetry sweep. By default, voltages
given as a SawTooth
function.
Calculate molar reaction rates and working electrode flux rates. Returns a CVSweepResult
.
LiquidElectrolytes.CVSweepResult
— Typemutable struct CVSweepResult <: AbstractSimulationResult
Result type for cvsweep
.
Fields:
voltages::Any
: Vector of voltages
times::Any
: Vector of times
j_reaction::Any
: Working electrode molar reaction rates
j_bulk::Any
: Bulk molar fluxes
j_we::Any
: Working electrode molar fluxes
tsol::Any
: Transient solution
Access methods: voltages
, currents
voltages_currents
LiquidElectrolytes.SawTooth
— Typestruct SawTooth
Callable (functor) struct defining sawtooth function for cyclic voltammetry.
(::SawTooth)(t)
returns the voltage to be applied at moment t.
vmin::Float64
: Minimum voltage. Default: -1V.vmax::Float64
: Maximum voltage. Default: 1V.scanrate::Float64
: Scan rate. Default: 0.1V/s.vstart::Float64
: Start voltage. Default: 0Vtstart::Float64
: Start time. Default: 0sscanup::Bool
: Initial scan direction. Default: true
LiquidElectrolytes.period
— Functionperiod(st::SawTooth)
Return length of CV period
Supporting methods
LiquidElectrolytes.voltages_currents
— Functionvoltages_currents(result,ispec; electrode)
Voltage- working electrode current curve for species as DiffEqArray
LiquidElectrolytes.voltages_solutions
— Functionvoltages_solutions(result)
Return a TransientSolution
tsol
containing voltages (in tsol.t
) and the corresponding stationary solutions (in tsol.u
).
LiquidElectrolytes.currents
— Functioncurrents(result,ispec; electrode)
Vector of electrode currents for species ispec
. Electrode can be:
:bulk
: calculate current at bulk boundary conditions:we
: calculate current electrode interface:reaction
: calculate current from reaction term
LiquidElectrolytes.voltages_dlcaps
— Functionvoltages_dlcaps(result)
Double layer capacitance curve as DiffEqArray
LiquidElectrolytes.bulkbcondition
— Functionbulkbcondition(f,u,bnode,electrolyte; region = data.Γ_bulk)
Bulk boundary condition for electrolyte: set potential, pressure and concentrations to bulk values.
LiquidElectrolytes.AbstractSimulationResult
— Typeabstract type AbstractSimulationResult
Abstract supertype for simulation results.