diff --git a/bin/EP-Launch/EP-Launch.exe b/bin/EP-Launch/EP-Launch.exe index 36aee871aed..39551e04173 100644 Binary files a/bin/EP-Launch/EP-Launch.exe and b/bin/EP-Launch/EP-Launch.exe differ diff --git a/src/EP-Launch/epl-ui.frm b/src/EP-Launch/epl-ui.frm index 15bf3e8d392..82aa3bad7f4 100644 --- a/src/EP-Launch/epl-ui.frm +++ b/src/EP-Launch/epl-ui.frm @@ -1,7 +1,7 @@ VERSION 5.00 -Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "ComDlg32.OCX" -Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.1#0"; "MSCOMCTL.OCX" Object = "{48E59290-9880-11CF-9754-00AA00C00908}#1.0#0"; "MSINET.OCX" +Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.1#0"; "MSCOMCTL.OCX" +Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "ComDlg32.OCX" Begin VB.Form eplUI BorderStyle = 1 'Fixed Single Caption = "EP-Launch" @@ -15,6 +15,168 @@ Begin VB.Form eplUI ScaleHeight = 7455 ScaleWidth = 8835 StartUpPosition = 1 'CenterOwner + Begin VB.Frame frameUtility + BorderStyle = 0 'None + Caption = "Frame1" + Height = 6255 + Left = 240 + TabIndex = 28 + Top = 480 + Width = 8295 + Begin VB.CommandButton cmdUtilityOutput6 + Caption = "Open 6" + Height = 375 + Left = 3960 + TabIndex = 104 + Top = 4680 + Width = 1785 + End + Begin VB.CommandButton cmdUtilityOutput5 + Caption = "Open 5" + Height = 375 + Left = 2040 + TabIndex = 103 + Top = 4680 + Width = 1785 + End + Begin VB.CommandButton cmdUtilityOutput4 + Caption = "Open 4" + Height = 375 + Left = 120 + TabIndex = 102 + Top = 4680 + Width = 1785 + End + Begin VB.CommandButton cmdUtilityOutput3 + Caption = "Open 3" + Height = 375 + Left = 3960 + TabIndex = 44 + Top = 4200 + Width = 1785 + End + Begin VB.CommandButton cmdUtilityOutput2 + Caption = "Open 2" + Height = 375 + Left = 2040 + TabIndex = 43 + Top = 4200 + Width = 1785 + End + Begin VB.ComboBox cmbUtility + Height = 315 + Left = 600 + Style = 2 'Dropdown List + TabIndex = 42 + Top = 120 + Width = 1815 + End + Begin VB.Frame frameUtilityWeather + Caption = "Weather File" + Height = 1215 + Left = 120 + TabIndex = 36 + Top = 2880 + Width = 8175 + Begin VB.CommandButton cmdUtilityWeatherBrowse + Caption = "Browse.." + Height = 375 + Left = 240 + TabIndex = 37 + Top = 720 + Width = 1215 + End + Begin VB.Label lblUtilityWeatherFile + Caption = "\" + Height = 495 + Left = 120 + TabIndex = 38 + Top = 240 + Width = 7935 + End + End + Begin VB.Frame frameUtilityInput + Caption = "Input File" + Height = 1215 + Left = 120 + TabIndex = 33 + Top = 1560 + Width = 8175 + Begin VB.CommandButton cmdUtilityIDFEdit + Caption = "Edit - IDF Editor" + Height = 375 + Left = 6720 + TabIndex = 41 + Top = 720 + Width = 1335 + End + Begin VB.CommandButton cmdUtilityTextEdit + Caption = "Edit - Text Editor" + Height = 375 + Left = 5280 + TabIndex = 40 + Top = 720 + Width = 1335 + End + Begin VB.CommandButton cmdUtilityInputBrowse + Caption = "Browse.." + Height = 375 + Left = 240 + TabIndex = 34 + Top = 720 + Width = 1215 + End + Begin VB.Label lblUtilityInputFile + Caption = "\" + Height = 495 + Left = 120 + TabIndex = 35 + Top = 240 + Width = 7935 + End + End + Begin VB.Frame frameUtilityAbout + Caption = "About" + Height = 975 + Left = 120 + TabIndex = 32 + Top = 480 + Width = 8175 + Begin VB.Label lblUtilityAbout + Caption = "lt" + Height = 615 + Left = 120 + TabIndex = 39 + Top = 240 + Width = 7935 + WordWrap = -1 'True + End + End + Begin VB.CommandButton cmdUtilityOutput1 + Caption = "Open 1" + Height = 375 + Left = 120 + TabIndex = 31 + Top = 4200 + Width = 1785 + End + Begin VB.CommandButton cmdUtilityRun + Caption = "Run Utility" + Height = 375 + Left = 6000 + TabIndex = 30 + Top = 4200 + Width = 2175 + End + Begin VB.Label Label2 + Caption = "Utility" + Height = 255 + Left = 120 + TabIndex = 45 + Top = 160 + Width = 495 + End + End Begin VB.Frame frameSingle BorderStyle = 0 'None Caption = "frameSingle" @@ -850,168 +1012,6 @@ Begin VB.Form eplUI EndProperty EndProperty End - Begin VB.Frame frameUtility - BorderStyle = 0 'None - Caption = "Frame1" - Height = 6255 - Left = 240 - TabIndex = 28 - Top = 480 - Width = 8295 - Begin VB.CommandButton cmdUtilityOutput6 - Caption = "Open 6" - Height = 375 - Left = 3960 - TabIndex = 104 - Top = 4680 - Width = 1785 - End - Begin VB.CommandButton cmdUtilityOutput5 - Caption = "Open 5" - Height = 375 - Left = 2040 - TabIndex = 103 - Top = 4680 - Width = 1785 - End - Begin VB.CommandButton cmdUtilityOutput4 - Caption = "Open 4" - Height = 375 - Left = 120 - TabIndex = 102 - Top = 4680 - Width = 1785 - End - Begin VB.CommandButton cmdUtilityOutput3 - Caption = "Open 3" - Height = 375 - Left = 3960 - TabIndex = 44 - Top = 4200 - Width = 1785 - End - Begin VB.CommandButton cmdUtilityOutput2 - Caption = "Open 2" - Height = 375 - Left = 2040 - TabIndex = 43 - Top = 4200 - Width = 1785 - End - Begin VB.ComboBox cmbUtility - Height = 315 - Left = 600 - Style = 2 'Dropdown List - TabIndex = 42 - Top = 120 - Width = 1815 - End - Begin VB.Frame frameUtilityWeather - Caption = "Weather File" - Height = 1215 - Left = 120 - TabIndex = 36 - Top = 2880 - Width = 8175 - Begin VB.CommandButton cmdUtilityWeatherBrowse - Caption = "Browse.." - Height = 375 - Left = 240 - TabIndex = 37 - Top = 720 - Width = 1215 - End - Begin VB.Label lblUtilityWeatherFile - Caption = "\" - Height = 495 - Left = 120 - TabIndex = 38 - Top = 240 - Width = 7935 - End - End - Begin VB.Frame frameUtilityInput - Caption = "Input File" - Height = 1215 - Left = 120 - TabIndex = 33 - Top = 1560 - Width = 8175 - Begin VB.CommandButton cmdUtilityIDFEdit - Caption = "Edit - IDF Editor" - Height = 375 - Left = 6720 - TabIndex = 41 - Top = 720 - Width = 1335 - End - Begin VB.CommandButton cmdUtilityTextEdit - Caption = "Edit - Text Editor" - Height = 375 - Left = 5280 - TabIndex = 40 - Top = 720 - Width = 1335 - End - Begin VB.CommandButton cmdUtilityInputBrowse - Caption = "Browse.." - Height = 375 - Left = 240 - TabIndex = 34 - Top = 720 - Width = 1215 - End - Begin VB.Label lblUtilityInputFile - Caption = "\" - Height = 495 - Left = 120 - TabIndex = 35 - Top = 240 - Width = 7935 - End - End - Begin VB.Frame frameUtilityAbout - Caption = "About" - Height = 975 - Left = 120 - TabIndex = 32 - Top = 480 - Width = 8175 - Begin VB.Label lblUtilityAbout - Caption = "lt" - Height = 615 - Left = 120 - TabIndex = 39 - Top = 240 - Width = 7935 - WordWrap = -1 'True - End - End - Begin VB.CommandButton cmdUtilityOutput1 - Caption = "Open 1" - Height = 375 - Left = 120 - TabIndex = 31 - Top = 4200 - Width = 1785 - End - Begin VB.CommandButton cmdUtilityRun - Caption = "Run Utility" - Height = 375 - Left = 6000 - TabIndex = 30 - Top = 4200 - Width = 2175 - End - Begin VB.Label Label2 - Caption = "Utility" - Height = 255 - Left = 120 - TabIndex = 45 - Top = 160 - Width = 495 - End - End Begin VB.Label lblCheckingUpdates Caption = "Checking for Updates" ForeColor = &H80000011& @@ -1485,7 +1485,7 @@ Private Type utilProgType includeExtensionInCall As Boolean 'if the extension should be included when the file is passed to the application waitUntilUtilityExits As Boolean 'true if EP-Launch should wait until the called program is done End Type -Const numUtilProg = 10 +Const numUtilProg = 9 Dim utilProg(numUtilProg) As utilProgType Private Type SimQueueType @@ -6098,7 +6098,7 @@ utilProg(7).outExt3Alt = "-GAVGTable.htm" utilProg(7).outExt4 = "-AppGErr.txt" utilProg(7).outExt5 = "" utilProg(7).outExt6 = "" -utilProg(7).applicationFile = "PostProcess\AppGPostProcess\appgpostprocess.exe" +utilProg(7).applicationFile = "PostProcess\AppGPostProcess.exe" utilProg(7).appIsSpreadsheet = False utilProg(7).batchFile = "" utilProg(7).useInputAsExeArgument = True @@ -6149,32 +6149,31 @@ utilProg(9).useInputAsExeArgument = False utilProg(9).fileSuffix = "" utilProg(9).includeExtensionInCall = False utilProg(9).waitUntilUtilityExits = False -' -utilProg(10).name = "EP-Compare" -utilProg(10).about = "Graphs the values from the tabular report for multiple simulations side by side." -utilProg(10).enableInput = False -utilProg(10).enableWthr = False -utilProg(10).enableInTextEdit = True -utilProg(10).IDFEdOpt = "" -utilProg(10).inExt = "" -utilProg(10).outExt1 = "" -utilProg(10).outExt2 = "" -utilProg(10).outExt3 = "" -utilProg(10).outExt4 = "" -utilProg(10).outExt5 = "" -utilProg(10).outExt6 = "" -utilProg(10).applicationFile = "PostProcess\EP-Compare\EP-Compare.exe" -utilProg(10).appIsSpreadsheet = False -utilProg(10).batchFile = "" -utilProg(10).useInputAsExeArgument = False -utilProg(10).fileSuffix = "" -utilProg(10).includeExtensionInCall = False -utilProg(10).waitUntilUtilityExits = False - - ' ' NOT SUPPORTED +' +'utilProg(10).name = "EP-Compare" +'utilProg(10).about = "Graphs the values from the tabular report for multiple simulations side by side." +'utilProg(10).enableInput = False +'utilProg(10).enableWthr = False +'utilProg(10).enableInTextEdit = True +'utilProg(10).IDFEdOpt = "" +'utilProg(10).inExt = "" +'utilProg(10).outExt1 = "" +'utilProg(10).outExt2 = "" +'utilProg(10).outExt3 = "" +'utilProg(10).outExt4 = "" +'utilProg(10).outExt5 = "" +'utilProg(10).outExt6 = "" +'utilProg(10).applicationFile = "PostProcess\EP-Compare\EP-Compare.exe" +'utilProg(10).appIsSpreadsheet = False +'utilProg(10).batchFile = "" +'utilProg(10).useInputAsExeArgument = False +'utilProg(10).fileSuffix = "" +'utilProg(10).includeExtensionInCall = False +'utilProg(10).waitUntilUtilityExits = False +' 'utilProg(8).name = "View3D" 'utilProg(8).about = "EnergyPlus has the capability of accepting user defined view factors for special research " & _ '"situations. This option is not recommended for general use. However, when a user desires to supply view " & _ diff --git a/src/EP-Launch/epl.vbp b/src/EP-Launch/epl.vbp index 9a9378a6940..102ef095540 100644 --- a/src/EP-Launch/epl.vbp +++ b/src/EP-Launch/epl.vbp @@ -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 @@ -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="" @@ -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" diff --git a/src/EP-Launch/epl.vbw b/src/EP-Launch/epl.vbw index 7ea35d0aad8..715f0af579b 100644 --- a/src/EP-Launch/epl.vbw +++ b/src/EP-Launch/epl.vbw @@ -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 diff --git a/src/EP-Launch/frmAbout.frm b/src/EP-Launch/frmAbout.frm index acd081ed8f1..61f12410a3d 100644 --- a/src/EP-Launch/frmAbout.frm +++ b/src/EP-Launch/frmAbout.frm @@ -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 diff --git a/src/EnergyPlus/BranchInputManager.cc b/src/EnergyPlus/BranchInputManager.cc index 46960e890bf..df484145803 100644 --- a/src/EnergyPlus/BranchInputManager.cc +++ b/src/EnergyPlus/BranchInputManager.cc @@ -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 //================================================================================== diff --git a/src/EnergyPlus/BranchInputManager.hh b/src/EnergyPlus/BranchInputManager.hh index 3a69f1dd406..c89d6275bf3 100644 --- a/src/EnergyPlus/BranchInputManager.hh +++ b/src/EnergyPlus/BranchInputManager.hh @@ -134,6 +134,7 @@ namespace BranchInputManager { // Functions void ManageBranchInput(EnergyPlusData &state); + void ManageConnectorInput(EnergyPlusData &state); //================================================================================== // Routines that "get" data from internal branch management structure diff --git a/src/EnergyPlus/HeatBalanceAirManager.cc b/src/EnergyPlus/HeatBalanceAirManager.cc index 2ba6b5d0543..9cd750681dd 100644 --- a/src/EnergyPlus/HeatBalanceAirManager.cc +++ b/src/EnergyPlus/HeatBalanceAirManager.cc @@ -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", diff --git a/src/EnergyPlus/HeatBalanceManager.cc b/src/EnergyPlus/HeatBalanceManager.cc index 704e0e6a7c7..dc1079e86d9 100644 --- a/src/EnergyPlus/HeatBalanceManager.cc +++ b/src/EnergyPlus/HeatBalanceManager.cc @@ -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:; diff --git a/src/EnergyPlus/SimulationManager.cc b/src/EnergyPlus/SimulationManager.cc index 5f4a4d212b6..d955fb48fd9 100644 --- a/src/EnergyPlus/SimulationManager.cc +++ b/src/EnergyPlus/SimulationManager.cc @@ -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(state); diff --git a/tst/EnergyPlus/unit/BranchInputManager.unit.cc b/tst/EnergyPlus/unit/BranchInputManager.unit.cc index 4000f82ae4b..c63d5d0328b 100644 --- a/tst/EnergyPlus/unit/BranchInputManager.unit.cc +++ b/tst/EnergyPlus/unit/BranchInputManager.unit.cc @@ -53,6 +53,7 @@ // EnergyPlus Headers #include #include +#include #include #include @@ -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 diff --git a/tst/EnergyPlus/unit/HeatBalanceManager.unit.cc b/tst/EnergyPlus/unit/HeatBalanceManager.unit.cc index 8ca53850122..2a68307e747 100644 --- a/tst/EnergyPlus/unit/HeatBalanceManager.unit.cc +++ b/tst/EnergyPlus/unit/HeatBalanceManager.unit.cc @@ -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) { diff --git a/tst/EnergyPlus/unit/Resources/Window5DataFile_ExtraBlankLines.dat b/tst/EnergyPlus/unit/Resources/Window5DataFile_ExtraBlankLines.dat new file mode 100644 index 00000000000..35831d66918 --- /dev/null +++ b/tst/EnergyPlus/unit/Resources/Window5DataFile_ExtraBlankLines.dat @@ -0,0 +1,75 @@ +Window5 Data File for EnergyPlus +BERKELEY LAB WINDOW v7.6.4.0 +Date : Thu Aug 20 14:36:08 2025 +Window name : Example A +Description : Fixed (picture) +# Glazing Systems: 1 +GLAZING SYSTEM DATA: Height Width nPanes Uval-center SC-center SHGC-center Tvis-center + System1 : 1398 1098 1 5.624 0.938 0.816 0.886 +FRAME/MULLION DATA: Width OutsideProj InsideProj Cond EdgeCondRatio SolAbs VisAbs Emiss Orient'n (mull) + L Sill : 50.8 25.4 25.4 500.000 0.524 0.300 0.300 0.90 + R Sill : 50.8 25.4 25.4 500.000 0.524 0.300 0.300 0.90 + L Head : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + R Head : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Top L Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Bot L Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Top R Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Bot R Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Mullion : 0.0 0.0 0.0 0.000 0.000 0.000 0.000 0.00 + Average frame: 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 +DIVIDER DATA : Width OutsideProj InsideProj Cond EdgeCondRatio SolAbs VisAbs Emiss Type #Hor #Vert + System1 : 0.0 0.0 0.0 0.000 0.000 0.000 0.000 0.000 None 0 0 +GLASS DATA : Layer# Thickness Cond Tsol Rfsol Rbsol Tvis Rfvis Rbvis Tir EmissF EmissB SpectralDataFile + System1 : 1 5.664 1.000 0.771 0.072 0.073 0.886 0.085 0.085 0.000 0.840 0.840 Clear_6.VTA +GAP DATA : Gap# Thick nGasses +GAS DATA : GasName Fraction MWeight ACond BCond CCond AVisc BVisc CVisc ASpHeat BSpHeat CSpHeat +GLAZING SYSTEM OPTICAL DATA +Angle 0 10 20 30 40 50 60 70 80 90 Hemis +System1 +Tsol 0.771 0.770 0.767 0.761 0.750 0.728 0.681 0.575 0.347 0.000 0.689 +Abs1 0.157 0.158 0.161 0.165 0.171 0.177 0.183 0.184 0.167 0.000 0.171 +Rfsol 0.072 0.072 0.072 0.074 0.079 0.095 0.137 0.241 0.486 1.000 0.130 +Rbsol 0.073 0.072 0.072 0.074 0.079 0.095 0.137 0.241 0.486 1.000 0.130 +Tvis 0.886 0.886 0.885 0.882 0.875 0.856 0.808 0.692 0.431 0.000 0.808 +Rfvis 0.085 0.085 0.085 0.087 0.093 0.111 0.157 0.272 0.533 1.000 0.149 +Rbvis 0.085 0.085 0.085 0.087 0.093 0.111 0.157 0.272 0.533 1.000 0.149 + +Window5 Data File for EnergyPlus + + +BERKELEY LAB WINDOW v7.6.4.0 + +Date : Thu Aug 20 14:36:08 2025 +Window name : Example B +Description : Fixed (picture) +# Glazing Systems: 1 +GLAZING SYSTEM DATA: Height Width nPanes Uval-center SC-center SHGC-center Tvis-center + System1 : 1398 1098 1 5.624 0.938 0.816 0.886 +FRAME/MULLION DATA: Width OutsideProj InsideProj Cond EdgeCondRatio SolAbs VisAbs Emiss Orient'n (mull) + L Sill : 50.8 25.4 25.4 500.000 0.524 0.300 0.300 0.90 + R Sill : 50.8 25.4 25.4 500.000 0.524 0.300 0.300 0.90 + L Head : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + R Head : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Top L Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Bot L Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Top R Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Bot R Jamb : 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 + Mullion : 0.0 0.0 0.0 0.000 0.000 0.000 0.000 0.00 + Average frame: 50.8 25.4 25.4 500.000 0.522 0.300 0.300 0.90 +DIVIDER DATA : Width OutsideProj InsideProj Cond EdgeCondRatio SolAbs VisAbs Emiss Type #Hor #Vert + System1 : 0.0 0.0 0.0 0.000 0.000 0.000 0.000 0.000 None 0 0 +GLASS DATA : Layer# Thickness Cond Tsol Rfsol Rbsol Tvis Rfvis Rbvis Tir EmissF EmissB SpectralDataFile + System1 : 1 5.664 1.000 0.771 0.072 0.073 0.886 0.085 0.085 0.000 0.840 0.840 Clear_6.VTA +GAP DATA : Gap# Thick nGasses +GAS DATA : GasName Fraction MWeight ACond BCond CCond AVisc BVisc CVisc ASpHeat BSpHeat CSpHeat +GLAZING SYSTEM OPTICAL DATA +Angle 0 10 20 30 40 50 60 70 80 90 Hemis +System1 +Tsol 0.771 0.770 0.767 0.761 0.750 0.728 0.681 0.575 0.347 0.000 0.689 +Abs1 0.157 0.158 0.161 0.165 0.171 0.177 0.183 0.184 0.167 0.000 0.171 +Rfsol 0.072 0.072 0.072 0.074 0.079 0.095 0.137 0.241 0.486 1.000 0.130 +Rbsol 0.073 0.072 0.072 0.074 0.079 0.095 0.137 0.241 0.486 1.000 0.130 +Tvis 0.886 0.886 0.885 0.882 0.875 0.856 0.808 0.692 0.431 0.000 0.808 +Rfvis 0.085 0.085 0.085 0.087 0.093 0.111 0.157 0.272 0.533 1.000 0.149 +Rbvis 0.085 0.085 0.085 0.087 0.093 0.111 0.157 0.272 0.533 1.000 0.149 +