
I was trying to solve look up table for the dat below, but i am getting an error message, so what shall i do?
조회 수: 1 (최근 30일)
이전 댓글 표시

the error is like this

And the command warining

댓글 수: 0
답변 (1개)
Gayathri
2025년 2월 4일
The issue arises because the "Table data" and "Breakpoints" are in table format as shown in the screenshot attached. This is due to the way in which the excel file has been loaded to read the "OCV" and "SOC" columns.
We need to make sure that "Table data" and "Breakpoints" are arrays of size 1xN for a "1-D Lookup Table". This can be achieved by loading the excel file using the "readtable" function as shown below.
% Specify the file name or path
filename = 'battery_exp.xlsx';
% Read the Excel file into a table
dataTable = readtable(filename);
SOC=(dataTable.SOC)'
OCV=(dataTable.OCV)'
And now if you pass the "SOC" and "OCV" to the "Lookup Table", then the "Block Parameters" tab will be be as shown below. The error will be resolved using this approach.

For more information on the "readtable" function, please refer to the below documentation link.
Hope you find this information helpful!
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Nonlinearity에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!