mapbox / mapbox/node-or-tools

Vehicle Specific Cost and Duration Factors

Open
#18 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
155
Forks
47
PR merge metrics
No merged PRs in 30d

Description

At the moment we expose a single cost and duration matrix per vehicle. What we should allow for in the context of multiple vehicles is cost and duration factors on a per vehicle basis to scale the cost and duration matrix the user passes us, think

numVehicles: 3
costFactors: [1.0, 0.7, 1.5]
durationFactors: [1.0, 0.7, 1.5]

which would scale both the cost as well as the duration matrices depending on the factors for each vehicle. We need to separate cost and duration factors because users could specify e.g. distance as cost in which case `costFactors` would be `[1.0 1.0 1.0]` and `durationFactors` would account for slower and faster vehicles.

Related: Heterogeneous Fleets https://github.com/mapbox/node-or-tools/issues/11

cc @karenzshea

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no files or tests. Start by tracing the public vehicle-routing API that accepts cost and duration matrices, then review the related Heterogeneous Fleets issue (#11). Done means multiple vehicles can receive separate costFactors and durationFactors that scale the corresponding matrices, with coverage for the three-vehicle example.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, node.js
Domain
backend-api-design
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.