First time here? Check out the Help page!

Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
2

E+ and Matlab Error [closed]

asked 2 years ago

Zakaria's avatar

updated 1 year ago

Hi everyone!,

I am trying to performe a co-simulation between E+ and Matlab using the "EnergyPlus Co-simulation Toolbox" and I tried to an output and the error bellow appears.

Error using table (line 335) 'EP_ZONE__Refrigeration_Air_Chiller_System_Total_Compressor_Electric_Energy' is longer than the maximum allowed length for a table variable name.

How can I solve this problem ?

Or is there any way to give a short name to the output?

Preview: (hide)

Closed for the following reason the question is answered, right answer was accepted by Zakaria
close date 2024-01-09 07:29:23.428148

1 Answer

Sort by » oldest newest most voted
1

answered 1 year ago

Zakaria's avatar

The mlepMatlab script utilizes the following code to define the variable name using the format EP_ZoneName_VariableNameUsedByEnergyPlus. Instead of using [{'Time'}; ep.outputSigName] as shown in the code below, I replaced it with [{'Time'}; {'VariableName1'};{'VariableName2'};...;{'VariableNameN'}]

Original code :

logTable = table('Size',[0, 1 + ep.nOut],...
'VariableTypes',repmat({'double'},1,1 + ep.nOut),...
'VariableNames',[{'Time'}; ep.outputSigName]);

Modified code :

logTable = table('Size',[0, 1 + ep.nOut],...
'VariableTypes',repmat({'double'},1,1 + ep.nOut),...
'VariableNames',[{'Time'}; {'VariableName1'};{'VariableName2'};...;{'VariableNameN'}];
Preview: (hide)
link

Training Workshops

Careers

Question Tools

1 follower

Stats

Asked: 2 years ago

Seen: 135 times

Last updated: Aug 24 '23