I want to solve a VRP with some constraints. Let's say I got a network of nodes (= electric omnibus network) and each node represents a busline. Each node has attributes like starting and end time and energy consumption.
My idea is to use the code for a VRPTW and add the constraint of the energy consumption as capacity of a node .
This way I could manage that after a bus does a specific line, it only drives to the lines that are possible to fulfill concerning the time window (means: if he can or can not reach f.ex. line 30 before its starting time) and concerning the enery capacity (every bus has a battery and the energy consumption must not bring it below a certain point x. Point x means the bus can drive the line and still have enough energy left to reach the closest loading facility).
I tried to add the capacity constraint with the AddDimension() functionality, but it doesn't work out the way I want it to.
My question is: is it even possible to realize my idea with the current state of OR-Tools and if yes, how is it done best?
I do it with Python.
Combining multiple Routing tasks of Google OR-Tools
192 Views Asked by nostripe At
0
There are 0 best solutions below
Related Questions in CONSTRAINTS
- Can't display the simplest UIToolbar
- IO placement is infeasible error in Vivado
- Timefold Solver applies the constraints based on priority/order of constraints (from ConstraintProvider) by default?
- Is it possible to restrict a method to a specific namespace?
- Modify Wave Function Collapse for Non-Perfectly Solvable Problems
- Hibernate CascadeType Issue: Updates not Cascading to Child Entity
- Verifying all address locations of memory
- Apply constraint through EF Core to SQL Server using .NET 6.0?
- How to check attributes of a ref column in the table that is being updated - Oracle
- Spark Not Null constrains in combination with badrecordspath for reading (delta) tables
- How to get consecutive pairs (based on their Timeslot) of Lessons in Timefold?
- Requires compile with msvc but rejected by gcc
- keep has_each for a list in Specman
- Why does C++20's concept constraint not work as expected?
- Issue while saving using Entity Framework Core with datetime columns constraint
Related Questions in OR-TOOLS
- Google or-tools soft constraint issue
- OR Tools cp model performance for flexible job shop scheduling with transitions
- Add node precedence
- OR Tools problem with 'scheduling_with_transitions_sat' job shop scheduling example from GitHub
- OR Tools Job Shop Scheduling for multiple machines with setup times
- Only allow intervals to be produced on machines during shifts cp-sat or-tools
- ortools solvers GLOP, PDLP instantly writes that the model is infeasible
- Self referencing constraints
- Geo spatial constraints in OR-Tools CP-SAT
- CpModel BoolVar not evaluating as a boolean
- Adding reload points in Google Cloud Fleet Routing API (Optimization AI)
- Differences between Excel Solver & OR Tools solver in python
- Unable to build OR-Tools with XPRESS enabled in Windows 11
- Google OR-Tools Set Some Locations Edge Fixed
- AttributeError: type object 'ortools.algorithms.python.knapsack_solver.KnapsackSolver' has no attribute 'KNAPSACK_DYNAMIC_PROGRAMMING_SOLVER'
Related Questions in CAPACITY
- Is there any PyPSA sample of the Energy Storage capacity expansion model?
- Why the values from Hadoop API doesn't match with the calculated values?
- Anylogic set forklift capacity to be 2
- Discrepancy Between Calculated and Actual capacity in Slice
- Define Service Block Capacity
- newtonsoft json memmory reservation serialize
- Volume opportunistic available capacity differs so much and too low
- Capacity of HashMaps in Rust (Rust by Practice)
- Artifact capacity in Power BI Premium Gen 2
- How to initialize slice with initial values and capacity at the same time?
- Set Array.capacity manualy?
- Why does the capacity of a vector increase by a factor of 1.5?
- Stardog on VM Linux Ubutu - memory capacity
- Power BI Capacity failed to refresh dataset even after capacity size increased
- Define StringBuilder capacity when number of characters is unknown
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?