Main Content

createPulses

Identify pulses and create pulse objects from experimental data

Description

example

createPulses(psObj) identifies the location of pulse events. Creates separate pulse objects from the Battery.PulseSequence object experimental data.

createPulses(psObj,Name,Value) identifies the location of pulse events. Creates separate pulse objects from the Battery.PulseSequence object experimental data with additional options specified by one or more Name,Value pair arguments.

Examples

collapse all

This example shows how to create pulse objects from data.

Create a pulse sequence object.

psObj = Battery.PulseSequence;
disp(psObj)

Load data from a file.

FileName = 'Synthetic_LiPo_PulseDischarge.mat';
[time,voltage,current] = Battery.loadDataFromMatFile(FileName);

Add the data to the pulse sequence.

addData(psObj,time,voltage,current);

Create pulse objects from data.

createPulses(psObj,...
    'CurrentOnThreshold',0.1,... 
    'NumRCBranches',3,... 
    'RCBranchesUse2TimeConstants',false,...
    'PreBufferSamples',10,... 
    'PostBufferSamples',15);

Input Arguments

collapse all

Battery.PulseSequence object for the pulse sequence that you want to analyze.

Name-Value Arguments

Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Before R2021a, use commas to separate each name and value, and enclose Name in quotes.

Example: createPulses(psObj,'CurrentOnThreshold',0.1)

Use this value to specify the minimum current magnitude for identifying the pulse locations, in A. The createPulses function considers values below the CurrentOnThrehsold as relaxation or measurement noise.

Example: createPulses(psObj,'CurrentOnThreshold',0.1)

Data Types: double

Use this value to specify the number of RC branches. To change the number of branches after an estimation, you must rerun createPulses along with any estimation steps. Rerunning ensures that the estimation parameters are the right size.

Example: createPulses(psObj,'NumRCBranches',4)

Data Types: uint32

The createPulses function does not support using separate time constants for load and relaxation when it estimates each RC branch. If you set the value to true, the createPulses function might produce an error.

Example: createPulses(psObj,'RCBranchesUse2TimeConstants',false)

Data Types: logical

Use this value to specify the number of data samples to retain before pulse estimation. The buffer allows the estimation to focus on matching the measured data before the pulse begins.

Example: createPulses(psObj,'PreBufferSamples',5)

Data Types: uint32

Use this value to specify the number of samples to retain before the next pulse estimation. The buffer allows the estimation to focus on matching the transition when the next pulse begins. Typically, the end transition of one pulse and the starting transition at the next pulse are at the same state of charge (SOC). Therefore, both transitions help determine the parameter values at that SOC breakpoint.

Example: createPulses(psObj,'PostBufferSamples',14)

Data Types: uint32

Use this value to specify that there must be two consecutive samples under current to define a pulse. Set to true if occasional noise spikes in the current measurement trigger a false pulse detection. By default, the value is false, indicating that a single sample above the threshold detects a pulse event.

Example: createPulses(psObj,'PulseRequires2Samples',true)

Data Types: logical

Version History

Introduced in R2016b