Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified bin/EP-Launch/EP-Launch.exe
Binary file not shown.
377 changes: 188 additions & 189 deletions src/EP-Launch/epl-ui.frm

Large diffs are not rendered by default.

13 changes: 7 additions & 6 deletions src/EP-Launch/epl.vbp
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
Type=Exe
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#..\..\..\..\..\..\..\Windows\SysWOW64\stdole2.tlb#OLE Automation
Object={F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0; ComDlg32.OCX
Object={C0A63B80-4B21-11D3-BD95-D426EF2C7949}#1.0#0; Vsflex7L.ocx
Object={831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.1#0; MSCOMCTL.OCX
Object={86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0; MSCOMCT2.OCX
Reference=*\G{C0A63B80-4B21-11D3-BD95-D426EF2C7949}#1.0#0#..\..\..\..\..\..\..\WINDOWS\SysWow64\Vsflex7L.ocx#ComponentOne VSFlexGrid 7.1 (Light)
Object={38911DA0-E448-11D0-84A3-00DD01104159}#1.1#0; COMCT332.OCX
Object={48E59290-9880-11CF-9754-00AA00C00908}#1.0#0; MSINET.OCX
Form=epl-ui.frm
Expand All @@ -14,6 +11,10 @@ Form=frmRunStatus.frm
Form=frmOptions.frm
Form=frmDefineViewResults.frm
Module=MainModule; MainModule.bas
Object={831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.1#0; MSCOMCTL.OCX
Object={86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0; MSCOMCT2.OCX
Object={C0A63B80-4B21-11D3-BD95-D426EF2C7949}#1.0#0; Vsflex7L.ocx
Object={F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0; ComDlg32.OCX
IconForm="eplUI"
Startup="eplUI"
HelpFile=""
Expand All @@ -25,10 +26,10 @@ HelpContextID="0"
CompatibleMode="0"
MajorVer=2
MinorVer=1
RevisionVer=6
RevisionVer=7
AutoIncrementVer=0
ServerSupportFiles=0
VersionComments="2.16"
VersionComments="2.17"
VersionCompanyName="GARD Analytics, Inc."
VersionLegalCopyright="Copyright 2000-2025 by GARD Analytics Inc. subject to approval."
VersionProductName="EPLaunch"
Expand Down
4 changes: 2 additions & 2 deletions src/EP-Launch/epl.vbw
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
eplUI = 366, 25, 1710, 945, , 130, 130, 1680, 1033, C
frmAbout = 234, 234, 1784, 1137, C, 208, 208, 1758, 1111, C
crashMessage = 182, 262, 1313, 1182, , 26, 26, 927, 946, C
frmAbout = 327, 84, 1877, 987, C, 208, 208, 1758, 1111, C
crashMessage = 809, 145, 1940, 1065, , 26, 26, 927, 946, C
frmNewQueue = 124, 453, 1674, 1356, , 416, 416, 1966, 1319, C
frmRunStatus = 0, 0, 0, 0, C, 442, 442, 1992, 1345, C
frmOptions = 0, 0, 0, 0, C, 0, 0, 1550, 903, C
Expand Down
2 changes: 1 addition & 1 deletion src/EP-Launch/frmAbout.frm
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ Begin VB.Form frmAbout
Width = 3855
End
Begin VB.Label lblTitle
Caption = "EP-Launch - Version 2.16"
Caption = "EP-Launch - Version 2.17"
BeginProperty Font
Name = "MS Sans Serif"
Size = 12
Expand Down
16 changes: 16 additions & 0 deletions src/EnergyPlus/BranchInputManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,22 @@ namespace BranchInputManager {
}
}

void ManageConnectorInput(EnergyPlusData &state)
{
bool hasSplitterOrMixer(false);
if (state.dataBranchInputManager->GetSplitterInputFlag) {
hasSplitterOrMixer = true;
GetSplitterInput(state);
}
if (state.dataBranchInputManager->GetMixerInputFlag) {
hasSplitterOrMixer = true;
GetMixerInput(state);
}
if (hasSplitterOrMixer && state.dataBranchInputManager->GetConnectorListInputFlag) {
GetConnectorListInput(state);
}
}

//==================================================================================
// Routines that "get" data from internal branch management structure
//==================================================================================
Expand Down
1 change: 1 addition & 0 deletions src/EnergyPlus/BranchInputManager.hh
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ namespace BranchInputManager {

// Functions
void ManageBranchInput(EnergyPlusData &state);
void ManageConnectorInput(EnergyPlusData &state);

//==================================================================================
// Routines that "get" data from internal branch management structure
Expand Down
4 changes: 2 additions & 2 deletions src/EnergyPlus/HeatBalanceAirManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -578,14 +578,14 @@ void GetSimpleAirModelInputs(EnergyPlusData &state, bool &ErrorsFound) // IF err
Constant::Units::m3_s,
state.dataHeatBal->ZnAirRpt(thisZoneAirBalance.ZonePtr).OABalanceVdotCurDensity,
OutputProcessor::TimeStepType::System,
OutputProcessor::StoreType::Sum,
OutputProcessor::StoreType::Average,
state.dataHeatBal->Zone(thisZoneAirBalance.ZonePtr).Name);
SetupOutputVariable(state,
"Zone Combined Outdoor Air Standard Density Volume Flow Rate",
Constant::Units::m3_s,
state.dataHeatBal->ZnAirRpt(thisZoneAirBalance.ZonePtr).OABalanceVdotStdDensity,
OutputProcessor::TimeStepType::System,
OutputProcessor::StoreType::Sum,
OutputProcessor::StoreType::Average,
state.dataHeatBal->Zone(thisZoneAirBalance.ZonePtr).Name);
SetupOutputVariable(state,
"Zone Combined Outdoor Air Current Density Volume",
Expand Down
22 changes: 16 additions & 6 deletions src/EnergyPlus/HeatBalanceManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3757,18 +3757,28 @@ namespace HeatBalanceManager {
}

Label10:;
for (LineNum = 2; LineNum <= 5; ++LineNum) {
NextLine = W5DataFile.readLine();
if (NextLine.eof) {
goto Label1000;
}
++FileLineCount;
if (!has_prefixi(NextLine.data, "WINDOW NAME")) {
// Berkeley Lab WINDOW 7 has been found to include extra blank lines after the "WINDOW5" line
// so find the line that begins with "WINDOW NAME"
goto Label10;
} else {
// Get window name
W5Name = std::string{NextLine.data.substr(19)};
WindowNameInW5DataFile = Util::makeUPPER(W5Name);

// Get description (currently not used)
NextLine = W5DataFile.readLine();
if (NextLine.eof) {
goto Label1000;
}
DataLine(LineNum) = NextLine.data;
++FileLineCount;
}

// Get window name and check for match
W5Name = std::string{DataLine(4).substr(19)};
WindowNameInW5DataFile = Util::makeUPPER(W5Name);
// Check for window name match
if (DesiredConstructionName != WindowNameInW5DataFile) {
// Doesn't match; read through file until next window entry is found
Label20:;
Expand Down
1 change: 1 addition & 0 deletions src/EnergyPlus/SimulationManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,7 @@ namespace SimulationManager {
isInputObjectUsed(state);

BranchInputManager::ManageBranchInput(state); // just gets input and returns.
BranchInputManager::ManageConnectorInput(state); // just gets input and returns.

// Create a new plugin manager which starts up the Python interpreter
state.dataPluginManager->pluginManager = std::make_unique<EnergyPlus::PluginManagement::PluginManager>(state);
Expand Down
132 changes: 132 additions & 0 deletions tst/EnergyPlus/unit/BranchInputManager.unit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
// EnergyPlus Headers
#include <EnergyPlus/BranchInputManager.hh>
#include <EnergyPlus/Data/EnergyPlusData.hh>
#include <EnergyPlus/DataErrorTracking.hh>
#include <EnergyPlus/DataSizing.hh>
#include <EnergyPlus/InputProcessing/InputProcessor.hh>

Expand Down Expand Up @@ -502,4 +503,135 @@ TEST_F(EnergyPlusFixture, BranchInputManager_GetAirBranchIndex)
EXPECT_EQ(0, BranchIndex);
}

TEST_F(EnergyPlusFixture, BranchInputManager_OrphanObjects)
{
// Branch
state->dataBranchInputManager->clear_state();
state->dataErrTracking->TotalSevereErrors = 0;
std::string idf_objects = delimited_string({
"Branch,",
" Heating Supply Main Branch, !- Name",
" , !- Pressure Drop Curve Name",
" Coil:Heating:Water, !- Component 1 Object Type",
" Heating Supply Reheat Coil, !- Component 1 Name",
" Heating Supply Inlet Node, !- Component 1 Inlet Node Name",
" Heating Supply Outlet Node; !- Component 1 Outlet Node Name",
});
ASSERT_TRUE(process_idf(idf_objects));
EXPECT_NO_THROW(ManageBranchInput(*state));

std::string expected_error = delimited_string({
" ** Severe ** During Branch Input, Invalid Component Name input=HEATING SUPPLY REHEAT COIL",
" ** ~~~ ** Component type=COIL:HEATING:WATER",
" ** ~~~ ** Occurs on Branch=HEATING SUPPLY MAIN BRANCH",
" ** Severe ** AuditBranches: There are 1 branch(es) that do not appear on any BranchList.",
" ** ~~~ ** Use Output:Diagnostics,DisplayExtraWarnings; for detail of each branch not on a branch list.",
});
compare_err_stream(expected_error, true);

// BranchList
state->dataBranchInputManager->clear_state();
state->dataErrTracking->TotalSevereErrors = 0;
idf_objects = delimited_string({
"BranchList,",
" Heating Supply Branches, !- Name",
" Heating Supply Main Branch; !- Branch 1 Name",
});
ASSERT_TRUE(process_idf(idf_objects));
EXPECT_NO_THROW(ManageBranchInput(*state));

expected_error = delimited_string({
" ** Severe ** GetBranchListInput: BranchList=\"HEATING SUPPLY BRANCHES\", invalid data.",
" ** ~~~ ** ..invalid Branch Name not found=\"HEATING SUPPLY MAIN BRANCH\".",
" ** Severe ** GetBranchListInput: Invalid Input -- preceding condition(s) will likely cause termination.",
});
compare_err_stream(expected_error, true);

// Splitter
state->dataBranchInputManager->clear_state();
state->dataErrTracking->TotalSevereErrors = 0;
idf_objects = delimited_string({
"Connector:Splitter,",
" Heating Supply Splitter, !- Name",
" Heating Supply Inlet Branch, !- Inlet Branch Name",
" Central Boiler Branch, !- Outlet Branch 1 Name",
" Heating Supply Bypass Branch; !- Outlet Branch 2 Name",
});
ASSERT_TRUE(process_idf(idf_objects));
EXPECT_THROW(ManageConnectorInput(*state), EnergyPlus::FatalError);

expected_error = delimited_string({
" ** Severe ** GetSplitterInput: Invalid Branch=HEATING SUPPLY INLET BRANCH, referenced as Inlet Branch to Connector:Splitter=HEATING "
"SUPPLY SPLITTER",
" ** Severe ** GetSplitterInput: Invalid Branch=CENTRAL BOILER BRANCH, referenced as Outlet Branch # 1 to Connector:Splitter=HEATING "
"SUPPLY SPLITTER",
" ** Severe ** GetSplitterInput: Invalid Branch=HEATING SUPPLY BYPASS BRANCH, referenced as Outlet Branch # 2 to "
"Connector:Splitter=HEATING SUPPLY SPLITTER",
" ** Fatal ** GetSplitterInput: Fatal Errors Found in Connector:Splitter, program terminates.",
" ...Summary of Errors that led to program termination:",
" ..... Reference severe error count=3",
" ..... Last severe error=GetSplitterInput: Invalid Branch=HEATING SUPPLY BYPASS BRANCH, referenced as Outlet Branch # 2 to "
"Connector:Splitter=HEATING SUPPLY SPLITTER",
});
compare_err_stream(expected_error, true);

// Mixer
state->dataBranchInputManager->clear_state();
state->dataErrTracking->TotalSevereErrors = 0;
idf_objects = delimited_string({
"Connector:Mixer,",
" Heating Supply Mixer, !- Name",
" Heating Supply Outlet Branch, !- Outlet Branch Name",
" Central Boiler Branch, !- Inlet Branch 1 Name",
" Heating Supply Bypass Branch; !- Inlet Branch 2 Name",
});
ASSERT_TRUE(process_idf(idf_objects));
EXPECT_THROW(ManageConnectorInput(*state), EnergyPlus::FatalError);

expected_error = delimited_string({
" ** Severe ** GetMixerInput: Invalid Branch=HEATING SUPPLY OUTLET BRANCH, referenced as Outlet Branch in Connector:Mixer=HEATING SUPPLY "
"MIXER",
" ** Severe ** GetMixerInput: Invalid Branch=CENTRAL BOILER BRANCH, referenced as Inlet Branch # 1 in Connector:Mixer=HEATING SUPPLY "
"MIXER",
" ** Severe ** GetMixerInput: Invalid Branch=HEATING SUPPLY BYPASS BRANCH, referenced as Inlet Branch # 2 in Connector:Mixer=HEATING "
"SUPPLY MIXER",
" ** Fatal ** GetMixerInput: Fatal Errors Found in Connector:Mixer, program terminates.",
" ...Summary of Errors that led to program termination:",
" ..... Reference severe error count=3",
" ..... Last severe error=GetMixerInput: Invalid Branch=HEATING SUPPLY BYPASS BRANCH, referenced as Inlet Branch # 2 in "
"Connector:Mixer=HEATING SUPPLY MIXER",
});
compare_err_stream(expected_error, true);

// ConnectorList
state->dataBranchInputManager->clear_state();
state->dataErrTracking->TotalSevereErrors = 0;
idf_objects = delimited_string({
"ConnectorList,",
" Heating Supply Side Connectors, !- Name",
" Connector:Splitter, !- Connector 1 Object Type",
" Heating Supply Splitter, !- Connector 1 Name",
" Connector:Mixer, !- Connector 2 Object Type",
" Heating Supply Mixer; !- Connector 2 Name",
});
ASSERT_TRUE(process_idf(idf_objects));
EXPECT_THROW(ManageConnectorInput(*state), EnergyPlus::FatalError);

expected_error = delimited_string({
" ** Severe ** Invalid Connector:Splitter(none)=HEATING SUPPLY SPLITTER, referenced by ConnectorList=HEATING SUPPLY SIDE CONNECTORS",
" ** Severe ** Invalid Connector:Mixer(none)=HEATING SUPPLY MIXER, referenced by ConnectorList=HEATING SUPPLY SIDE CONNECTORS",
" ** Severe ** For ConnectorList=HEATING SUPPLY SIDE CONNECTORS",
" ** ~~~ ** ...Item=HEATING SUPPLY SPLITTER, Type=CONNECTOR:SPLITTER was not matched.",
" ** ~~~ ** The BranchList for this Connector:Splitter does not match the BranchList for its corresponding Connector:Mixer.",
" ** Severe ** For ConnectorList=HEATING SUPPLY SIDE CONNECTORS",
" ** ~~~ ** ...Item=HEATING SUPPLY MIXER, Type=CONNECTOR:MIXER was not matched.",
" ** ~~~ ** The BranchList for this Connector:Mixer does not match the BranchList for its corresponding Connector:Splitter.",
" ** Fatal ** GetConnectorListInput: Program terminates for preceding conditions.",
" ...Summary of Errors that led to program termination:",
" ..... Reference severe error count=4",
" ..... Last severe error=For ConnectorList=HEATING SUPPLY SIDE CONNECTORS",
});
compare_err_stream(expected_error, true);
}

} // namespace EnergyPlus
17 changes: 17 additions & 0 deletions tst/EnergyPlus/unit/HeatBalanceManager.unit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2316,6 +2316,23 @@ TEST_F(EnergyPlusFixture, Window5DataFileSpaceInName)
EXPECT_TRUE(ConstructionFound);
}

TEST_F(EnergyPlusFixture, Window5DataExtraBlankLines)
{

fs::path window5DataFilePath;
window5DataFilePath = configured_source_directory() / "tst/EnergyPlus/unit/Resources/Window5DataFile_ExtraBlankLines.dat";
std::string ConstructName{"EXAMPLE B"};
bool ConstructionFound{false};
bool EOFonW5File{false};
bool ErrorsFound{false};
state->dataHeatBal->MaxSolidWinLayers = 2;

SearchWindow5DataFile(*state, window5DataFilePath, ConstructName, ConstructionFound, EOFonW5File, ErrorsFound);

EXPECT_EQ(ConstructName, "EXAMPLE B");
EXPECT_TRUE(ConstructionFound);
}

TEST_F(EnergyPlusFixture, Window5DataFileZeroSCSHGC)
{

Expand Down
Loading
Loading