From 1842f0119b17ed73bdac113dad3ed2eec2d8028a Mon Sep 17 00:00:00 2001 From: Stefanos Doumpoulakis <dubulak@gmail.com> Date: Tue, 11 Oct 2022 18:38:31 +0300 Subject: [PATCH] various fixes --- VectoCore/VectoCore/Configuration/Constants.cs | 4 ++-- .../VectoCore/InputData/Reader/DrivingCycleDataReader.cs | 5 ----- .../Models/SimulationComponent/Impl/EngineFanAuxiliary.cs | 2 +- .../VectoCoreTest/Models/Simulation/DrivingCycleTests.cs | 4 ---- 4 files changed, 3 insertions(+), 12 deletions(-) diff --git a/VectoCore/VectoCore/Configuration/Constants.cs b/VectoCore/VectoCore/Configuration/Constants.cs index e295f5132e..1cfb81011c 100644 --- a/VectoCore/VectoCore/Configuration/Constants.cs +++ b/VectoCore/VectoCore/Configuration/Constants.cs @@ -51,7 +51,7 @@ namespace TUGraz.VectoCore.Configuration public const string Prefix = "AUX_"; public const string PowerPrefix = "P_"; - public const double FanElectricToMechanicalEfficiency = 0.7; + public const double FanElectricToMechanicalEfficiency = 1.05; public static class IDs { @@ -332,7 +332,7 @@ namespace TUGraz.VectoCore.Configuration /// When the simulated (in VTP) positive engine work deviates more than this threshold /// from the measured positive energy of the vdri, a warning is issued. /// </summary> - public const double VTPEngineWorkDeviationThreshold = 0.01; + public const double VTPEngineWorkDeviationThreshold = 0.1; } public static class XML diff --git a/VectoCore/VectoCore/InputData/Reader/DrivingCycleDataReader.cs b/VectoCore/VectoCore/InputData/Reader/DrivingCycleDataReader.cs index b15b533525..244fb58799 100644 --- a/VectoCore/VectoCore/InputData/Reader/DrivingCycleDataReader.cs +++ b/VectoCore/VectoCore/InputData/Reader/DrivingCycleDataReader.cs @@ -940,11 +940,6 @@ namespace TUGraz.VectoCore.InputData.Reader return CheckColumns(header, allowedCols, requiredCols, throwExceptions, allowAux) && CheckComboColumns(header, new[] { Fields.AirSpeedRelativeToVehicle, Fields.WindYawAngle }, throwExceptions) && CheckMutuallyExclusiveColumns(header, new[] { Fields.FanSpeed, Fields.FanElectricalPower}, throwExceptions) - && CheckColumnsPredicatedOnAnother( - header, - new[] { Fields.CH4MassFlow, Fields.NMHCMassFlow }, - FuelTypeHelper.GetLabelsForNonGaseous("fc_"), - throwExceptions) && CheckColumnsPredicatedOnAnotherMissing( header, new[] { Fields.THCMassFlow }, diff --git a/VectoCore/VectoCore/Models/SimulationComponent/Impl/EngineFanAuxiliary.cs b/VectoCore/VectoCore/Models/SimulationComponent/Impl/EngineFanAuxiliary.cs index e7444fd163..2eb8804b7e 100644 --- a/VectoCore/VectoCore/Models/SimulationComponent/Impl/EngineFanAuxiliary.cs +++ b/VectoCore/VectoCore/Models/SimulationComponent/Impl/EngineFanAuxiliary.cs @@ -65,7 +65,7 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl public Watt PowerDemand(Watt fanElectricalPower) { - return fanElectricalPower / Constants.Auxiliaries.FanElectricToMechanicalEfficiency; + return fanElectricalPower * Constants.Auxiliaries.FanElectricToMechanicalEfficiency; } } diff --git a/VectoCore/VectoCoreTest/Models/Simulation/DrivingCycleTests.cs b/VectoCore/VectoCoreTest/Models/Simulation/DrivingCycleTests.cs index 2f88661ba0..78e6dac177 100644 --- a/VectoCore/VectoCoreTest/Models/Simulation/DrivingCycleTests.cs +++ b/VectoCore/VectoCoreTest/Models/Simulation/DrivingCycleTests.cs @@ -238,10 +238,6 @@ namespace TUGraz.VectoCore.Tests.Models.Simulation CycleType.MeasuredSpeedGear), TestCase("<t>,<v>,<n_eng>,<n_fan>,<tq_left>,<tq_right>,<n_wh_left>,<n_wh_right>,<fc_DIESEL CI>,<CO>,<NOx>,<THC>,<CO2>,<PN>", CycleType.VTP), - TestCase("<t>,<v>,<n_eng>,<n_fan>,<tq_left>,<tq_right>,<n_wh_left>,<n_wh_right>,<fc_NG CI>,<tq_eng>,<CH4>,<CO>,<NOx>,<THC>,<CO2>,<PN>", - CycleType.VTP), - TestCase("<t>,<v>,<n_eng>,<n_fan>,<tq_left>,<tq_right>,<n_wh_left>,<n_wh_right>,<fc_NG CI>,<tq_eng>,<NMHC>,<CO>,<NOx>,<THC>,<CO2>,<PN>", - CycleType.VTP), TestCase("<t>,<v>,<n_eng>,<n_fan>,<tq_left>,<tq_right>,<n_wh_left>,<n_wh_right>,<fc_NG CI>,<tq_eng>,<CH4>,<NMHC>,<CO>,<NOx>,<THC>,<CO2>", CycleType.VTP), TestCase("<t>,<v>,<n_eng>,<n_fan>,<tq_left>,<tq_right>,<n_wh_left>,<n_wh_right>,<fc_NG CI>,<tq_eng>,<CO>,<NOx>,<CO2>,<PN>", -- GitLab