PhysicalConsumptionModel

public struct PhysicalConsumptionModel : Hashable

Defines the physical consumption model for electric vehicles, using vehicle-specific parameters to calculate energy consumption along a route. Note: [sdk.transport.VehicleSpecification.current_weight_in_kilograms] must be set. Note: This is a beta release of this feature, so there could be a few bugs and unexpected behaviors. Related APIs may change for new releases without a deprecation process.

  • The proportion of the energy drawn from the battery that is used to move the vehicle. (This is to factor in energy losses through heat in the motors, for example.) Supported range from 0 to 1

    Declaration

    Swift

    public var driveTrainEfficiency: Double
  • The proportion of the energy gained when braking or going downhill that can be recuperated and restored as battery charge.

    Supported range from 0 to 1

    Declaration

    Swift

    public var recuperationEfficiency: Double
  • Power (in W) consumed by the vehicle’s auxiliary systems (for example, air conditioning, lights).

    The provided value must be greater than or equal to 0.

    Declaration

    Swift

    public var auxiliaryPowerConsumptionInWatts: Double
  • Frontal area represents the total cross section area of the vehicle as viewed from the front, specified in square meters. Physical consumption model is using this value in combination with airDragCoefficient to calculate the consumption caused by air resistance. As fallback VehicleSpecification.widthInCentimeters and VehicleSpecification.heightInCentimeters are used.

    This parameter is used to provide a more accurate consumption prediction for electric vehicles.

    In the range from 0.5 to 50

    Declaration

    Swift

    public var frontalAreaInSquareMeters: Double
  • Rolling resistance refers to the resistance experienced by your vehicle tire as it rolls over a surface. The main causes of this resistance are tire deformation, wing drag, and friction with the ground. The coefficient of rolling resistance is a numerical value indicating the severity of this factor.

    This parameter is used to provide a more accurate consumption prediction for electric vehicles.

    Supported range from 0 to 1

    Declaration

    Swift

    public var rollingResistanceCoefficient: Double
  • The drag coefficient of an vehicle defines the way the vehicle is expected to pass through the surrounding air. More streamlined vehicles are more aerodynamic and therefore have smaller drag coefficient.

    This parameter is used to provide a more accurate consumption prediction for electric vehicles.

    Supported range from 0 to 1

    Declaration

    Swift

    public var airDragCoefficient: Double
  • Creates a new instance.

    • Parameters

      • driveTrainEfficiency: The proportion of the energy drawn from the battery that is used to move the vehicle. (This is to factor in energy losses through heat in the motors, for example.) Supported range from 0 to 1
      • recuperationEfficiency: The proportion of the energy gained when braking or going downhill that can be recuperated and restored as battery charge.

      Supported range from 0 to 1

      • auxiliaryPowerConsumptionInWatts: Power (in W) consumed by the vehicle’s auxiliary systems (for example, air conditioning, lights).

      The provided value must be greater than or equal to 0.

      This parameter is used to provide a more accurate consumption prediction for electric vehicles.

      In the range from 0.5 to 50

      • rollingResistanceCoefficient: Rolling resistance refers to the resistance experienced by your vehicle tire as it rolls over a surface. The main causes of this resistance are tire deformation, wing drag, and friction with the ground. The coefficient of rolling resistance is a numerical value indicating the severity of this factor.

      This parameter is used to provide a more accurate consumption prediction for electric vehicles.

      Supported range from 0 to 1

      • airDragCoefficient: The drag coefficient of an vehicle defines the way the vehicle is expected to pass through the surrounding air. More streamlined vehicles are more aerodynamic and therefore have smaller drag coefficient.

      This parameter is used to provide a more accurate consumption prediction for electric vehicles.

      Supported range from 0 to 1

    Declaration

    Swift

    public init(driveTrainEfficiency: Double = 0.1, recuperationEfficiency: Double = 0.1, auxiliaryPowerConsumptionInWatts: Double = 0.1, frontalAreaInSquareMeters: Double = 0.5, rollingResistanceCoefficient: Double = 0.1, airDragCoefficient: Double = 0.1)