# Validity of a VRP formulation

A delivery company is operating in Virginia and has a fleet of trucks that are used to deliver groceries from supermarkets to consumers. The company delivers orders and operates its fleet for one shift per day that is between 12 PM and 11:59 PM.

Each day by 12 PM, the company receives a list of all deliveries required from all supermarkets. Each order is defined by the supermarket location, delivery location, and delivery time window. The company should deliver all orders. The goal of the business is to minimize its costs which are defined as follows:

πΆππ π‘ = (π½ Γ π) + (πΎ Γ π·)
π½: the fixed cost per each used truck per day.
π: the number of used trucks per day.
πΎ: the cost per unit travel distance in km.
π·: the total travel distance from all trucks per day in km.

All trucks should start and end their operation at the depot. The location of the depot is at: [25.1371,55.25042]. The average service time per order is 5 minutes (i.e., the time needed to take the order to the front door of the customer after arriving at their location).

Assumptions:
β’ All distances are assumed to be haversine distances.
β’ The average driving speed of the truck is 20 km/hr.
β’ π½ = 300$$/π‘ππ’ππ$$
β’ πΎ = 0.5$$/ππ$$
β’ Trucks have infinite capacity.

Hence, a truck can pick up multiple ordersβ deliveries and then deliver them. You are given the data for 6 different days. Days 1, 2, and 3 had a low amount of demand, while days 4, 5, and 6 had a high amount of demand. You need to come up with the operational plan deciding how many trucks to use and the route of each truck. (i.e., deal with each day as a separate problem, so the optimal number of trucks per day can be two on day 1 and five on day 2, and so on).

Here is my formulation:

• I think you should give your model maximum number of available trucks, then introduce additional index to your binary variable $x_i$ be $x_{i,t}$. t means the index of truck. Then the $x_{i,t} = 1$ if order $i$ is assigned to truck $t$ otherwise, $0$. In addition, introduce another variable $y_t$ means whether use truck $t$ or not. And cons: $\sum_{t} y_t \leq M$, $M =$ maximum number of available trucks. . Nov 17 at 12:30