Summary of the invention
It is in view of the above problems or insufficient, when in order to solve state filter using data-driven model, secondary electricity
The problem of calculation amount of pool model is high, model accuracy is low and model over-fitting, the present invention provides one kind to be based on segmented line
The secondary cell model and method for estimating state of property interpolation.
A kind of secondary cell model based on piecewise linear interpolation, including state transition model and output model.
The concrete form of state transition model are as follows:
Wherein, k is sampled point ordinal number, and p, q are model order, ikThe battery current of sampled point k is represented,Represent sampled point
The battery theory dynamic electric voltage of k.au、buFormula it is as follows:
WhereinRepresent the battery SOC of sampled point k, Y1、…、YrWithFor auPiecewise linear interpolation node
Coordinate.R, m is auPiecewise linear interpolation order.V '=vY, k-u, w '=wY, k-u。vY, k-uIt representsIn section (- ∞, Y2)、
[Y2, Y3]、…、[Yr-1, ∞) in where section serial number, meetThe v in above-mentioned sectionY, k-uA section.wY, k-uGeneration
TableIn sectionThe serial number in middle place section meetsPositioned at upper
State w in sectionY, k-u+1A section.
Wherein, I1、…、IsWithFor buPiecewise linear interpolation node coordinate.S, n is buPiecewise linearity insert
It is worth order.V '=vI, k-u, w '=wI, k-u。vI, k-uRepresent ik-uIn section (- ∞, I2)、[I2, I3)、…、[Is-1, ∞) in where
The serial number in section, meets ik-uThe v in above-mentioned sectionI, k-uA section.wI, k-uIt representsIn section The serial number in middle place section meetsW in above-mentioned sectionI, k-u+1A section.
In above-mentioned formula, aU, v, w、bU, v, wFor piecewise linear interpolation nodal value, wherein for aU, v, w, index bound 1
≤u≤p,1≤v≤r,0≤w≤m;For bU, v, w, index bound is 0≤u≤q, 1≤v≤s, 0≤w≤n.
The concrete form of output model are as follows:
Wherein, yTerm, kRepresent the cell voltage of sampled point k, yOc, kRepresent the battery open circuit voltage of sampled point k, ∈kIt represents
The measurement noise of sampled point k.
The method for estimating state of secondary cell model based on piecewise linear interpolation, the specific steps are as follows:
Step S1, the secondary cell model based on piecewise linear interpolation is initialized, reinitialize prior state vector, priori
State error covariance matrix.
Step S2, cell voltage is measured, battery voltage measurement is obtained;According to battery voltage measurement, the elder generation of initialization
The prior state error co-variance matrix for testing state vector and initialization, to the secondary cell model based on piecewise linear interpolation,
Posteriority state vector, posteriority state error covariance matrix are obtained by EKF;
Then the expectation estimation of battery SOC, electricity are obtained by posteriority state vector and posteriority state error covariance matrix
The variance evaluation of the variance evaluation of pond SOC, the expectation estimation of capacity attenuation and capacity attenuation;
Step S3, the posteriority state vector that is obtained according to step S2, posteriority state error covariance matrix, are obtained by EKF
Prior state vector, prior state error co-variance matrix to next sampled point;
Step S4, circulation step S2-S3, by prior state vector, the prior state of the obtained next sampled point of step S3
Prior state of the error co-variance matrix as the prior state vector sum initialization of the initialization of step S2 in circulation next time
Error co-variance matrix is started the cycle over and is executed until the state estimation to secondary cell is completed.
Further, in step S1, by battery carry out working condition measurement, and Test Cycle test in battery current,
Cell voltage, time initialize the secondary electricity based on piecewise linear interpolation by Levenberg-Marquardt gradient descent method
Pool model.
Further, in step S1, the component of prior state vector has battery SOC, capacity attenuation and piecewise linear interpolation
Nodal value.
The present invention is obtained by the way that piecewise linear interpolation is applied to secondary cell model based on the secondary of piecewise linear interpolation
Battery model, and the secondary cell model based on piecewise linear interpolation is used in state filter, improve secondary cell state
The accuracy of estimation reduces the calculation amount and over-fitting of secondary cell state estimation.
Specific embodiment
In order to make the purpose of the present invention, technical solution and advantage are more clearly understood, below in conjunction with attached drawing and embodiment,
The present invention will be described in further detail.
As the method for estimating state of Fig. 1, the secondary cell model based on piecewise linear interpolation can be divided into following steps:
Step S1, the secondary cell model based on piecewise linear interpolation is initialized, reinitialize prior state vector, priori
State error covariance matrix.
Step S11, the secondary cell model based on piecewise linear interpolation is initialized.
Battery current, battery electricity in the present embodiment, by carrying out working condition measurement to battery, and in Test Cycle test
Pressure, time initialize the secondary cell mould based on piecewise linear interpolation by Levenberg-Marquardt gradient descent method
Type.
Firstly, carrying out open-circuit voltage test to battery, battery open circuit voltage function is obtained, the specific method is as follows:
First battery is full of, then starts to measure time, battery current, cell voltage.(such as with low current
It 0.1C) discharges battery, until voltage drops to low voltage threshold (such as 3V).Then battery is filled with low current
Electricity, until voltage rises to high voltage threshold (such as 4.2V).The battery SOC during this is estimated roughly by ampere-hour integral
Meter, formula are as follows:
Wherein, k is sampled point ordinal number, NdisFor the sampled point ordinal number at the end of electric discharge.tkRepresent the time of sampled point k, ik
The battery current of sampled point k is represented, charging is positive, and electric discharge is negative, CnFor rated capacity,Represent the battery SOC of sampled point k.
Battery SOC and cell voltage when gained is discharged and when charging are carried out when piecewise linear interpolation obtains electric discharge and are filled
Curve of the cell voltage relative to SOC when electric.By cell voltage when measured electric discharge and when charging relative to battery SOC
Curve takes average curve to get battery open circuit voltage function y is arrivedoc(z)。
Next the initial value y of measurement cell voltageTerm, 0, and battery SOC is back-calculated to obtain according to battery open circuit voltage function
Initial value, i.e.,Then, working condition measurement is carried out to battery, and the battery electricity in Test Cycle test
Stream, cell voltage, time, and by ampere-hour integrate to obtain the rough estimate of battery SOC in working condition measurement, formula is as follows:
Wherein CnFor amount of income constant volume before this.
Then, intend using piecewise linear interpolation nodal value as using Levenberg-Marquardt gradient descent method
The parameter of conjunction, approximating method and formula are as follows:
With C=[a1,1,0 … aP, r, m b0,1,0 … bQ, s, n]TAs fitting vector, N is total number of sample points, is fitted
The initial estimation C of vector0:
yk=yterm,k-yoc,k
T=max (p, q)+1
Then, fitting vector is estimated using Levenberg-marquardt gradient descent method:
Wherein when k > t,It is obtained by state transition model;When k≤t,V '=vY, k-u, w '=wY, k-u。
It enables∈=[∈1 … ∈N]T.Since l=0, iteration following equation:
Ifμ is then added 1 multiplied by 0.1, l, next step iteration is carried out, otherwise re-starts μ multiplied by 10
This step iteration.When l reaches the upper limit (such as 1000), orReach lower limit (such as 1 × 10-6) stop afterwards.If l+1=l when stoppingend, obtain
It arrivesPiecewise linear interpolation nodal value is finally obtained by each component of C.
Step S12, prior state vector, prior state error co-variance matrix are initialized.
In the present embodiment, the component of prior state vector has battery SOC, capacity attenuation and piecewise linear interpolation nodal value.
Firstly, measuring cell voltage, and the initial value of battery SOC is back-calculated to obtain by battery open circuit voltage functionHold
Measure the initial value of decayingTake 1.The initial value of piecewise linear interpolation nodal value takes gained piecewise linear interpolation node in step S11
Value.The initial value of the initial value of SOC, the initial value of capacity attenuation and piecewise linear interpolation nodal value is merged into vector, is obtained
The initial value of prior state vector
The initial value of prior state error co-variance matrix rule of thumb obtains.It is with specific reference to state initial estimation precision
And the requirement to state estimation initial convergence speed, it is obtained by experience and fine tuning.In the present embodiment, prior state error association
The initial value of variance matrix takes following value:
Wherein, diag indicates diagonal matrix.
Step S2, cell voltage is measured, battery voltage measurement is obtained;According to battery voltage measurement, the elder generation of initialization
The prior state error co-variance matrix for testing state vector and initialization, to the secondary cell model based on piecewise linear interpolation,
Posteriority state vector, posteriority state error covariance matrix are obtained by EKF;Then pass through posteriority state vector and posteriority state
Error co-variance matrix obtains the expectation estimation of battery SOC, the variance evaluation of battery SOC, the expectation estimation of capacity attenuation and appearance
Measure the variance evaluation of decaying.
Step S21, cell voltage is measured, battery voltage measurement is obtained;According to battery voltage measurement, the elder generation of initialization
The prior state error co-variance matrix for testing state vector and initialization, to the secondary cell model based on piecewise linear interpolation,
Posteriority state vector, posteriority state error covariance matrix are obtained by EKF.
Cell voltage is measured first, obtains battery voltage measurement.Then, according to the prior state vector sum base of initialization
Cell voltage discreet value is obtained in the secondary cell model of piecewise linear interpolation.The prior state vector of known initializationIt willValue as zk、
aU, v, w、bU, v, wIt brings into the secondary cell model based on piecewise linear interpolation, and enables measurement noise ∈k=0, calculate cell voltage
yTerm, k, obtain cell voltage discreet value
State transition model calculates v by dichotomizing search when calculatingY, k-u、wY, k-u、vI, k-u、wI, k-u, can reduce
Formula calculates required calculation amount, to achieve the purpose that the calculation amount for reducing secondary cell model.
Then, according to battery voltage measurement, cell voltage discreet value, initialization prior state vector, initialization
Prior state error co-variance matrix, to the secondary cell model based on piecewise linear interpolation, by EKF obtain posteriority state to
AmountPosteriority state error covariance matrix
Wherein ∑∈To measure noise ∈kVariance, determined according to model accuracy and measurement accuracy, take 1 in the present embodiment ×
10-3。
Step S22, estimated by the expectation that posteriority state vector and posteriority state error covariance matrix obtain battery SOC
Meter, the variance evaluation of battery SOC, the expectation estimation of capacity attenuation and capacity attenuation variance evaluation.
Posteriority state vectorIn,For battery SOC
Expectation estimation,For the expectation estimation of capacity attenuation.Posteriority state error covariance matrix
In,For the variance evaluation of battery SOC,For the variance evaluation of capacity attenuation.By rated capacity CnDivided byCapacity after cell decay can be obtained.
Step S3, the posteriority state vector that is obtained according to step S2, posteriority state error covariance matrix, are obtained by EKF
Prior state vector, prior state error co-variance matrix to next sampled point.
Wherein,It is state-noise covariance matrix, is determined according to model accuracy, is taken in the present embodiment
Step S4, circulation step S2-S3, by prior state vector, the prior state of the obtained next sampled point of step S3
Prior state of the error co-variance matrix as the prior state vector sum initialization of the initialization of step S2 in circulation next time
Error co-variance matrix is started the cycle over and is executed until the state estimation to secondary cell is completed.
Fig. 2 shows model of the present invention improves the accuracy of cell voltage discreet value, so as to finally improve electricity
The accuracy of pond state estimation.
Fig. 3 is shown, and model of the present invention and method improve the accuracy of the expectation estimation of battery SOC.
Fig. 4 is shown, and institute's representation model of the present invention and method reduce the calculation amount that battery status is estimated.
Fig. 5 is shown, model of the present invention in battery status estimation procedure, the variation of the model other than operating point compared with
It is small, illustrate that model of the present invention can reduce the over-fitting of model in battery status estimation procedure, so as to final
Improve the accuracy of battery status estimation.