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

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

if no thermal degrading is available in input data set it to high values (i.e....

if no thermal degrading is available in input data set it to high values (i.e. disable thermal buffer)
provide debugging info (toString method) on hybridstrategy response, hybridcontroller response and em-settings
parent 9bcfca63
No related branches found
No related tags found
No related merge requests found
......@@ -15,7 +15,7 @@ namespace TUGraz.VectoCommon.Models {
public PerSecond DeltaEngineSpeed { get; set; }
}
public class HybridStrategyResponse : IHybridStrategyResponse
public class HybridStrategyResponse : AbstractComponentResponse, IHybridStrategyResponse
{
public Dictionary<PowertrainPosition, NewtonMeter> MechanicalAssistPower;
public bool ShiftRequired { get; set; }
......@@ -62,7 +62,7 @@ namespace TUGraz.VectoCommon.Models {
return ToString().Equals(other.ToString(), StringComparison.InvariantCultureIgnoreCase);
}
public string ToString()
public override string ToString()
{
var setting = string.Join(", ", Setting.MechanicalAssistPower.Select(x => $"{x.Key}, {x.Value}"));
return $"{U}: {setting} {Score} G{Gear}";
......
......@@ -181,7 +181,7 @@ namespace TUGraz.VectoCommon.Models
HybridControllerResponse HybridController { get; set; }
}
public class HybridControllerResponse
public class HybridControllerResponse : AbstractComponentResponse
{
public HybridStrategyResponse StrategySettings { get; set; }
}
......
......@@ -53,7 +53,7 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON {
public Joule OverloadBuffer
{
get { return Body.GetValueOrDefault<double>("ThermalOverloadBuffer")?.SI(Unit.SI.Mega.Joule).Cast<Joule>() ?? 0.SI<Joule>(); }
get { return Body.GetValueOrDefault<double>("ThermalOverloadBuffer")?.SI(Unit.SI.Mega.Joule).Cast<Joule>() ?? 1e18.SI<Joule>(); }
}
public double OverloadRecoveryFactor
......@@ -66,7 +66,7 @@ namespace TUGraz.VectoCore.InputData.FileIO.JSON {
public Watt ContinuousPower
{
get { return Body.GetValueOrDefault<double>("ContinuousPower")?.SI<Watt>() ?? 0.SI<Watt>(); }
get { return Body.GetValueOrDefault<double>("ContinuousPower")?.SI<Watt>() ?? 1e12.SI<Watt>(); }
}
......
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