Code development platform for open source projects from the European Union institutions :large_blue_circle: EU Login authentication by SMS has been phased out. To see alternatives please check here

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

use factor method for completed bus calculations

parent d4322011
Branches
Tags
No related merge requests found
...@@ -209,12 +209,12 @@ namespace TUGraz.VectoCore.OutputData.XML { ...@@ -209,12 +209,12 @@ namespace TUGraz.VectoCore.OutputData.XML {
protected internal static double CalculateFactorMethodFactor(IResult primaryResult, protected internal static double CalculateFactorMethodFactor(IResult primaryResult,
XMLDeclarationReport.ResultEntry specific, XMLDeclarationReport.ResultEntry generic) XMLDeclarationReport.ResultEntry specific, XMLDeclarationReport.ResultEntry generic)
{ {
//return specific.EnergyConsumptionTotal.Value() / generic.EnergyConsumptionTotal.Value(); return specific.EnergyConsumptionTotal.Value() / generic.EnergyConsumptionTotal.Value();
var energyConsumptionPrimary = primaryResult.EnergyConsumption.Sum(x => x.Value); // var energyConsumptionPrimary = primaryResult.EnergyConsumption.Sum(x => x.Value);
var energyConsumptionCompeted = energyConsumptionPrimary + //var energyConsumptionCompeted = energyConsumptionPrimary +
specific.EnergyConsumptionTotal / specific.Distance - // specific.EnergyConsumptionTotal / specific.Distance -
generic.EnergyConsumptionTotal / generic.Distance; // generic.EnergyConsumptionTotal / generic.Distance;
return energyConsumptionCompeted / energyConsumptionPrimary; //return energyConsumptionCompeted / energyConsumptionPrimary;
} }
private XElement[] GetFuelConsumptionResults(XMLDeclarationReport.ResultEntry genericResult, XMLDeclarationReport.ResultEntry specificResult, IResult primaryResult) private XElement[] GetFuelConsumptionResults(XMLDeclarationReport.ResultEntry genericResult, XMLDeclarationReport.ResultEntry specificResult, IResult primaryResult)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment