diff --git a/VECTO/BusAuxiliaries/UI/frmAuxiliaryConfig.vb b/VECTO/BusAuxiliaries/UI/frmAuxiliaryConfig.vb index 8f208e16a6e346e7fa85dce90cd75488b72e4bf9..94b7d391528264e8e692e255e92aeef368c2fe57 100644 --- a/VECTO/BusAuxiliaries/UI/frmAuxiliaryConfig.vb +++ b/VECTO/BusAuxiliaries/UI/frmAuxiliaryConfig.vb @@ -27,7 +27,6 @@ Imports TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.Pneumatics Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.Electrics Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.HVAC Imports TUGraz.VectoCore.Models.BusAuxiliaries.Util -Imports TUGraz.VectoCore.Models.Declaration Imports TUGraz.VectoCore.OutputData.FileIO @@ -494,7 +493,7 @@ Public Class frmAuxiliaryConfig Try Dim ahsmFile As String = FilePathUtils.ResolveFilePath(aauxPath, txtSSMFilePath.Text) - Dim ssmTool As SSMTOOL = New SSMTOOL(SSMInputData.ReadFile(ahsmFile, Nothing, Nothing, DeclarationData.BusAuxiliaries.SSMTechnologyList)) ', New HVACConstants, False) + Dim ssmTool As SSMTOOL = New SSMTOOL(SSMInputData.ReadFile(ahsmFile, Nothing, Nothing)) ', New HVACConstants, False) 'If ssmTool.Load(ahsmFile) Then ' ErrorProvider.SetError(txtSSMFilePath, String.Empty) @@ -1031,7 +1030,7 @@ Public Class frmAuxiliaryConfig 'is file valid Try ahsm - HVac Steady State Model Try Dim ahsmFile As String = FilePathUtils.ResolveFilePath(aauxPath, absoluteSSMPath) - Dim ssmTool As SSMTOOL = new SSMTOOL(SSMInputData.ReadFile(ahsmFile, Nothing, Nothing, DeclarationData.BusAuxiliaries.SSMTechnologyList)) ' New SSMTOOL(ahsmFile, New HVACConstants, False) + Dim ssmTool As SSMTOOL = new SSMTOOL(SSMInputData.ReadFile(ahsmFile, Nothing, Nothing)) ' New SSMTOOL(ahsmFile, New HVACConstants, False) 'ssmTool.Load(ahsmFile) Catch ex As Exception MessageBox.Show("The supplied AHSM File was invalid, aborting.") diff --git a/VECTO/BusAuxiliaries/UI/frmHVACTool.vb b/VECTO/BusAuxiliaries/UI/frmHVACTool.vb index dc3d4e501a188bec6b40b9f3c7d83a51e2737017..db4e4d73ed544e5cf44b15ef294908a225866924 100644 --- a/VECTO/BusAuxiliaries/UI/frmHVACTool.vb +++ b/VECTO/BusAuxiliaries/UI/frmHVACTool.vb @@ -23,8 +23,8 @@ Public Class frmHVACTool Private ssmTOOL As SSMTOOL Private originalssmTOOL As SSMTOOL Private TabColors As Dictionary(Of TabPage, Color) = New Dictionary(Of TabPage, Color)() - Private editTechLine As ISSMTechnology = New SSMTechnology() - Private gvTechListBinding As BindingList(Of ISSMTechnology) + Private editTechLine As SSMTechnology = New SSMTechnology() + Private gvTechListBinding As BindingList(Of SSMTechnology) Private DefaultCategories As String() = {"Cooling", "Heating", "Insulation", "Ventiliation"} Private vectoFile As String = String.Empty Private UserHitCancel As Boolean = False @@ -56,36 +56,36 @@ Public Class frmHVACTool Private Sub BindGrid() - Dim _ - gvTechListBinding As _ - New BindingList(Of ISSMTechnology)( - ssmTOOL.TechList.TechLines.OrderBy(Function(o) o.Category).ThenBy(Function(t) t.BenefitName).ToList()) - Me.gvTechBenefitLines.DataSource = gvTechListBinding + 'Dim _ + ' gvTechListBinding As _ + ' New BindingList(Of ISSMTechnology)( + ' ssmTOOL.TechList.TechLines.OrderBy(Function(o) o.Category).ThenBy(Function(t) t.BenefitName).ToList()) + 'Me.gvTechBenefitLines.DataSource = gvTechListBinding End Sub Private Function GetCategories() As List(Of String) - If Not ssmTOOL Is Nothing AndAlso Not ssmTOOL.TechList Is Nothing AndAlso ssmTOOL.TechList.TechLines.Count > 0 Then + 'If Not ssmTOOL Is Nothing AndAlso Not ssmTOOL.TechList Is Nothing AndAlso ssmTOOL.TechList.TechLines.Count > 0 Then - 'Fuse Lists - Dim fusedList As List(Of String) = DefaultCategories.ToList() + ' 'Fuse Lists + ' Dim fusedList As List(Of String) = DefaultCategories.ToList() - For Each s As String In ssmTOOL.TechList.TechLines.Select(Function(sel) sel.Category) + ' For Each s As String In ssmTOOL.TechList.TechLines.Select(Function(sel) sel.Category) - If Not fusedList.Contains(s) Then - fusedList.Add(s) - End If + ' If Not fusedList.Contains(s) Then + ' fusedList.Add(s) + ' End If - Next + ' Next - Return fusedList.OrderBy(Function(o) o.ToString()).ToList() + ' Return fusedList.OrderBy(Function(o) o.ToString()).ToList() - Else + 'Else - Return New List(Of String)(DefaultCategories) + Return New List(Of String)(DefaultCategories) - End If - End Function + 'End If + End Function 'Constructors Public Sub New(busDatabasePath As String, ahsmFilePath As String, vectoFilePath As String, @@ -100,8 +100,8 @@ Public Class frmHVACTool Me.busDatabasePath = busDatabasePath Me.ahsmFilePath = ahsmFilePath - ssmTOOL = New SSMTOOL(SSMInputData.ReadFile(ahsmFilePath, Nothing, DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions, DeclarationData.BusAuxiliaries.SSMTechnologyList)) ' , New HVACConstants, False, useDefaults) - originalssmTOOL = New SSMTOOL(SSMInputData.ReadFile(ahsmFilePath, Nothing, DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions, DeclarationData.BusAuxiliaries.SSMTechnologyList)) ' ahsmFilePath, New HVACConstants, False, useDefaults) + ssmTOOL = New SSMTOOL(SSMInputData.ReadFile(ahsmFilePath, Nothing, DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions)) ' , New HVACConstants, False, useDefaults) + originalssmTOOL = New SSMTOOL(SSMInputData.ReadFile(ahsmFilePath, Nothing, DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions)) ' ahsmFilePath, New HVACConstants, False, useDefaults) 'If IO.File.Exists(ahsmFilePath) Then ' If ssmTOOL.Load(ahsmFilePath) AndAlso originalssmTOOL.Load(ahsmFilePath) Then @@ -990,37 +990,37 @@ Public Class frmHVACTool 'This must be a close box event. If nothing changed, then bail, otherwise ask user if they wanna save - If Not ssmTOOL.IsEqualTo(originalssmTOOL) Then + 'If Not ssmTOOL.IsEqualTo(originalssmTOOL) Then - result = - (MessageBox.Show("Would you like to save changes before closing?", "Save Changes", MessageBoxButtons.YesNoCancel, - MessageBoxIcon.Question)) + ' result = + ' (MessageBox.Show("Would you like to save changes before closing?", "Save Changes", MessageBoxButtons.YesNoCancel, + ' MessageBoxIcon.Question)) - Select Case result + ' Select Case result - Case DialogResult.Yes - 'save + ' Case DialogResult.Yes + ' 'save - If Not BusAuxWriter.SaveSSMConfig(ssmTOOL.SSMInputs, ahsmFilePath) Then - e.Cancel = True - End If + ' If Not BusAuxWriter.SaveSSMConfig(ssmTOOL.SSMInputs, ahsmFilePath) Then + ' e.Cancel = True + ' End If - Case DialogResult.No - 'just allow the form to close - 'without saving - Me.DialogResult = Windows.Forms.DialogResult.Cancel + ' Case DialogResult.No + ' 'just allow the form to close + ' 'without saving + ' Me.DialogResult = Windows.Forms.DialogResult.Cancel - Case DialogResult.Cancel - 'cancel the close - e.Cancel = True - Me.DialogResult = Windows.Forms.DialogResult.Cancel + ' Case DialogResult.Cancel + ' 'cancel the close + ' e.Cancel = True + ' Me.DialogResult = Windows.Forms.DialogResult.Cancel - End Select + ' End Select - End If + 'End If UserHitCancel = False UserHitSave = False @@ -1039,7 +1039,7 @@ Public Class frmHVACTool category = CType(gvTechBenefitLines.Rows(row).Cells("Category").Value, String) - editTechLine = ssmTOOL.TechList.TechLines.First(Function(f) f.BenefitName = benefitName AndAlso f.Category = category) + 'editTechLine = ssmTOOL.TechList.TechLines.First(Function(f) f.BenefitName = benefitName AndAlso f.Category = category) FillTechLineEditPanel(row) @@ -1116,15 +1116,15 @@ Public Class frmHVACTool BindGrid() 'find new row - Dim ol As List(Of ISSMTechnology) = - ssmTOOL.TechList.TechLines.OrderBy(Function(x) x.Category).ThenBy(Function(tb) tb.BenefitName).ToList() - Dim item As ISSMTechnology = - ol.First( - Function(x) _ - x.Category = GetTechLineFromPanel().Category AndAlso x.BenefitName = GetTechLineFromPanel().BenefitName) - Dim idx As Integer = ol.IndexOf(item) + 'Dim ol As List(Of ISSMTechnology) = + ' ssmTOOL.TechList.TechLines.OrderBy(Function(x) x.Category).ThenBy(Function(tb) tb.BenefitName).ToList() + 'Dim item As ISSMTechnology = + ' ol.First( + ' Function(x) _ + ' x.Category = GetTechLineFromPanel().Category AndAlso x.BenefitName = GetTechLineFromPanel().BenefitName) + 'Dim idx As Integer = ol.IndexOf(item) - gvTechBenefitLines.FirstDisplayedScrollingRowIndex = idx + 'gvTechBenefitLines.FirstDisplayedScrollingRowIndex = idx cboCategory.DataSource = GetCategories() @@ -1330,13 +1330,13 @@ Public Class frmHVACTool 'TechList Helpers Private Sub FillTechLineEditPanel(index As Integer) - Dim techline As ISSMTechnology + Dim techline As SSMTechnology Dim benefitName, category As Object benefitName = gvTechBenefitLines.Rows(index).Cells("BenefitName").Value category = gvTechBenefitLines.Rows(index).Cells("Category").Value - techline = - ssmTOOL.TechList.TechLines.First(Function(f) f.BenefitName.Equals(benefitName) AndAlso f.Category.Equals(category)) + 'techline = + ' ssmTOOL.TechList.TechLines.First(Function(f) f.BenefitName.Equals(benefitName) AndAlso f.Category.Equals(category)) txtIndex.Text = index.ToString() cboCategory.Text = techline.Category @@ -1357,10 +1357,10 @@ Public Class frmHVACTool 'chkOnVehicle.Checked = techline.OnVehicle End Sub - Private Function GetTechLineFromPanel() As ISSMTechnology + Private Function GetTechLineFromPanel() As SSMTechnology Dim tl As SSMTechnology = New SSMTechnology() - tl.BusFloorType = ssmTOOL.SSMInputs.BusParameters.BusFloorType + 'tl.BusFloorType = ssmTOOL.SSMInputs.BusParameters.BusFloorType tl.Category = StrConv(cboCategory.Text, vbProperCase) tl.BenefitName = txtBenefitName.Text diff --git a/VECTOAux/VectoAuxiliariesTests/UnitTests/M0_5_SmartAlternatorSetEfficiencyTests.vb b/VECTOAux/VectoAuxiliariesTests/UnitTests/M0_5_SmartAlternatorSetEfficiencyTests.vb index 5ddfd2cef90ed63e0e9271227f71c28cc069a0d9..14ab45c69f2e01b5950f23ca6946016ae9180f58 100644 --- a/VECTOAux/VectoAuxiliariesTests/UnitTests/M0_5_SmartAlternatorSetEfficiencyTests.vb +++ b/VECTOAux/VectoAuxiliariesTests/UnitTests/M0_5_SmartAlternatorSetEfficiencyTests.vb @@ -4,7 +4,6 @@ Imports TUGraz.VectoCommon.BusAuxiliaries Imports TUGraz.VectoCommon.Models Imports TUGraz.VectoCommon.Utils -Imports TUGraz.VectoCore.BusAuxiliaries.Interfaces.DownstreamModules Imports TUGraz.VectoCore.InputData.FileIO.JSON Imports TUGraz.VectoCore.InputData.Reader.ComponentData Imports TUGraz.VectoCore.Models.BusAuxiliaries @@ -15,7 +14,6 @@ Imports TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.Pneumatics Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.HVAC -Imports TUGraz.VectoCore.Models.Declaration Imports TUGraz.VectoCore.Models.SimulationComponent.Data @@ -41,8 +39,7 @@ Namespace UnitTests Const _SSMMAP As String = "TestFiles\ssm.Ahsm" 'Const _BusDatabase As String ="TestFiles\BusDatabase.abdb - dim ssmInput As ISSMInputs = SSMInputData.ReadFile(_SSMMAP, utils.GetDefaultVehicleData(), Nothing, - DeclarationData.BusAuxiliaries.SSMTechnologyList) + dim ssmInput As ISSMInputs = SSMInputData.ReadFile(_SSMMAP, utils.GetDefaultVehicleData(), Nothing) 'CType(CType(ssmInput, SSMInputs).Vehicle, VehicleData).Height = 0.SI (Of Meter) Dim ssm As ISSMTOOL = New SSMTOOL(ssmInput) diff --git a/VECTOAux/VectoAuxiliariesTests/UnitTests/M14Tests.vb b/VECTOAux/VectoAuxiliariesTests/UnitTests/M14Tests.vb index e6516ad05c4087068d4a6135af68c33426d92d9f..d52c732212cf7abfdc6c522249587b16c17be11d 100644 --- a/VECTOAux/VectoAuxiliariesTests/UnitTests/M14Tests.vb +++ b/VECTOAux/VectoAuxiliariesTests/UnitTests/M14Tests.vb @@ -70,9 +70,9 @@ Namespace UnitTests End Set End Property - Public Function IsEqualTo(source As ISSMTOOL) As Boolean Implements ISSMTOOL.IsEqualTo - Throw New NotImplementedException - End Function + 'Public Function IsEqualTo(source As ISSMTOOL) As Boolean Implements ISSMTOOL.IsEqualTo + ' Throw New NotImplementedException + 'End Function 'Public Function Load(filePath As String) As Boolean Implements ISSMTOOL.Load ' Throw New NotImplementedException @@ -94,9 +94,8 @@ Namespace UnitTests ' Throw New NotImplementedException 'End Function - Public Property TechList As ISSMTechList Implements ISSMTOOL.TechList + Public Property TechList As ISSMTechnologyBenefits Implements ISSMTOOL.TechList - Public Event Message(ByRef sender As Object, message As String, messageType As AdvancedAuxiliaryMessageType) Implements ISSMTOOL.Message End Class diff --git a/VECTOAux/VectoAuxiliariesTests/UnitTests/M1_AverageHVACLoadDemandTests.vb b/VECTOAux/VectoAuxiliariesTests/UnitTests/M1_AverageHVACLoadDemandTests.vb index a4b92284960b0c8f11c552c067f03604adc8644e..4fbe0265817213416423dc7813edccc4a6341260 100644 --- a/VECTOAux/VectoAuxiliariesTests/UnitTests/M1_AverageHVACLoadDemandTests.vb +++ b/VECTOAux/VectoAuxiliariesTests/UnitTests/M1_AverageHVACLoadDemandTests.vb @@ -47,7 +47,7 @@ Namespace UnitTests dim auxConfig = Utils.GetAuxTestConfig() dim vehicle = auxConfig.VehicleData CType(vehicle, VehicleData).Height = 0.SI (of Meter) - Dim ssmInput = SSMInputData.ReadFile(_SSMMAP, vehicle, Nothing, SSMTechnologiesReader.ReadFromFile("TestFiles/TechBenefits.csv")) + Dim ssmInput = SSMInputData.ReadFile(_SSMMAP, vehicle, Nothing) ssm = New SSMTOOL(ssmInput) alternatorMap = AlternatorReader.ReadMap(_GOODMAP) @@ -55,9 +55,9 @@ Namespace UnitTests 'ssm.Load(_SSMMAP) - For Each entry As ISSMTechnology In ssm.TechList.TechLines - 'entry.OnVehicle = True - Next + 'For Each entry As ISSMTechnology In ssm.TechList.TechLines + ' entry.OnVehicle = True + 'Next CType(auxConfig.ElectricalUserInputsConfig, ElectricsUserInputsConfig).PowerNetVoltage = powernetVoltage CType(auxConfig.ElectricalUserInputsConfig, ElectricsUserInputsConfig).AlternatorMap =alternatorMap @@ -68,9 +68,9 @@ Namespace UnitTests 'ssm.Load(_SSMMAP) - For Each entry As ISSMTechnology In ssm.TechList.TechLines - 'entry.OnVehicle = true - next + 'For Each entry As ISSMTechnology In ssm.TechList.TechLines + ' entry.OnVehicle = true + 'next Return New M01Impl(m0, alternatorGearEfficiency, compressorGrearEfficiency, diff --git a/VECTOAux/VectoAuxiliariesTests/UnitTests/M2_AverageElectricalLoadTests.vb b/VECTOAux/VectoAuxiliariesTests/UnitTests/M2_AverageElectricalLoadTests.vb index 0bd4f37c949cd551c30b6e7392fcb1fab7d1586b..e21d2cd937a521c6928045c0018ff6a48ae7fdd2 100644 --- a/VECTOAux/VectoAuxiliariesTests/UnitTests/M2_AverageElectricalLoadTests.vb +++ b/VECTOAux/VectoAuxiliariesTests/UnitTests/M2_AverageElectricalLoadTests.vb @@ -14,7 +14,6 @@ Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.Electrics Imports TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.HVAC -Imports TUGraz.VectoCore.Models.Declaration Imports TUGraz.VectoCore.Models.SimulationComponent.Data @@ -33,7 +32,7 @@ Namespace UnitTests Const _SSMMAP As String = "TestFiles\ssm.Ahsm" 'Const _BusDatabase As String ="TestFiles\BusDatabase.abdb - Dim ssm As ISSMTOOL = New SSMTOOL(SSMInputData.ReadFile(_SSMMAP, Utils.GetDefaultVehicleData(), Nothing, DeclarationData.BusAuxiliaries.SSMTechnologyList)) + Dim ssm As ISSMTOOL = New SSMTOOL(SSMInputData.ReadFile(_SSMMAP, Utils.GetDefaultVehicleData(), Nothing)) 'CType(CType(ssm.SSMInputs, SSMInputs).Vehicle, VehicleData).Height = 0.SI(of Meter) 'ssm.Load(_SSMMAP) diff --git a/VECTOAux/VectoAuxiliariesTests/UnitTests/SSMTOOLTests.vb b/VECTOAux/VectoAuxiliariesTests/UnitTests/SSMTOOLTests.vb index bb4df027bfeac26bec9897aee0cd71f303111bbc..f461d5b0bd444c433e1498316d0f17d804c67689 100644 --- a/VECTOAux/VectoAuxiliariesTests/UnitTests/SSMTOOLTests.vb +++ b/VECTOAux/VectoAuxiliariesTests/UnitTests/SSMTOOLTests.vb @@ -27,7 +27,7 @@ Namespace UnitTests Dim src As SSMTOOL = DirectCast(source, SSMTOOL) Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = src.SSMInputs.BusParameters.BusFloorType + 'newItem.BusFloorType = src.SSMInputs.BusParameters.BusFloorType 'newItem.Units = "fraction" @@ -54,7 +54,7 @@ Namespace UnitTests Dim feedback As String = String.Empty - CType(src.TechList, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) + 'CType(src.TechList, SSMTechList).TechLines = New List(Of SSMTechnology)({newItem}) End Sub <OneTimeSetUp> @@ -173,11 +173,11 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechList).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechList).Items - Assert.IsTrue(target.TechLines.Count > 0) + 'Assert.IsTrue(target.TechLines.Count > 0) End Sub <Test()> @@ -186,19 +186,19 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListALLON).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListALLON).Items - For Each entry As ISSMTechnology In target.TechLines + 'For Each entry As ISSMTechnology In target.TechLines 'entry.OnVehicle = True - Next + 'Next - Assert.IsTrue(target.TechLines.Count > 0) - Assert.AreEqual(0.142, Math.Round(target.HValueVariation, 3)) - Assert.AreEqual(0.006, Math.Round(target.VHValueVariation, 3)) - Assert.AreEqual(0.006, Math.Round(target.VVValueVariation, 3)) - Assert.AreEqual(0.006, Math.Round(target.VCValueVariation, 3)) - Assert.AreEqual(0.259, Math.Round(target.CValueVariation, 3)) + 'Assert.IsTrue(target.TechLines.Count > 0) + 'Assert.AreEqual(0.142, Math.Round(target.HValueVariation, 3)) + 'Assert.AreEqual(0.006, Math.Round(target.VHValueVariation, 3)) + 'Assert.AreEqual(0.006, Math.Round(target.VVValueVariation, 3)) + 'Assert.AreEqual(0.006, Math.Round(target.VCValueVariation, 3)) + 'Assert.AreEqual(0.259, Math.Round(target.CValueVariation, 3)) 'Assert.AreEqual(0.0, Math.Round(target.VHValueVariationKW, 3)) 'Assert.AreEqual(0.0, Math.Round(target.VVValueVariationKW, 3)) @@ -214,12 +214,12 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items - 'Assert.IsTrue(target.Initialise()) + ''Assert.IsTrue(target.Initialise()) - Assert.IsTrue(target.TechLines.Count = 0) + 'Assert.IsTrue(target.TechLines.Count = 0) End Sub <Test()> @@ -228,39 +228,39 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items - Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = gen.BusParameters.BusFloorType + 'Dim newItem As SSMTechnology = New SSMTechnology() + 'newItem.BusFloorType = gen.BusParameters.BusFloorType - 'newItem.Units = "fraction" - newItem.Category = "Insulation" - newItem.BenefitName = "Benefit1" + ''newItem.Units = "fraction" + 'newItem.Category = "Insulation" + 'newItem.BenefitName = "Benefit1" - newItem.LowFloorH = 0.1 - newItem.LowFloorV = 0.1 - newItem.LowFloorC = 0.1 + 'newItem.LowFloorH = 0.1 + 'newItem.LowFloorV = 0.1 + 'newItem.LowFloorC = 0.1 - newItem.SemiLowFloorH = 0.1 - newItem.SemiLowFloorV = 0.1 - newItem.SemiLowFloorC = 0.1 + 'newItem.SemiLowFloorH = 0.1 + 'newItem.SemiLowFloorV = 0.1 + 'newItem.SemiLowFloorC = 0.1 - newItem.RaisedFloorH = 0.1 - newItem.RaisedFloorV = 0.1 - newItem.RaisedFloorC = 0.1 + 'newItem.RaisedFloorH = 0.1 + 'newItem.RaisedFloorV = 0.1 + 'newItem.RaisedFloorC = 0.1 - 'newItem.OnVehicle = True - newItem.ActiveVH = True - newItem.ActiveVV = True - newItem.ActiveVC = True - 'newItem.LineType = TechLineType.Normal + ''newItem.OnVehicle = True + 'newItem.ActiveVH = True + 'newItem.ActiveVV = True + 'newItem.ActiveVC = True + ''newItem.LineType = TechLineType.Normal - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) + 'CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) - Assert.IsTrue(target.TechLines.Count = 1) + 'Assert.IsTrue(target.TechLines.Count = 1) End Sub <Test()> @@ -269,40 +269,40 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items - Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = gen.BusParameters.BusFloorType + 'Dim newItem As SSMTechnology = New SSMTechnology() + 'newItem.BusFloorType = gen.BusParameters.BusFloorType - 'newItem.Units = "fraction" - newItem.Category = "Insulation" - newItem.BenefitName = "Benefit1" + ''newItem.Units = "fraction" + 'newItem.Category = "Insulation" + 'newItem.BenefitName = "Benefit1" - newItem.LowFloorH = 0.1 - newItem.LowFloorV = 0.1 - newItem.LowFloorC = 0.1 + 'newItem.LowFloorH = 0.1 + 'newItem.LowFloorV = 0.1 + 'newItem.LowFloorC = 0.1 - newItem.SemiLowFloorH = 0.1 - newItem.SemiLowFloorV = 0.1 - newItem.SemiLowFloorC = 0.1 + 'newItem.SemiLowFloorH = 0.1 + 'newItem.SemiLowFloorV = 0.1 + 'newItem.SemiLowFloorC = 0.1 - newItem.RaisedFloorH = 0.1 - newItem.RaisedFloorV = 0.1 - newItem.RaisedFloorC = 0.1 + 'newItem.RaisedFloorH = 0.1 + 'newItem.RaisedFloorV = 0.1 + 'newItem.RaisedFloorC = 0.1 - 'newItem.OnVehicle = True - newItem.ActiveVH = True - newItem.ActiveVV = True - newItem.ActiveVC = True - 'newItem.LineType = TechLineType.Normal + ''newItem.OnVehicle = True + 'newItem.ActiveVH = True + 'newItem.ActiveVV = True + 'newItem.ActiveVC = True + ''newItem.LineType = TechLineType.Normal - Dim feedback As String = String.Empty + 'Dim feedback As String = String.Empty - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) + 'CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) + 'CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) - Assert.IsTrue(target.TechLines.Count = 1) + 'Assert.IsTrue(target.TechLines.Count = 1) End Sub <Test()> @@ -311,40 +311,40 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items - Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = gen.BusParameters.BusFloorType + 'Dim newItem As SSMTechnology = New SSMTechnology() + 'newItem.BusFloorType = gen.BusParameters.BusFloorType - 'newItem.Units = "fraction" - newItem.Category = "Insulation" - newItem.BenefitName = "Benefit1" + ''newItem.Units = "fraction" + 'newItem.Category = "Insulation" + 'newItem.BenefitName = "Benefit1" - newItem.LowFloorH = 0.1 - newItem.LowFloorV = 0.1 - newItem.LowFloorC = 0.1 + 'newItem.LowFloorH = 0.1 + 'newItem.LowFloorV = 0.1 + 'newItem.LowFloorC = 0.1 - newItem.SemiLowFloorH = 0.1 - newItem.SemiLowFloorV = 0.1 - newItem.SemiLowFloorC = 0.1 + 'newItem.SemiLowFloorH = 0.1 + 'newItem.SemiLowFloorV = 0.1 + 'newItem.SemiLowFloorC = 0.1 - newItem.RaisedFloorH = 0.1 - newItem.RaisedFloorV = 0.1 - newItem.RaisedFloorC = 0.1 + 'newItem.RaisedFloorH = 0.1 + 'newItem.RaisedFloorV = 0.1 + 'newItem.RaisedFloorC = 0.1 - 'newItem.OnVehicle = True - newItem.ActiveVH = True - newItem.ActiveVV = True - newItem.ActiveVC = True - 'newItem.LineType = TechLineType.Normal + ''newItem.OnVehicle = True + 'newItem.ActiveVH = True + 'newItem.ActiveVV = True + 'newItem.ActiveVC = True + ''newItem.LineType = TechLineType.Normal - Dim feedback As String = String.Empty + 'Dim feedback As String = String.Empty - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) - Assert.IsTrue(target.TechLines.Count = 1) - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)() - Assert.IsTrue(target.TechLines.Count = 0) + 'CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) + 'Assert.IsTrue(target.TechLines.Count = 1) + 'CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)() + 'Assert.IsTrue(target.TechLines.Count = 0) End Sub <Test()> @@ -353,40 +353,40 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As ISSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items - Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = gen.BusParameters.BusFloorType + 'Dim newItem As SSMTechnology = New SSMTechnology() + 'newItem.BusFloorType = gen.BusParameters.BusFloorType - 'newItem.Units = "fraction" - newItem.Category = "Insulation" - newItem.BenefitName = "Benefit1" + ''newItem.Units = "fraction" + 'newItem.Category = "Insulation" + 'newItem.BenefitName = "Benefit1" - newItem.LowFloorH = 0.1 - newItem.LowFloorV = 0.1 - newItem.LowFloorC = 0.1 + 'newItem.LowFloorH = 0.1 + 'newItem.LowFloorV = 0.1 + 'newItem.LowFloorC = 0.1 - newItem.SemiLowFloorH = 0.1 - newItem.SemiLowFloorV = 0.1 - newItem.SemiLowFloorC = 0.1 + 'newItem.SemiLowFloorH = 0.1 + 'newItem.SemiLowFloorV = 0.1 + 'newItem.SemiLowFloorC = 0.1 - newItem.RaisedFloorH = 0.1 - newItem.RaisedFloorV = 0.1 - newItem.RaisedFloorC = 0.1 + 'newItem.RaisedFloorH = 0.1 + 'newItem.RaisedFloorV = 0.1 + 'newItem.RaisedFloorC = 0.1 - 'newItem.OnVehicle = True - newItem.ActiveVH = True - newItem.ActiveVV = True - newItem.ActiveVC = True - 'newItem.LineType = TechLineType.Normal + ''newItem.OnVehicle = True + 'newItem.ActiveVH = True + 'newItem.ActiveVV = True + 'newItem.ActiveVC = True + ''newItem.LineType = TechLineType.Normal - 'Add - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) + ''Add + 'CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) - 'Modify - newItem.LowFloorC = 0.99 - Assert.IsTrue(target.TechLines(0).IsEqualTo(newItem)) + ''Modify + 'newItem.LowFloorC = 0.99 + 'Assert.IsTrue(target.TechLines(0).IsEqualTo(newItem)) End Sub <Test()> @@ -395,11 +395,11 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As SSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As SSMTechList = New SSMTechList() + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = gen.BusParameters.BusFloorType + 'newItem.BusFloorType = gen.BusParameters.BusFloorType 'newItem.Units = "fraction" newItem.Category = "Insulation" @@ -423,10 +423,10 @@ Namespace UnitTests newItem.ActiveVC = True 'newItem.LineType = TechLineType.Normal - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)({newItem}) - Assert.IsTrue(target.TechLines.Count = 1) - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)() - Assert.IsTrue(target.TechLines.Count = 0) + 'CType(target, SSMTechList).TechLines = New List(Of SSMTechnology)({newItem}) + 'Assert.IsTrue(target.TechLines.Count = 1) + 'CType(target, SSMTechList).TechLines = New List(Of SSMTechnology)() + 'Assert.IsTrue(target.TechLines.Count = 0) End Sub <Test()> @@ -435,11 +435,11 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim target As SSMTechList = New SSMTechList(gen.BusParameters.BusFloorType) - target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items + 'Dim target As SSMTechList = New SSMTechList() + 'target.TechLines = SSMTechnologiesReader.ReadFromFile(GOODTechListEMPTYLIST).Items Dim newItem As SSMTechnology = New SSMTechnology() - newItem.BusFloorType = gen.BusParameters.BusFloorType + 'newItem.BusFloorType = gen.BusParameters.BusFloorType 'newItem.Units = "fraction" newItem.Category = "Insulation" @@ -463,7 +463,7 @@ Namespace UnitTests newItem.ActiveVC = True 'newItem.LineType = TechLineType.Normal - CType(target, SSMTechList).TechLines = New List(Of ISSMTechnology)() + 'CType(target, SSMTechList).TechLines = New List(Of SSMTechnology)() End Sub 'TechListLineTests @@ -472,8 +472,8 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim ttl As ISSMTechnology = New SSMTechnology() - ttl.BusFloorType = gen.BusParameters.BusFloorType + Dim ttl As SSMTechnology = New SSMTechnology() + 'ttl.BusFloorType = gen.BusParameters.BusFloorType Assert.IsNotNull(ttl) End Sub @@ -483,13 +483,13 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) - Dim ttl1 As ISSMTechnology = New SSMTechnology() - ttl1.BusFloorType = gen.BusParameters.BusFloorType + Dim ttl1 As SSMTechnology = New SSMTechnology() + 'ttl1.BusFloorType = gen.BusParameters.BusFloorType - Dim ttl2 As ISSMTechnology = New SSMTechnology() - ttl2.BusFloorType = gen.BusParameters.BusFloorType + Dim ttl2 As SSMTechnology = New SSMTechnology() + 'ttl2.BusFloorType = gen.BusParameters.BusFloorType - Assert.IsTrue(ttl1.IsEqualTo(ttl2)) + 'Assert.IsTrue(ttl1.IsEqualTo(ttl2)) End Sub '<TestCase("Units")> _ @@ -515,10 +515,10 @@ Namespace UnitTests Dim gen As ISSMInputs = New SSMInputs(Nothing) Dim ttl1 As SSMTechnology = New SSMTechnology() - ttl1.BusFloorType = gen.BusParameters.BusFloorType + 'ttl1.BusFloorType = gen.BusParameters.BusFloorType Dim ttl2 As SSMTechnology = New SSMTechnology() - ttl2.BusFloorType = gen.BusParameters.BusFloorType + 'ttl2.BusFloorType = gen.BusParameters.BusFloorType Select Case prop @@ -561,7 +561,7 @@ Namespace UnitTests End Select - Assert.IsFalse(ttl1.IsEqualTo(ttl2)) + 'Assert.IsFalse(ttl1.IsEqualTo(ttl2)) End Sub 'SSMTOOL Persistance @@ -599,8 +599,7 @@ Namespace UnitTests 'success = target.Load(filePath) Try target = New SSMTOOL(SSMInputData.ReadFile(filePath, utils.GetDefaultVehicleData(), - DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions, - DeclarationData.BusAuxiliaries.SSMTechnologyList)) + DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions)) Catch success = false end try @@ -631,7 +630,7 @@ Namespace UnitTests ', New HVACConstants()) - Assert.IsTrue(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsTrue(ssmTool1.IsEqualTo(ssmTool2)) End Sub <Test()> @@ -660,7 +659,7 @@ Namespace UnitTests ', New HVACConstants()) - Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) End Sub 'TechListBenefitLine Comparison @@ -682,7 +681,7 @@ Namespace UnitTests ' DeclarationData.BusAuxiliaries.SSMTechnologyList)) - Assert.IsTrue(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsTrue(ssmTool1.IsEqualTo(ssmTool2)) End Sub <Test()> @@ -705,7 +704,7 @@ Namespace UnitTests 'Change something on techlist AddDefaultTechLine(ssmTool1) - Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) End Sub <Test()> @@ -729,7 +728,7 @@ Namespace UnitTests AddDefaultTechLine(ssmTool1) AddDefaultTechLine(ssmTool2) - Assert.IsTrue(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsTrue(ssmTool1.IsEqualTo(ssmTool2)) End Sub <Test()> @@ -754,9 +753,9 @@ Namespace UnitTests AddDefaultTechLine(ssmTool2) 'Make Unequal - CType(ssmTool2.TechList.TechLines(0), SSMTechnology).BenefitName = "Doobie" + 'CType(ssmTool2.TechList.TechLines(0), SSMTechnology).BenefitName = "Doobie" - Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) End Sub <Test()> @@ -781,9 +780,9 @@ Namespace UnitTests AddDefaultTechLine(ssmTool2) 'Make Unequal - CType(ssmTool2.TechList.TechLines(0), SSMTechnology).ActiveVV = False + 'CType(ssmTool2.TechList.TechLines(0), SSMTechnology).ActiveVV = False - Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) + 'Assert.IsFalse(ssmTool1.IsEqualTo(ssmTool2)) End Sub End Class End Namespace diff --git a/VECTOAux/VectoAuxiliariesTests/UnitTests/Utils.vb b/VECTOAux/VectoAuxiliariesTests/UnitTests/Utils.vb index 398f2232830f11fd61750aa50695003b2f8ebb45..c627dea59f202795a918cea1f20be9fa447dd42e 100644 --- a/VECTOAux/VectoAuxiliariesTests/UnitTests/Utils.vb +++ b/VECTOAux/VectoAuxiliariesTests/UnitTests/Utils.vb @@ -93,6 +93,16 @@ Public Class Utils 11.8.SI(Unit.SI.Kilo.Watt.Hour.Per.kilo.Gramm).Cast _ (Of JoulePerKilogramm)) + Dim techBenefits = New TechnologyBenefits + For Each item As SSMTechnology In DeclarationData.BusAuxiliaries.SSMTechnologyList + techBenefits.CValueVariation += item.RaisedFloorC + techBenefits.HValueVariation += item.RaisedFloorH + techBenefits.VCValueVariation += If(item.ActiveVC, item.RaisedFloorV, 0) + techBenefits.VHValueVariation += if (item.ActiveVH, item.RaisedFloorV, 0) + techBenefits.VVValueVariation += If (item.ActiveVV, item.RaisedFloorV, 0) + + Next + Dim retval = New AuxiliaryConfig() With { .ElectricalUserInputsConfig = New ElectricsUserInputsConfig() With { .AverageCurrentDemandInclBaseLoad = 0.SI(Of Ampere), @@ -116,7 +126,7 @@ Public Class Utils .SmartRegeneration = False }, .SSMInputs = New SSMInputs(Nothing, heatingFuel) With { - .Technologies = DeclarationData.BusAuxiliaries.SSMTechnologyList, + .Technologies = techBenefits, .DefaultConditions = New EnvironmentalConditionMapEntry(25.0.DegCelsiusToKelvin(), 400.SI (Of WattPerSquareMeter), 1.0), .EnvironmentalConditionsMap = DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions, diff --git a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMInputs.cs b/VectoCommon/VectoCommon/BusAuxiliaries/ISSMInputs.cs index 945f390b21f3ffcf0716c07ee4732ddfa9903004..62c8c616d0a21a847e3d4da0b2df17bf1844b243 100644 --- a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMInputs.cs +++ b/VectoCommon/VectoCommon/BusAuxiliaries/ISSMInputs.cs @@ -11,7 +11,7 @@ namespace TUGraz.VectoCommon.BusAuxiliaries ISSMBusParameters BusParameters { get; } - ISSMTechnologies Technologies { get; } + ISSMTechnologyBenefits Technologies { get; } ISSMBoundaryConditions BoundaryConditions { get; } diff --git a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechList.cs b/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechList.cs deleted file mode 100644 index db6ee323f10760c2715c0bb81b7dfa46c20778dc..0000000000000000000000000000000000000000 --- a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechList.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System.Collections.Generic; - -namespace TUGraz.VectoCommon.BusAuxiliaries -{ - public interface ISSMTechList - { - IReadOnlyList<ISSMTechnology> TechLines { get; set; } - - //void Clear(); - //ITechListBenefitLine Find(string category, string benefitName); - //bool Add(ITechListBenefitLine item, ref string feedback); - //bool Delete(ITechListBenefitLine item, ref string feedback); - //bool Modify(ITechListBenefitLine originalItem, ITechListBenefitLine modifiedItem, ref string feedback); - - //void SetSSMGeneralInputs(ISSMInputs genInputs); - - double HValueVariation { get; } - double VHValueVariation { get; } - double VVValueVariation { get; } - double VCValueVariation { get; } - double CValueVariation { get; } - - //double HValueVariationKW { get; } - //double VHValueVariationKW { get; } - //double VVValueVariationKW { get; } - //double VCValueVariationKW { get; } - //double CValueVariationKW { get; } - - - //bool Initialise(); - //bool Initialise(string filePath); - } -} diff --git a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechnology.cs b/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechnology.cs deleted file mode 100644 index b60d54351fb316d10e5eae928c2a721407c0f8a7..0000000000000000000000000000000000000000 --- a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechnology.cs +++ /dev/null @@ -1,44 +0,0 @@ -using System.Collections.Generic; - -namespace TUGraz.VectoCommon.BusAuxiliaries { - - public interface ISSMTechnologies - { - IReadOnlyList<ISSMTechnology> Items { get; } - - string Source { get; } - } - - public interface ISSMTechnology - { - FloorType BusFloorType { set; } - - string Category { get; } - string BenefitName { get; } - - double LowFloorH { get; } - double LowFloorV { get; } - double LowFloorC { get; } - - double SemiLowFloorH { get; } - double SemiLowFloorV { get; } - double SemiLowFloorC { get; } - - double RaisedFloorH { get; } - double RaisedFloorV { get; } - double RaisedFloorC { get; } - - //bool OnVehicle { get; set; } - bool ActiveVH { get; } - bool ActiveVV { get; } - bool ActiveVC { get; } - - double H { get; } - double VH { get; } - double VV { get; } - double VC { get; } - double C { get; } - - bool IsEqualTo(ISSMTechnology source); - } -} \ No newline at end of file diff --git a/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechnologyBenefits.cs b/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechnologyBenefits.cs new file mode 100644 index 0000000000000000000000000000000000000000..37645a7563fec249a4b0fb15941d88c6c3dfb71b --- /dev/null +++ b/VectoCommon/VectoCommon/BusAuxiliaries/ISSMTechnologyBenefits.cs @@ -0,0 +1,14 @@ +using System.Collections.Generic; + +namespace TUGraz.VectoCommon.BusAuxiliaries +{ + public interface ISSMTechnologyBenefits + { + double HValueVariation { get; } + double VHValueVariation { get; } + double VVValueVariation { get; } + double VCValueVariation { get; } + double CValueVariation { get; } + + } +} diff --git a/VectoCommon/VectoCommon/VectoCommon.csproj b/VectoCommon/VectoCommon/VectoCommon.csproj index eaf17f4cebe85acce149477f06afa8f70a51a05e..cc1c98a007429650abaed40ac38fb439c91cca67 100644 --- a/VectoCommon/VectoCommon/VectoCommon.csproj +++ b/VectoCommon/VectoCommon/VectoCommon.csproj @@ -71,8 +71,7 @@ <Compile Include="BusAuxiliaries\IResultCard.cs" /> <Compile Include="BusAuxiliaries\ISignals.cs" /> <Compile Include="BusAuxiliaries\ISSMInputs.cs" /> - <Compile Include="BusAuxiliaries\ISSMTechList.cs" /> - <Compile Include="BusAuxiliaries\ISSMTechnology.cs" /> + <Compile Include="BusAuxiliaries\ISSMTechnologyBenefits.cs" /> <Compile Include="BusAuxiliaries\IVehicleData.cs" /> <Compile Include="BusAuxiliaries\SmartResult.cs" /> <Compile Include="Hashing\IVectoHash.cs" /> diff --git a/VectoCore/VectoCore/InputData/FileIO/JSON/BusAuxiliaryInputData.cs b/VectoCore/VectoCore/InputData/FileIO/JSON/BusAuxiliaryInputData.cs index 258f23b35e9153b7d95cf15338c3835bcd6a17cf..c064f0b7cdd60b9b70123cf8e8feb76d488d94a5 100644 --- a/VectoCore/VectoCore/InputData/FileIO/JSON/BusAuxiliaryInputData.cs +++ b/VectoCore/VectoCore/InputData/FileIO/JSON/BusAuxiliaryInputData.cs @@ -31,9 +31,9 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON var env = string.IsNullOrWhiteSpace(data["EnvironmentalConditions"]?.ToString()) ? DeclarationData.BusAuxiliaries.DefaultEnvironmentalConditions : EnvironmentalContidionsMapReader.ReadFile(data["EnvironmentalConditions"].ToString()); - var techList = string.IsNullOrWhiteSpace(data["SSMTechologies"]?.ToString()) - ? DeclarationData.BusAuxiliaries.SSMTechnologyList - : SSMTechnologiesReader.ReadFromFile(data["SSMTechologies"].ToString()); + //var techList = string.IsNullOrWhiteSpace(data["SSMTechologies"]?.ToString()) + // ? DeclarationData.BusAuxiliaries.SSMTechnologyList + // : SSMTechnologiesReader.ReadFromFile(data["SSMTechologies"].ToString()); var actuations = new Actuations() { Braking = data["Actuations"]?.GetEx<int>("Brakes") ?? 0, ParkBrakeAndDoors = data["Actuations"]?.GetEx<int>("Park brake + 2 doors") ?? 0, @@ -44,11 +44,10 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON var ssm = string.IsNullOrWhiteSpace(data["SSMFilePath"]?.ToString()) ? new SSMInputs("", FuelData.Diesel) { EnvironmentalConditionsMap = env, - Technologies = techList + Technologies = new TechnologyBenefits() } : SSMInputData.ReadFile( - Path.Combine(baseDir, data["SSMFilePath"].ToString()), vehicleData, env, - techList); + Path.Combine(baseDir, data["SSMFilePath"].ToString()), vehicleData, env); return new AuxiliaryConfig( ) { ElectricalUserInputsConfig = ec, PneumaticAuxillariesConfig = pac, diff --git a/VectoCore/VectoCore/InputData/FileIO/JSON/SSMInputData.cs b/VectoCore/VectoCore/InputData/FileIO/JSON/SSMInputData.cs index 27e57c0bd17b2435b889b6e24dd9632f83b759d1..f35378f52f01f73be005b9e248183afa5c75516f 100644 --- a/VectoCore/VectoCore/InputData/FileIO/JSON/SSMInputData.cs +++ b/VectoCore/VectoCore/InputData/FileIO/JSON/SSMInputData.cs @@ -18,7 +18,7 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON return retVal; } - public static ISSMInputs ReadFile(string fileName, IVehicleData vehicleData, IEnvironmentalConditionsMap env, ISSMTechnologies technologies) + public static ISSMInputs ReadFile(string fileName, IVehicleData vehicleData, IEnvironmentalConditionsMap env) { var json = JSONInputDataFactory.ReadFile(fileName); var body = (JObject)json["Body"]; @@ -26,7 +26,7 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON var retVal = Create(body, vehicleData, fileName); retVal.EnvironmentalConditionsMap = env; - retVal.Technologies = technologies; + //retVal.Technologies = technologies; return retVal; } @@ -69,6 +69,11 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON retVal.FuelEnergyToHeatToCoolant = genInput.GetEx<double>("AH_FuelEnergyToHeatToCoolant"); retVal.CoolantHeatTransferredToAirCabinHeater = genInput.GetEx<double>("AH_CoolantHeatTransferredToAirCabinHeater"); + retVal.Technologies = new TechnologyBenefits() { + // TODO: MQ 2020-01-27 read from file! + //CValueVariation = + }; + return retVal; } } diff --git a/VectoCore/VectoCore/InputData/Reader/ComponentData/SSMTechnologiesReader.cs b/VectoCore/VectoCore/InputData/Reader/ComponentData/SSMTechnologiesReader.cs index aa3c3ec48b33a1b8d7f637c119bab0f01d60af24..6e9cc83ea5d9a43a5fdfc56f7604a1e2a1eca2b4 100644 --- a/VectoCore/VectoCore/InputData/Reader/ComponentData/SSMTechnologiesReader.cs +++ b/VectoCore/VectoCore/InputData/Reader/ComponentData/SSMTechnologiesReader.cs @@ -5,6 +5,7 @@ using System.Linq; using TUGraz.VectoCommon.BusAuxiliaries; using TUGraz.VectoCommon.Exceptions; using TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC; +using TUGraz.VectoCore.Models.Declaration; using TUGraz.VectoCore.Utils; namespace TUGraz.VectoCore.InputData.Reader.ComponentData @@ -20,17 +21,17 @@ namespace TUGraz.VectoCore.InputData.Reader.ComponentData Fields.ActiveVC, Fields.ActiveVH, Fields.ActiveVV }; - public static ISSMTechnologies ReadFromFile(string fileName) + public static List<SSMTechnology> ReadFromFile(string fileName) { return Create(VectoCSVFile.Read(fileName), fileName); } - public static ISSMTechnologies ReadFromStream(Stream str) + public static List<SSMTechnology> ReadFromStream(Stream str) { return Create(VectoCSVFile.ReadStream(str), null); } - public static ISSMTechnologies Create(DataTable data, string fileName) + public static List<SSMTechnology> Create(DataTable data, string fileName) { if (!HeaderIsValid(data.Columns)) { throw new VectoException("invalid header for techlist file. expected: {0} got: {1}", @@ -38,7 +39,7 @@ namespace TUGraz.VectoCore.InputData.Reader.ComponentData ); } - var retVal = new List<ISSMTechnology>(); + var retVal = new List<SSMTechnology>(); foreach (DataRow row in data.Rows) { retVal.Add(new SSMTechnology() { @@ -59,7 +60,7 @@ namespace TUGraz.VectoCore.InputData.Reader.ComponentData }); } - return new TechBenefitLines(retVal, fileName); + return retVal; } protected static bool HeaderIsValid(DataColumnCollection columns) diff --git a/VectoCore/VectoCore/InputData/Reader/DataObjectAdapter/DeclarationDataAdapterPrimaryBus.cs b/VectoCore/VectoCore/InputData/Reader/DataObjectAdapter/DeclarationDataAdapterPrimaryBus.cs index eaf8717bd8853d95e323d0aa72725bf4c1cd5400..852000aa9de2b4b2dc2c271bdb0ba78812b06a59 100644 --- a/VectoCore/VectoCore/InputData/Reader/DataObjectAdapter/DeclarationDataAdapterPrimaryBus.cs +++ b/VectoCore/VectoCore/InputData/Reader/DataObjectAdapter/DeclarationDataAdapterPrimaryBus.cs @@ -253,7 +253,8 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter var hvacBusheight = DeclarationData.BusAuxiliaries.CalculateInternalHeight(mission.VehicleHeight); var coolingPower = CalculateMaxCoolingPower(vehicleData, mission); var retVal = new SSMInputs(null, heatingFuel) { - Technologies = GetSSMTechnologyBenefits(busAuxInputData), + SSMDisabled = false, + Technologies = GetSSMTechnologyBenefits(busAuxInputData, mission.BusParameter.FloorType), DefaultConditions = new EnvironmentalConditionMapEntry( Constants.BusAuxiliaries.SteadyStateModel.DefaultTemperature, Constants.BusAuxiliaries.SteadyStateModel.DefaultSolar, @@ -301,12 +302,10 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter return retVal; } - private ISSMTechnologies GetSSMTechnologyBenefits(IBusAuxiliariesDeclarationData inputData) + private ISSMTechnologyBenefits GetSSMTechnologyBenefits(IBusAuxiliariesDeclarationData inputData, FloorType floorType) { - var benefits = DeclarationData.BusAuxiliaries.SSMTechnologyList; - - var onVehicle = new List<ISSMTechnology>(); - foreach (var item in benefits.Items) { + var onVehicle = new List<SSMTechnology>(); + foreach (var item in DeclarationData.BusAuxiliaries.SSMTechnologyList) { if (item.BenefitName.Equals("Adjustable coolant thermostat", StringComparison.InvariantCultureIgnoreCase) && inputData.HVACAux.AdjustableCoolantThermostat) { onVehicle.Add(item); @@ -318,7 +317,34 @@ namespace TUGraz.VectoCore.InputData.Reader.DataObjectAdapter } } - return new TechBenefitLines(onVehicle, "DeclarationDefaults"); + var retVal = new TechnologyBenefits(); + + switch (floorType) { + case FloorType.LowFloor: + retVal.CValueVariation = onVehicle.Sum(x => x.LowFloorC); + retVal.HValueVariation = onVehicle.Sum(x => x.LowFloorH); + retVal.VCValueVariation = onVehicle.Sum(x => x.ActiveVC ? x.LowFloorV : 0); + retVal.VHValueVariation = onVehicle.Sum(x => x.ActiveVH ? x.LowFloorV : 0); + retVal.VVValueVariation = onVehicle.Sum(x => x.ActiveVV ? x.LowFloorV : 0); + break; + case FloorType.HighFloor: + retVal.CValueVariation = onVehicle.Sum(x => x.RaisedFloorC); + retVal.HValueVariation = onVehicle.Sum(x => x.RaisedFloorH); + retVal.VCValueVariation = onVehicle.Sum(x => x.ActiveVC ? x.RaisedFloorV : 0); + retVal.VHValueVariation = onVehicle.Sum(x => x.ActiveVH ? x.RaisedFloorV : 0); + retVal.VVValueVariation = onVehicle.Sum(x => x.ActiveVV ? x.RaisedFloorV : 0); + break; + case FloorType.SemiLowFloor: + retVal.CValueVariation = onVehicle.Sum(x => x.SemiLowFloorC); + retVal.HValueVariation = onVehicle.Sum(x => x.SemiLowFloorH); + retVal.VCValueVariation = onVehicle.Sum(x => x.ActiveVC ? x.SemiLowFloorV : 0); + retVal.VHValueVariation = onVehicle.Sum(x => x.ActiveVH ? x.SemiLowFloorV : 0); + retVal.VVValueVariation = onVehicle.Sum(x => x.ActiveVV ? x.SemiLowFloorV : 0); + break; + } + + + return retVal; } diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMCalculate.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMCalculate.cs index db784ad8433e02c28904704d34fe185bd36054a3..0886150191f0caa48fd7f316d7a5fbd0855bc8f4 100644 --- a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMCalculate.cs +++ b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMCalculate.cs @@ -458,30 +458,30 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC var catLength = 15; var unitLength = 15; var firstValuePos = nameLength + catLength + unitLength + 2; - string cat; - string name; + //string cat; + //string name; sb.AppendLine(string.Format(new string(' ', firstValuePos) + "H{0}VH{0}VV{0}VC{0}C{0}", vbTab)); - foreach (var line in ssmTOOL.TechList.TechLines) { - { - var withBlock = line; + //foreach (var line in ssmTOOL.TechList.TechLines) { + // { + // var withBlock = line; - var extraNameSpaces = nameLength - withBlock.BenefitName.Length; - var extraCatSpaces = catLength - withBlock.Category.Length; + // var extraNameSpaces = nameLength - withBlock.BenefitName.Length; + // var extraCatSpaces = catLength - withBlock.Category.Length; - cat = line.Category.Substring(0, Math.Min(line.Category.Length, catLength)) + - new string(' ', extraCatSpaces < 0 ? 0 : extraCatSpaces).Replace(" ", "."); - name = line.BenefitName.Substring(0, Math.Min(line.BenefitName.Length, nameLength)) + - new string(' ', extraNameSpaces < 0 ? 0 : extraNameSpaces).Replace(" ", "."); + // cat = line.Category.Substring(0, Math.Min(line.Category.Length, catLength)) + + // new string(' ', extraCatSpaces < 0 ? 0 : extraCatSpaces).Replace(" ", "."); + // name = line.BenefitName.Substring(0, Math.Min(line.BenefitName.Length, nameLength)) + + // new string(' ', extraNameSpaces < 0 ? 0 : extraNameSpaces).Replace(" ", "."); - sb.AppendLine( - string.Format( - cat + name + " {0}{1}{0}{2}{0}{3}{0}{4}{0}{5}", vbTab, withBlock.H.ToString("0.000"), - withBlock.VH.ToString("0.000"), withBlock.VV.ToString("0.000"), withBlock.VC.ToString("0.000"), - withBlock.C.ToString("0.000"))); - } - } + // sb.AppendLine( + // string.Format( + // cat + name + " {0}{1}{0}{2}{0}{3}{0}{4}{0}{5}", vbTab, withBlock.H.ToString("0.000"), + // withBlock.VH.ToString("0.000"), withBlock.VV.ToString("0.000"), withBlock.VC.ToString("0.000"), + // withBlock.C.ToString("0.000"))); + // } + //} sb.AppendLine(""); sb.AppendLine("TechList Totals"); @@ -567,7 +567,7 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC } private Watt CalculateElectricalWAdjusted( - ISSMInputs genInputs, ISSMTechList tecList, IEnvironmentalConditionsMapEntry env) + ISSMInputs genInputs, ISSMTechnologyBenefits tecList, IEnvironmentalConditionsMapEntry env) { // =(MIN((H94*(1-H100)),C54*1000)/C59)+(I93*(1-I99))+(I94*(1-I100))+(I95*(1-I101)) @@ -589,7 +589,7 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC return ElectricalWAdjusted * env.Weighting; } - private Watt CalculateMechanicalWBaseAdjusted(ISSMInputs genInputs, ISSMTechList tecList, IEnvironmentalConditionsMapEntry env) + private Watt CalculateMechanicalWBaseAdjusted(ISSMInputs genInputs, ISSMTechnologyBenefits tecList, IEnvironmentalConditionsMapEntry env) { // =(MIN((F94*(1-F100)),C54*1000)/C59) @@ -604,7 +604,7 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC } private KilogramPerSecond CalculateFuelLPerHBaseAdjusted( - ISSMInputs genInputs, ISSMTechList tecList, IEnvironmentalConditionsMapEntry env) + ISSMInputs genInputs, ISSMTechnologyBenefits tecList, IEnvironmentalConditionsMapEntry env) { // =MIN(ABS(IF(AND(M89<0,M90<0),VLOOKUP(MAX(M89:M90),M89:P90,4),0)/1000),C71)/C37*(1/(C39*C38)) diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMInputs.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMInputs.cs index 22e17d65f2e5f5c127a0130a12ebe1604af254a7..9252d09bbb9f8178ce43be0bd7c0fd413234ce21 100644 --- a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMInputs.cs +++ b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMInputs.cs @@ -377,7 +377,7 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC get { return this; } } - public ISSMTechnologies Technologies { get; set; } + public ISSMTechnologyBenefits Technologies { get; set; } #endregion diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTOOL.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTOOL.cs index b72931d9633e69ff9c1e24f8f029ec7e6c8a4c63..44b41eb34f8446007c3ec1f7960e63e8d3fef3d5 100644 --- a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTOOL.cs +++ b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTOOL.cs @@ -18,9 +18,8 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC public SSMTOOL(ISSMInputs ssmInput) { - SSMInputs = ssmInput; //new SSMInputs(Path.GetDirectoryName(filePath)); - TechList = new SSMTechList(SSMInputs.BusParameters.BusFloorType); - TechList.TechLines = ssmInput.Technologies.Items; + SSMInputs = ssmInput; + TechList = ssmInput.Technologies; Calculate = new SSMCalculate(this); EngineWasteHeatkW = 0.SI<Watt>(); @@ -30,7 +29,7 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC public ISSMBoundaryConditions BoundaryConditions { get; set; } - public ISSMTechList TechList { get; set; } + public ISSMTechnologyBenefits TechList { get; set; } public ISSMCalculate Calculate { get; set; } public bool SSMDisabled { get { return SSMInputs.SSMDisabled; } } public IHVACConstants HVACConstants { get; set; } @@ -92,82 +91,8 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC public Watt EngineWasteHeatkW { get; protected set; } - // Persistance Functions - - // Comparison - public bool IsEqualTo(ISSMTOOL source) - { - - // In this methods we only want to compare the non Static , non readonly public properties of - // The class's General, User Inputs and Tech Benefit members. - - return compareGenUserInputs(source) && compareTechListBenefitLines(source); - } - - private bool compareGenUserInputs(ISSMTOOL source) - { - var src = (SSMTOOL)source; - - var properties = SSMInputs.GetType().GetProperties(); - - foreach (var prop in properties) { - - // If Not prop.GetAccessors.IsReadOnly Then - if (prop.CanWrite) { - var v1 = prop.GetValue(SSMInputs, null); - var v2 = prop.GetValue(src.SSMInputs, null); - if (v1 == null ^ v2 == null) { - return false; - } - if (v1 != null && !v1.Equals(v2)) { - return false; - } - } - } - - return true; - } - - private bool compareTechListBenefitLines(ISSMTOOL source) - { - var src = (SSMTOOL)source; - - // Equal numbers of lines check - if (TechList.TechLines.Count != src.TechList.TechLines.Count) - return false; - - foreach (var tl in TechList.TechLines.OrderBy(o => o.Category).ThenBy(n => n.BenefitName)) { - - // First Check line exists in other - if (src.TechList.TechLines.Where(w => w.BenefitName == tl.BenefitName && w.Category == tl.Category).Count() != 1) - return false; - else { - - // check are equal - - var testLine = src.TechList.TechLines.First(w => w.BenefitName == tl.BenefitName && w.Category == tl.Category); - - if (!testLine.IsEqualTo(tl)) - return false; - } - } - - // All Looks OK - return true; - } - - // Overrides - public override string ToString() - { - var sb = new StringBuilder(); - - sb.AppendLine(Calculate.ToString()); - - - return sb.ToString(); - } - + // Dynamicly Get Fuel having re-adjusted Engine Heat Waste, this was originally supposed to be Solid State. Late adjustment request 24/3/2015 public KilogramPerSecond FuelPerHBaseAsjusted(Watt AverageUseableEngineWasteHeatKW) { diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTechList.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTechList.cs deleted file mode 100644 index d2e6ed3e0c80ed2db477e258e34329e00e93b208..0000000000000000000000000000000000000000 --- a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTechList.cs +++ /dev/null @@ -1,99 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using TUGraz.VectoCommon.BusAuxiliaries; - -namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC -{ - // Used By SSMTOOL Class. - public class SSMTechList : ISSMTechList - { - private readonly List<ISSMTechnology> _techLines; - private FloorType _busFloorType; - - // Constructors - public SSMTechList(FloorType busFloorType) - { - _techLines = new List<ISSMTechnology>(); - BusFloorType = busFloorType; - } - - public IReadOnlyList<ISSMTechnology> TechLines - { - get { return _techLines; } - set { - _techLines.Clear(); - foreach (var item in value) { - if (TechLines.Any(w => w.Category == item.Category && w.BenefitName == item.BenefitName)) { - throw new ArgumentException("entry already exists"); - } - item.BusFloorType = BusFloorType; - _techLines.Add(item); - } - } - } - - public FloorType BusFloorType - { - get { return _busFloorType; } - set { - _busFloorType = value; - foreach (var entry in _techLines) { - entry.BusFloorType = BusFloorType; - } - } - } - - - - // Public Properties - Outputs Of Class - public double CValueVariation - { - get { - double a; - - a = TechLines.Sum(s => s.C); - - return a; - } - } - - - public double HValueVariation - { - get { - - // Dim a,b As double - return TechLines.Sum(s => s.H); - } - } - - - - public double VCValueVariation - { - get { - return TechLines.Sum(s => s.VC); // - VCValueVariationKW - } - } - - - public double VHValueVariation - { - get { - // Dim a,b As double - - return TechLines.Sum(s => s.VH); - } - } - - - public double VVValueVariation - { - get { - return TechLines.Sum(s => s.VV); - } - } - - } -} diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTechnology.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTechnology.cs deleted file mode 100644 index e46b0eef41a4049635879af67c31f59859c66f9d..0000000000000000000000000000000000000000 --- a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/SSMTechnology.cs +++ /dev/null @@ -1,262 +0,0 @@ -using System.Collections.Generic; -using TUGraz.VectoCommon.BusAuxiliaries; - -namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC -{ - - // Used by SSMTOOL Class, refer to original spreadsheet model - // Or PDF Model Document which articulates the same spreadsheet functionality - // But within the context of the Vecto interpretation of the same. - - public class TechBenefitLines : ISSMTechnologies - { - #region Implementation of ITechlistBenefitLines - - public TechBenefitLines(IReadOnlyList<ISSMTechnology> items, string source) - { - Items = items; - Source = source; - } - - public IReadOnlyList<ISSMTechnology> Items { get; } - - public string Source { get; } - - #endregion - } - - public class SSMTechnology : ISSMTechnology - { - //private float _h, _vh, _vv, _vc, _c; - public FloorType BusFloorType { protected get; set; } - - //public string Units { get; set; } - public string Category { get; set; } - public string BenefitName { get; set; } - public double LowFloorH { get; set; } - public double LowFloorV { get; set; } - public double LowFloorC { get; set; } - - public double SemiLowFloorH { get; set; } - public double SemiLowFloorV { get; set; } - public double SemiLowFloorC { get; set; } - - public double RaisedFloorH { get; set; } - public double RaisedFloorV { get; set; } - public double RaisedFloorC { get; set; } - - public bool OnVehicle { get { return true; } } - public bool ActiveVH { get; set; } - public bool ActiveVV { get; set; } - public bool ActiveVC { get; set; } - - public double H - { - get { - var returnValue = 0.0; - - // =IF($M49=0,0,IF(AND($M49=1,'INPUT & RESULTS SHEET'!$D$6="low floor"),'TECH LIST INPUT'!D49, IF(AND($M49=1,'INPUT & RESULTS SHEET'!$D$6="semi low floor"),'TECH LIST INPUT'!G49,'TECH LIST INPUT'!J49))) - if (!OnVehicle) { - return returnValue; - } - - switch (BusFloorType) { - case FloorType.LowFloor: return LowFloorH; - case FloorType.SemiLowFloor: return SemiLowFloorH; - case FloorType.HighFloor: return RaisedFloorH; - default: return returnValue; - } - } - } - - public double VH - { - get { - const double floorValue = 0; - - if (!OnVehicle) { - return floorValue; - } - - // Active - if (!ActiveVH) { - return 0; - } - - // Get floor value - switch (BusFloorType) { - case FloorType.LowFloor: return LowFloorV; - case FloorType.SemiLowFloor: return SemiLowFloorV; - case FloorType.HighFloor: return RaisedFloorV; - default: return floorValue; - } - } - } - - public double VV - { - get { - var floorValue = 0.0; - - if (!OnVehicle) { - return floorValue; - } - - // Active - if (!ActiveVV) { - return floorValue; - } - - // Get floor value - switch (BusFloorType) { - case FloorType.LowFloor: return LowFloorV; - case FloorType.SemiLowFloor: return SemiLowFloorV; - case FloorType.HighFloor: return RaisedFloorV; - default: return floorValue; - } - } - } - - public double VC - { - get { - var floorValue = 0.0; - - if (!OnVehicle) { - return floorValue; - } - - // Active - if (!ActiveVC) { - return floorValue; - } - - // Get floor value - switch (BusFloorType) { - case FloorType.LowFloor: return LowFloorV; - case FloorType.SemiLowFloor: return SemiLowFloorV; - case FloorType.HighFloor: return RaisedFloorV; - default: return floorValue; - } - } - } - - public double C - { - get { - var returnValue = 0.0; - - if (!OnVehicle) - return returnValue; - - switch (BusFloorType) { - case FloorType.LowFloor: return LowFloorC; - case FloorType.SemiLowFloor: return SemiLowFloorC; - case FloorType.HighFloor: return RaisedFloorC; - default: return returnValue; - } - } - } - - public SSMTechnology() { } - - - - // Operator Overloads - public static bool operator ==(SSMTechnology op1, SSMTechnology op2) - { - if ((op1.Category == op2.Category && op1.BenefitName == op2.BenefitName && op1.ActiveVC == op2.ActiveVC && - op1.ActiveVH == op2.ActiveVH && op1.ActiveVV == op2.ActiveVV && /*op1.LineType == op2.LineType &&*/ - op1.LowFloorC == op2.LowFloorC && op1.LowFloorV == op2.LowFloorV && op1.LowFloorH == op2.LowFloorH && - op1.SemiLowFloorC == op2.SemiLowFloorC && op1.SemiLowFloorH == op2.SemiLowFloorH && - op1.SemiLowFloorV == op2.SemiLowFloorV && op1.RaisedFloorC == op2.RaisedFloorC && - op1.RaisedFloorH == op2.RaisedFloorH && op1.RaisedFloorV == op2.RaisedFloorV && op1.OnVehicle == op2.OnVehicle - /*&& op1.Units == op2.Units*/)) { - return true; - } - - return false; - } - - public static bool operator !=(SSMTechnology op1, SSMTechnology op2) - { - if ((op1.Category != op2.Category || op1.BenefitName != op2.BenefitName || op1.ActiveVC != op2.ActiveVC || - op1.ActiveVH != op2.ActiveVH || op1.ActiveVV != op2.ActiveVV || /*op1.LineType != op2.LineType ||*/ - op1.LowFloorC != op2.LowFloorC || op1.LowFloorV != op2.LowFloorV || op1.LowFloorH != op2.LowFloorH || - op1.SemiLowFloorC != op2.SemiLowFloorC || op1.SemiLowFloorH != op2.SemiLowFloorH || - op1.SemiLowFloorV != op2.SemiLowFloorV || op1.RaisedFloorC != op2.RaisedFloorC || - op1.RaisedFloorH != op2.RaisedFloorH || op1.RaisedFloorV != op2.RaisedFloorV || op1.OnVehicle != op2.OnVehicle /*|| - op1.Units != op2.Units*/)) { - return true; - } - - return false; - } - - #region Equality members - - protected bool Equals(SSMTechnology other) - { - return Equals(BusFloorType, other.BusFloorType) && /*string.Equals(Units, other.Units) &&*/ - string.Equals(Category, other.Category) && string.Equals(BenefitName, other.BenefitName) && - LowFloorH.Equals(other.LowFloorH) && LowFloorV.Equals(other.LowFloorV) && LowFloorC.Equals(other.LowFloorC) && - SemiLowFloorH.Equals(other.SemiLowFloorH) && SemiLowFloorV.Equals(other.SemiLowFloorV) && - SemiLowFloorC.Equals(other.SemiLowFloorC) && RaisedFloorH.Equals(other.RaisedFloorH) && - RaisedFloorV.Equals(other.RaisedFloorV) && RaisedFloorC.Equals(other.RaisedFloorC) && - OnVehicle == other.OnVehicle && ActiveVH == other.ActiveVH && ActiveVV == other.ActiveVV && - ActiveVC == other.ActiveVC /* && LineType == other.LineType*/; - } - - public override bool Equals(object obj) - { - if (ReferenceEquals(null, obj)) { - return false; - } - if (ReferenceEquals(this, obj)) { - return true; - } - if (obj.GetType() != GetType()) { - return false; - } - - return Equals((SSMTechnology)obj); - } - - public override int GetHashCode() - { - unchecked { - var hashCode = BusFloorType.GetHashCode(); - //hashCode = (hashCode * 397) ^ (Units != null ? Units.GetHashCode() : 0); - hashCode = (hashCode * 397) ^ (Category != null ? Category.GetHashCode() : 0); - hashCode = (hashCode * 397) ^ (BenefitName != null ? BenefitName.GetHashCode() : 0); - hashCode = (hashCode * 397) ^ LowFloorH.GetHashCode(); - hashCode = (hashCode * 397) ^ LowFloorV.GetHashCode(); - hashCode = (hashCode * 397) ^ LowFloorC.GetHashCode(); - hashCode = (hashCode * 397) ^ SemiLowFloorH.GetHashCode(); - hashCode = (hashCode * 397) ^ SemiLowFloorV.GetHashCode(); - hashCode = (hashCode * 397) ^ SemiLowFloorC.GetHashCode(); - hashCode = (hashCode * 397) ^ RaisedFloorH.GetHashCode(); - hashCode = (hashCode * 397) ^ RaisedFloorV.GetHashCode(); - hashCode = (hashCode * 397) ^ RaisedFloorC.GetHashCode(); - hashCode = (hashCode * 397) ^ OnVehicle.GetHashCode(); - hashCode = (hashCode * 397) ^ ActiveVH.GetHashCode(); - hashCode = (hashCode * 397) ^ ActiveVV.GetHashCode(); - hashCode = (hashCode * 397) ^ ActiveVC.GetHashCode(); - //hashCode = (hashCode * 397) ^ (int)LineType; - return hashCode; - } - } - - #endregion - - public bool IsEqualTo(ISSMTechnology source) - { - var mySource = (SSMTechnology)source; - if (ReferenceEquals(mySource, null)) { - return false; - } - - return this == mySource; - } - } -} diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/TechnologyBenefits.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/TechnologyBenefits.cs new file mode 100644 index 0000000000000000000000000000000000000000..d65d2cda01f347aac4ced1a426bdd38aa1548123 --- /dev/null +++ b/VectoCore/VectoCore/Models/BusAuxiliaries/DownstreamModules/Impl/HVAC/TechnologyBenefits.cs @@ -0,0 +1,16 @@ +using TUGraz.VectoCommon.BusAuxiliaries; + +namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.HVAC { + public class TechnologyBenefits : ISSMTechnologyBenefits + { + #region Implementation of ISSMTechList + + public double HValueVariation { get; internal set; } + public double VHValueVariation { get; internal set; } + public double VVValueVariation { get; internal set; } + public double VCValueVariation { get; internal set; } + public double CValueVariation { get; internal set; } + + #endregion + } +} \ No newline at end of file diff --git a/VectoCore/VectoCore/Models/BusAuxiliaries/Interfaces/DownstreamModules/HVAC/ISSMTOOL.cs b/VectoCore/VectoCore/Models/BusAuxiliaries/Interfaces/DownstreamModules/HVAC/ISSMTOOL.cs index e60149fdfc3e4ad6c5bccea4b4da507d8d16ad81..11b00e630377fd5c82eb4e314ec61473a55fe42f 100644 --- a/VectoCore/VectoCore/Models/BusAuxiliaries/Interfaces/DownstreamModules/HVAC/ISSMTOOL.cs +++ b/VectoCore/VectoCore/Models/BusAuxiliaries/Interfaces/DownstreamModules/HVAC/ISSMTOOL.cs @@ -5,7 +5,7 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.HV public interface ISSMTOOL { ISSMInputs SSMInputs { get; } - ISSMTechList TechList { get; } + ISSMTechnologyBenefits TechList { get; } ISSMCalculate Calculate { get; } bool SSMDisabled { get; } IHVACConstants HVACConstants { get; set; } @@ -20,8 +20,6 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.Interfaces.DownstreamModules.HV Watt EngineWasteHeatkW { get; } - - bool IsEqualTo(ISSMTOOL source); /// <summary> /// This alters the waste heat and returns an adjusted fueling value diff --git a/VectoCore/VectoCore/Models/Declaration/DeclarationData.cs b/VectoCore/VectoCore/Models/Declaration/DeclarationData.cs index 9a1569705a867d1f407e7986d806b11e9fafc664..8fddcc710c016f4714d7603c1b8c29dcbdbdf8d4 100644 --- a/VectoCore/VectoCore/Models/Declaration/DeclarationData.cs +++ b/VectoCore/VectoCore/Models/Declaration/DeclarationData.cs @@ -144,7 +144,7 @@ namespace TUGraz.VectoCore.Models.Declaration private static IActuationsMap actuationsMap; //private static PneumaticsAuxilliariesConfig pneumaticAuxConfig; - private static ISSMTechnologies ssmTechnologies; + private static List<SSMTechnology> ssmTechnologies; //public static ISSMInputs SSMDefaultValues @@ -159,7 +159,7 @@ namespace TUGraz.VectoCore.Models.Declaration public static BusAlternatorTechnologies AlternatorTechnologies = new BusAlternatorTechnologies(); private static HVACCoolingPower hvacMaxCoolingPower; - public static ISSMTechnologies SSMTechnologyList + public static List<SSMTechnology> SSMTechnologyList { get { return ssmTechnologies ?? (ssmTechnologies = SSMTechnologiesReader.ReadFromStream( diff --git a/VectoCore/VectoCore/Models/Declaration/SSMTechnology.cs b/VectoCore/VectoCore/Models/Declaration/SSMTechnology.cs new file mode 100644 index 0000000000000000000000000000000000000000..6869f4fe897b290351a101828ae5137f39fac92f --- /dev/null +++ b/VectoCore/VectoCore/Models/Declaration/SSMTechnology.cs @@ -0,0 +1,29 @@ +namespace TUGraz.VectoCore.Models.Declaration +{ + + public class SSMTechnology + { + public string Category { get; set; } + public string BenefitName { get; set; } + + public double LowFloorH { get; set; } + public double LowFloorV { get; set; } + public double LowFloorC { get; set; } + + public double SemiLowFloorH { get; set; } + public double SemiLowFloorV { get; set; } + public double SemiLowFloorC { get; set; } + + public double RaisedFloorH { get; set; } + public double RaisedFloorV { get; set; } + public double RaisedFloorC { get; set; } + + + public bool ActiveVH { get; set; } + public bool ActiveVV { get; set; } + public bool ActiveVC { get; set; } + + + + } +} diff --git a/VectoCore/VectoCore/OutputData/FileIO/BusAuxWriter.cs b/VectoCore/VectoCore/OutputData/FileIO/BusAuxWriter.cs index 2481db5247aed410891374db2c62fc1d9d19aaeb..9bec902633bf0261162abe3e47cf7afcf3072db6 100644 --- a/VectoCore/VectoCore/OutputData/FileIO/BusAuxWriter.cs +++ b/VectoCore/VectoCore/OutputData/FileIO/BusAuxWriter.cs @@ -30,9 +30,16 @@ namespace TUGraz.VectoCore.OutputData.FileIO body["EnvironmentalConditions"] = string.IsNullOrWhiteSpace(auxCfg.SSMInputs.EnvironmentalConditions.Source) ? "" : JSONFileWriter.GetRelativePath(auxCfg.SSMInputs.EnvironmentalConditions.Source, basePath); - body["SSMTechologies"] = string.IsNullOrWhiteSpace(auxCfg.SSMInputs.Technologies.Source) - ? "" - : JSONFileWriter.GetRelativePath(auxCfg.SSMInputs.Technologies.Source, basePath); + body["SSMTechologyBenefits"] = new Dictionary<string, object>() { + { "Heating", auxCfg.SSMInputs.Technologies.HValueVariation}, + { "Cooling", auxCfg.SSMInputs.Technologies.CValueVariation }, + { "Ventilation", auxCfg.SSMInputs.Technologies.VVValueVariation }, + { "VentilationHeating", auxCfg.SSMInputs.Technologies.VHValueVariation}, + { "VentilationCooling", auxCfg.SSMInputs.Technologies.VCValueVariation} + }; + //string.IsNullOrWhiteSpace(auxCfg.SSMInputs.Technologies.Source) + //? "" + //: JSONFileWriter.GetRelativePath(auxCfg.SSMInputs.Technologies.Source, basePath); body["Actuations"] = new Dictionary<string, object>() { {"Brakes", auxCfg.Actuations.Braking }, {"Park brake + 2 doors", auxCfg.Actuations.ParkBrakeAndDoors }, @@ -158,7 +165,7 @@ namespace TUGraz.VectoCore.OutputData.FileIO var body = new Dictionary<string, object>(); body["SSMDisabled"] = ssmInput.SSMDisabled; body["SSMInputs"] = SaveGenInputs(ssmInput); - body["TechList"] = SaveTechlist(ssmInput); + //body["TechList"] = SaveTechlist(ssmInput); JSONInputDataFactory.WriteFile(JToken.FromObject(new Dictionary<string, object>() { { "Header", "AHSM" }, { "Body", body } }), filePath); @@ -200,83 +207,5 @@ namespace TUGraz.VectoCore.OutputData.FileIO return retVal; } - - private static List<object> SaveTechlist(ISSMInputs ssmInputs) - { - var retVal = new List<object>(); - - foreach (var line in ssmInputs.Technologies.Items) { - var tmp = new Dictionary<string, object>(); - tmp["Category"] = line.Category; - tmp["BenefitName"] = line.BenefitName; - tmp["LowFloorH"] = line.LowFloorH; - tmp["LowFloorV"] = line.LowFloorV; - tmp["LowFloorC"] = line.LowFloorC; - tmp["SemiLowFloorH"] = line.SemiLowFloorH; - tmp["SemiLowFloorV"] = line.SemiLowFloorV; - tmp["SemiLowFloorC"] = line.SemiLowFloorC; - tmp["RaisedFloorH"] = line.RaisedFloorH; - tmp["RaisedFloorV"] = line.RaisedFloorV; - tmp["RaisedFloorC"] = line.RaisedFloorC; - //tmp["OnVehicle"] = line.OnVehicle; - tmp["ActiveVH"] = line.ActiveVH; - tmp["ActiveVV"] = line.ActiveVV; - tmp["ActiveVC"] = line.ActiveVC; - retVal.Add(tmp); - } - - return retVal; - } - - //public bool Load(string filePath) - //{ - // var returnValue = true; - - // try { - // var json = JSONInputDataFactory.ReadFile(filePath); - // var body = (JObject)json["Body"]; - - // SSMDisabled = body.GetEx<bool>("SSMDisabled"); - // LoadGenInputs((JObject)body["SSMInputs"]); - // } catch (Exception) { - - // // Nothing to do except return false. - - // returnValue = false; - // } - - // return returnValue; - //} - - //private void LoadGenInputs(JObject genInput) - //{ - // SSMInputs.BoundaryConditions.GFactor = genInput.GetEx<double>("BC_GFactor"); - // SSMInputs.BoundaryConditions.PassengerBoundaryTemperature = genInput.GetEx<double>("BC_PassengerBoundaryTemperature").DegCelsiusToKelvin(); - // SSMInputs.BoundaryConditions.HeatingBoundaryTemperature = genInput.GetEx<double>("BC_HeatingBoundaryTemperature").DegCelsiusToKelvin(); - // SSMInputs.BoundaryConditions.CoolingBoundaryTemperature = genInput.GetEx<double>("BC_CoolingBoundaryTemperature").DegCelsiusToKelvin(); - // SSMInputs.BoundaryConditions.HighVentilation = genInput.GetEx<double>("BC_HighVentilation").SI(Unit.SI.Per.Hour).Cast<PerSecond>(); - // SSMInputs.BoundaryConditions.LowVentilation = genInput.GetEx<double>("BC_lowVentilation").SI(Unit.SI.Per.Hour).Cast<PerSecond>(); - // SSMInputs.BoundaryConditions.SpecificVentilationPower = genInput.GetEx<double>("BC_SpecificVentilationPower").SI(Unit.SI.Watt.Hour.Per.Cubic.Meter).Cast<JoulePerCubicMeter>(); - // SSMInputs.BoundaryConditions.AuxHeaterEfficiency = genInput.GetEx<double>("BC_AuxHeaterEfficiency"); - // SSMInputs.BoundaryConditions.GCVDieselOrHeatingOil = genInput.GetEx<double>("BC_GCVDieselOrHeatingOil").SI(Unit.SI.Kilo.Watt.Hour.Per.Kilo.Gramm).Cast<JoulePerKilogramm>(); - // SSMInputs.BoundaryConditions.MaxTemperatureDeltaForLowFloorBusses = genInput.GetEx<double>("BC_MaxTemperatureDeltaForLowFloorBusses").SI<Kelvin>(); - // SSMInputs.BoundaryConditions.MaxPossibleBenefitFromTechnologyList = genInput.GetEx<double>("BC_MaxPossibleBenefitFromTechnologyList"); - // SSMInputs.EnvironmentalConditions.EnviromentalTemperature = genInput.GetEx<double>("EC_EnviromentalTemperature").DegCelsiusToKelvin(); - // SSMInputs.EnvironmentalConditions.Solar = genInput.GetEx<double>("EC_Solar").SI<WattPerSquareMeter>(); - // SSMInputs.EnvironmentalConditions.EnviromentalConditions_BatchFile = genInput.GetEx<string>("EC_EnviromentalConditions_BatchFile"); - // SSMInputs.EnvironmentalConditions.EnviromentalConditions_BatchEnabled = genInput.GetEx<bool>("EC_EnviromentalConditions_BatchEnabled"); - // SSMInputs.ACSystem.CompressorType = genInput.GetEx<string>("AC_CompressorType"); - // SSMInputs.ACSystem.CompressorCapacity = genInput.GetEx<double>("AC_CompressorCapacitykW").SI(Unit.SI.Kilo.Watt).Cast<Watt>(); - // SSMInputs.Ventilation.VentilationOnDuringHeating = genInput.GetEx<bool>("VEN_VentilationOnDuringHeating"); - // SSMInputs.Ventilation.VentilationWhenBothHeatingAndACInactive = genInput.GetEx<bool>("VEN_VentilationWhenBothHeatingAndACInactive"); - // SSMInputs.Ventilation.VentilationDuringAC = genInput.GetEx<bool>("VEN_VentilationDuringAC"); - // SSMInputs.Ventilation.VentilationFlowSettingWhenHeatingAndACInactive = genInput.GetEx<string>("VEN_VentilationFlowSettingWhenHeatingAndACInactive"); - // SSMInputs.Ventilation.VentilationDuringHeating = genInput.GetEx<string>("VEN_VentilationDuringHeating"); - // SSMInputs.Ventilation.VentilationDuringCooling = genInput.GetEx<string>("VEN_VentilationDuringCooling"); - // SSMInputs.AuxHeater.EngineWasteHeatkW = genInput.GetEx<double>("AH_EngineWasteHeatkW").SI(Unit.SI.Kilo.Watt).Cast<Watt>(); - // SSMInputs.AuxHeater.FuelFiredHeaterkW = genInput.GetEx<double>("AH_FuelFiredHeaterkW").SI(Unit.SI.Kilo.Watt).Cast<Watt>(); - // SSMInputs.AuxHeater.FuelEnergyToHeatToCoolant = genInput.GetEx<double>("AH_FuelEnergyToHeatToCoolant"); - // SSMInputs.AuxHeater.CoolantHeatTransferredToAirCabinHeater = genInput.GetEx<double>("AH_CoolantHeatTransferredToAirCabinHeater"); - //} } } diff --git a/VectoCore/VectoCore/VectoCore.csproj b/VectoCore/VectoCore/VectoCore.csproj index 79b58f8c99fa9ce033e3638355bf1895c54e0ca6..d99fd59a8d6e30497dabf593f38b405581d4aeaa 100644 --- a/VectoCore/VectoCore/VectoCore.csproj +++ b/VectoCore/VectoCore/VectoCore.csproj @@ -271,6 +271,7 @@ <Compile Include="InputData\FileIO\XML\IXMLInputDataReader.cs" /> <Compile Include="InputData\FileIO\XML\XMLInputDataNinjectModule.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\Electrics\SimpleAlternator.cs" /> + <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\TechnologyBenefits.cs" /> <Compile Include="Models\Declaration\ADASCombination.cs" /> <Compile Include="InputData\Reader\ComponentData\AlternatorReader.cs" /> <Compile Include="InputData\Reader\ComponentData\CompressorMapReader.cs" /> @@ -304,9 +305,8 @@ <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\SSMCalculate.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\SSMInputs.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\SSMRun.cs" /> - <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\SSMTechList.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\SSMTOOL.cs" /> - <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\HVAC\SSMTechnology.cs" /> + <Compile Include="Models\Declaration\SSMTechnology.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\M06Impl.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\M07Impl.cs" /> <Compile Include="Models\BusAuxiliaries\DownstreamModules\Impl\M08Impl.cs" />