Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit 1cb76128 authored by Markus QUARITSCH's avatar Markus QUARITSCH
Browse files

removing comments with old excel formulas

parent 2e006a7d
No related branches found
No related tags found
No related merge requests found
......@@ -32,15 +32,11 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.Pneumati
public NormLiter TotalAirDemandCalculation(IActuations actuations)
{
//'These calculation are done directly from formulae provided from a supplied spreadsheet.
//'* * Breaks * *
//'=IF(K10 = "yes", IF(COUNTBLANK(F33), G33, F33), IF(COUNTBLANK(F34), G34, F34)) * K16
var airConsumptionPerActuation = _pneumaticAuxillariesConfig.Braking * _vehicleMassKG;
var breaks = actuations.Braking * airConsumptionPerActuation ;
//'* * ParkBrakesBreakplus2Doors * *Park break +2 doors
//'=SUM(IF(K14 = "electric", 0, IF(COUNTBLANK(F36), G36, F36)), PRODUCT(K16 * IF(COUNTBLANK(F37), G37, F37)))
airConsumptionPerActuation = _pneumaticUserInputsConfig.Doors == ConsumerTechnology.Electrically
? 0.SI<NormLiter>()
: _pneumaticAuxillariesConfig.DoorOpening;
......@@ -48,20 +44,16 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.Pneumati
var parkBrakesplus2Doors = (actuations.ParkBrakeAndDoors * airConsumptionPerActuation);
//'* * Kneeling * *
//'=IF(COUNTBLANK(F35), G35, F35) * K11 * K16
airConsumptionPerActuation = _pneumaticAuxillariesConfig.BreakingWithKneeling *
_pneumaticUserInputsConfig.KneelingHeight * _vehicleMassKG;
var kneeling = (actuations.Kneeling * airConsumptionPerActuation);
//'* * AdBlue * *
// '=IF(K13 = "electric", 0, G39 * F54) - Supplied Spreadsheet
var adBlue = _pneumaticUserInputsConfig.AdBlueDosing == ConsumerTechnology.Electrically
? 0.SI<NormLiter>()
: _pneumaticAuxillariesConfig.AdBlueInjection * actuations.CycleTime;
//'* * Regeneration * *
// '=SUM(R6: R9) * IF(K9 = "yes", IF(COUNTBLANK(F41), G41, F41), IF(COUNTBLANK(F40), G40, F40)) - Supplied SpreadSheet
var regeneration = breaks + parkBrakesplus2Doors + kneeling + adBlue;
var regenFraction = _pneumaticUserInputsConfig.SmartRegeneration
? _pneumaticAuxillariesConfig.SmartRegenFractionTotalAirDemand
......@@ -69,13 +61,11 @@ namespace TUGraz.VectoCore.Models.BusAuxiliaries.DownstreamModules.Impl.Pneumati
regeneration = regeneration * regenFraction;
//'* * DeadVolBlowOuts * *
// '=IF(COUNTBLANK(F43), G43, F43) / (F54 / 60) - Supplied SpreadSheet
airConsumptionPerActuation = _pneumaticAuxillariesConfig.DeadVolume;
var deadVolBlowOuts = (airConsumptionPerActuation * _pneumaticAuxillariesConfig.DeadVolBlowOuts *
actuations.CycleTime).Cast<NormLiter>();
//'* * AirSuspension * *
// '=IF(K12 = "electrically", 0, G38 * F54) - Suplied Spreadsheet
var airSuspension = _pneumaticUserInputsConfig.AirSuspensionControl == ConsumerTechnology.Electrically
? 0.SI<NormLiter>()
: _pneumaticAuxillariesConfig.AirControlledSuspension * actuations.CycleTime;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment