SoC estimation using the equation in attached image

9 visualizaciones (últimos 30 días)
Mustafa Ahmed
Mustafa Ahmed el 30 de Mayo de 2021
Comentada: Mustafa Ahmed el 7 de Ag. de 2021
Hi ,I have done this code in order to estimate the battery state of chaege (SoC) by using nasa data-set for battery charging and discharging , the data-sets are taking from this website https://ti.arc.nasa.gov/tech/dash/groups/pcoe/prognostic-data-repository/, part no 5 (Battery Data Set) BatteryAgingARC_53_54_55_56
in specific file named B0056.mat
sorry i could not upload it here due to the size of the file
my code as below
clc
clear all
A=load('B0056.mat');
load('B0056.mat');
for i=1:252
Type=B0056.cycle(i).type;
if strcmp(Type,'discharge')==1
Voltage_measured=B0056.cycle(i).data.Voltage_measured;
Current_measured=B0056.cycle(i).data.Current_measured;
Temperature_measured=B0056.cycle(i).data.Temperature_measured;
% Current_charge=B0056.cycle(i).data.Current_load;
% Voltage_charge=B0056.cycle(i).data.Voltage_load;
Current_charge=B0056.cycle(i).data.Current_charge;
Voltage_charge=B0056.cycle(i).data.Voltage_charge;
Time=B0056.cycle(i).data.Time/3600;
Capacity=B0056.cycle(i).data.Capacity;
for j=1:length(Current_charge)
if (j == 1)
SOC0 = 0;
else
State =(SOC0 -(-(Current_charge(j)*(Time(j)-Time(j-1)))./Capacity)*100);
end
end
end
end
SOC=State;
A=[ Voltage_measured', Current_measured',Temperature_measured',Current_charge',Voltage_charge',Time'];
A(1:end,end+1)=SOC;
a=strcat('B0006.cycle(', num2str(i),').charge.xlsx');
xlswrite(a,A);
data = readtable('B0006.cycle(252).charge.xlsx'); % read Excel file as table
data.Properties.VariableNames = {'Voltage Measured','Current Measured','Temp Measured','Current Charge','Voltage Charge','Time','SoC'}
writetable(data,'B0006.cycle(252).charge.xlsx') % write back modified data to excel file
[num,txt,raw] = xlsread('B0006.cycle(252).charge.xlsx');
[v,T,vT]=xlsread('B0006.cycle(252).charge.xlsx');
t=v(:,6);y=v(:,7);
plot(t,y)
xlabel('time')
ylabel('soc')
it does not show error but it does not show the required results as SoC during discharge should decrease from 100 to some points
I also want to get the recharge cycle when SOC=0 but it shows error in SOC=State;
please help me with that
note: the attach image is for the equation of SOC estimation
  1 comentario
NAMRATA MOHANTY
NAMRATA MOHANTY el 16 de Jul. de 2021
Hello Sir. I need your help in understanding SOC estimation concept.

Iniciar sesión para comentar.

Respuestas (1)

Joel Van Sickel
Joel Van Sickel el 3 de Ag. de 2021
Hello Mustafa,
the link to your data set does not work and you did not include the relevant .mat file so it would be particularly hard for anyone to help answer this question.
However, here: State =(SOC0 -(-(Current_charge(j)*(Time(j)-Time(j-1)))./Capacity)*100);
you are not correctly implementing the equation for an integral so this is probably at least part of the problem. Please see: https://www.mathworks.com/help/matlab/ref/integral.html
Regards,
Joel
  1 comentario
Mustafa Ahmed
Mustafa Ahmed el 7 de Ag. de 2021
thank you sir for your reply
please share your email for more contact details
or contact me via
mufasa.moose@gmail.com

Iniciar sesión para comentar.

Categorías

Más información sobre Propulsion and Power Systems en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by