Skip to content

GSoC' 22: Detailed description and signature of the new OR-Tools Bin Packing category functions to be added in vrpRouting #41

Closed
@Manas23601

Description

@Manas23601

Description

Google OR-Tools is an open-source software suite that can solve optimization problems such as:

  • Vehicle Routing
  • Flows
  • Integer and Linear Programming
  • Constraint Programming
  • Bin Packing

OR-Tools Bin Packing Category Functions:

  1. vrp_knapsack
vrp_knapsack(
  Weights_Costs SQL, capacity ANY-INTEGER, [, max_rows])

RETURNS SET OF
(item_id)
  1. vrp_multiple_knapsack
vrp_multiple_knapsack(
  Weights_Costs SQL, capacities ARRAY[ANY-INTEGER], [, max_rows])

RETURNS SET OF
(knapsack_number, item_id)
  1. vrp_bin_packing
vrp_bin_packing(
  Weights SQL, bin_capacity ANY-INTEGER, [, max_rows])

RETURNS SET OF
(bin_number, item_id)

Parameters:

  1. vrp_knapsack
Parameter Type Description
Weights_Cost SQL TEXT Weights_Cost SQL query describing the weight and cost of each item
Capacity ANY-INTEGER Maximum Capacity of the knapsack
max_rows ANY-INTEGER Maximum items(rows) to fetch from bin_packing_data table. Default = 100000
  1. vrp_multiple_knapsack
Parameter Type Description
Weights_Cost SQL TEXT Weights_Cost SQL query describing the weight and cost of each item
Capacities ARRAY[ANY-INTEGER] An Array describing maximum capacity of each knapsack
max_rows ANY-INTEGER Maximum items(rows) to fetch from bin_packing_data table. Default = 100000
  1. vrp_bin_packing
Parameter Type Description
Weights SQL TEXT Weights_Cost SQL query describing the weight of each item
Bin_Capacity ANY-INTEGER Maximum Capacity of Bin.
max_rows ANY-INTEGER Maximum items(rows) to fetch from bin_packing_data table. Default = 100000

Inner Query:

Weights_Cost SQL

Column Type Default Description
id ANY-INTEGER unique Identifier of the edge
weight ANY-INTEGER weight of the item
cost ANY-INTEGER cost of the item

Weights SQL

Column Type Default Description
id ANY-INTEGER unique Identifier of the edge
weight ANY-INTEGER weight of the item

Where:
ANY-INTEGER = SMALLINT, INTEGER, BIGINT
ANY-NUMERICAL = SMALLINT, INTEGER, BIGINT, REAL, FLOAT

Result Columns:

  1. vrp_knapsack
Column Type Description
item_id ANY-INTEGER Integer to identify an item.
  1. vrp_multiple_knapsack
Column Type Description
item_id ANY-INTEGER Integer to identify an item.
knapsack_number ANY-INTEGER Integer to identify knapsack.
  1. vrp_bin_packing
Column Type Description
item_id ANY-INTEGER Integer to identify an item.
bin_number ANY-INTEGER Integer to identify bin.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions