Introduction

City Logistics consists in searching for the optimal delivery of goods within cities, mostly using motorized vehicles while seeking to reduce its negative effects, such as gas consumption, emissions, congestion and public safety. City Logistics is commonly related to last-mile transportation problems. Because of the current growth in e-commerce, retailers, wholesalers, and individuals have increased the number of deliveries to consumers as well as to small businesses. Several companies provide logistics services for a wide variety of customers, mostly in the form of customized transportation, logistics operations, and warehousing support. However, constant economic changes and sustainable logistics’ needs have pushed companies to expand their services beyond traditional logistics and to offer new value-added services. These changes have also triggered the concept of smart city (Eitzen et al. 2017). The consolidation of goods, also known as pooling, is one of the best practices when it comes to reducing costs and increasing synergy among truck fleets. Benefits for truckers and shippers range from increased economies of scale, greater transportation offers, easier evaluation of offers, decreased collaboration costs, reduced gas emissions for transit systems, lower risks associated with transportation, and increased confidence with partners. Some strategic issues can equally see improvements, such as limiting price policy and market objective disclosures, and increasing fair competition without jeopardizing market prices.

Because of these potential benefits, creating a technological platform to solve an ‘on-route pooling and consolidation of goods’ problem would seem to be a must; an online logistics trucking platform could provide individuals’ desirable solutions and a collective benefit. We could expect that an online logistics trucking platform could benefit from several services, such as vehicle communication through Smart City’s sensors, command and control of city facilities, distress relief caused by incidents, or real-time alternative routing of trucks and/or goods. Besides, we could expect the matching and synchronization of customers and drivers to simplify intermodal operations, back-hauling, cross-docking, on route information (hazards warning), parking localization and payment, timing and delay forecasting, etc. This solution consists in strategically accepting pickup and deliveries from new shippers in LTL (less than full load) trucks already on the road in order to allow a higher utilization of empty truck spaces. This innovative service is called ‘LTL Truck-Share’ and allows carriers to register and post their trucks on tour, and shippers to register their cargo characteristics. The platform should add (consolidate) as much cargo as possible in real time for LTL trucks. The purpose of this study is thus to simulate an LTL truck-sharing logistics platform and to propose new approaches to solve LTL transportation problems, based on the platform. The cargo ranges from small to medium-sized shipments and the solution is not limited to urban areas but also extends to the use of roads near urban agglomerations. In order to do so, our modeling framework is based on ‘Theory of stable allocations and the practice of market design’. This theory was developed by Lloyd S. Shapley and Alvin E. Roth and received the ‘Economics Nobel Prize’ in 2012. According to this theory, it is always possible to solve a Stable Matching Problem (SMP) and to make all marriages stable.

This paper is set out as follows: in “Literature review” section, the research begins with a panorama of trends and advances in transportation. In “Modeling framework” section, the main part of this research, we present how the truck-sharing technological platform operates in the context of a sharing economy, assuming a rational behavior of users with additional hypothesis. In “Results” section, we present an analysis of results, and in “Conclusions and future research” section, we offer conclusions and remarks on the interesting future of platforms and new avenues for research.

Literature review

Truck transportation is the most important form of goods transportation in the world. Nevertheless, truck space vacancy remains high, a situation which has not changed considerably over the last decade. For example, unloaded trucks in the European Union, measured by driven kilometers, dropped by only 2% between 2010 and 2017, going from 21.9 to 20%, according to Eurostat (Eurostat 2018). In the face of this reality, City Logistics has become an active field of research (Savelsbergh and Savelsbergh 2016). City Logistics solutions have been applied in several cities, and their simulations represent an interesting means of studying the movement of goods and truck emptiness (Simo et al. 2018). Even ‘Hyperconnected City Logistics’ has been proposed to allow the efficient design of sustainable urban transportation systems (Crainic and Montreuil 2016). Nevertheless, integrating short-term operations scheduling represents a huge challenge in City Logistics planning (Crainic et al. 2009).

On the one hand, the limited capacity of truck fleet sizes imposes a flow of empty or LTL trucks from the city going to satellite centers and urban distribution centers in a continuous way. On the other hand, City Logistics must consider reverse movements originating in the city that have a destination outside the urban perimeter, but often this is not the case. The reverse good movement can be associated with product returns, damaged goods, wrongly-addressed merchandise, new steps in the customization process and waste collection operations. Most of the time the movement of entering and exiting flows is imbalanced as fewer cities consider the operations of some small industries and/or fluvial ports in their cores. In addition, many companies consider return logistics planning as it is important for their business, but they do not consider the synergy available with the available outbound empty truck flow. As has been pointed out, the design balance of the service network in City Logistics operations is still an open field of research (Crainic et al. 2009).

Joint planning is one of the solutions for increasing sharing of logistic providers, which includes schemes such as ‘horizontal collaboration’ or ‘multi-agent decision models’ (Baykasoglu and Kaplanoglu 2011; Rakotonarivo et al. 2009). However, these schemes and their solutions must deal with pressures from frequent, small and short lead-time queries for shipments (Palmer et al. 2012). Usually, efficiency can be increased when deadlines are long and when a centralized set-up is used (Kohn and Brodin 2008; McKinnon and Edwards 2010; McKinnon and Ge 2013; Zhou and Dai 2012). Possibilities of transportation sharing in long-haul cases have been studied by Islam and Olsen (2014), in particular for hinterland trucking. We note that sharing vehicle capacity can allow shippers to make fast deliveries when other regular shippers are present in the same delivery zones.

Several economies of scale (Nguyen et al. 2014) can be achieved in ‘time-based consolidation’ (in a rolling horizon or deadlines) as well as in ‘quantity-based consolidation’ (geographically, by freight centers or terminals). In some cases, ‘consolidation’ strategies encourage carriers to cooperate/coordinate in each other’s delivery zones or even to act in combinatorial auctions (Mesa-Arango and Ukkusuri 2013). In practice, consolidation can be achieved through ‘urban consolidation’ (in centers or parking lots), ‘in-truck consolidation’ or ‘destination perspective consolidation’ (package delivery logistics among carriers). Nevertheless, a trade-off exists between transportation costs reduction, pickup and delivery operations speed and detours and handling costs. Moreover, cooperation requires associating companies that normally compete against each other and that wish to maintain fast procurement as their differentiation tool. In City Logistics, Urban Consolidation Centers (UCC) are not always successful due to high operating costs which are tied not only to insufficient number of carriers willing to outsource trucks but also to the lack of supporting incentives and measures such as regulation and access fees (Mes et al. 2014; Marcucci and Danielis 2008; Regan and Golob 2005). According to Macharis and Kin (2017), a new classification of innovative concepts for sustainable City Logistics could be considered by the private sector to deal with these challenges. These concepts are awareness, avoidance, act and shift, and anticipation of new technologies. Other authors (Arvidsson and Pazirandeh 2017) suggest the evaluation of ‘mobile depots’ to support low emissions last-mile deliveries. Crowdshipping appears as one of the sharing economy models that considers deliveries made by tiers on their current way to certain neighborhoods. Small businesses or individuals can trust them to complete their deliveries. The integration of individual and freight transportation is based on a matching process through online platforms between logistics requesters and transportation suppliers (truck bidders).

As mentioned, transportation offers opportunities for people willing to share their unused assets for profit or at least to reduce expenditure by Crowdshipping. For example, Uber connects car owners with users willing to pay for these assets in taxi rides. Walmart uses customers in part of their deliveries to other customers, providing faster deliveries at low cost with reduced fleet sizes. These operation modes can be operated by stores or be outsourced through third-party applications to guarantee a certain quality of service or even same-day deliveries (Dayarian and Savelsbergh 2017). More professional Digital Brokerage Services exist like Cargo and Uber Freight, where low to medium-sized companies agree to transport items for short periods for a fee. The operation engages drivers in time slots with minimum payments for their work, allowing better back hauling, small and irregular hauling. Powerpool LLC, an extension to Uber Freight, considers renting trailers to carriers for drop-and-hook, resulting in shorter tows and reduced waiting time for load/unload operations. This service could be well suited for inner city or local logistics. Again, but in last-mile delivery, companies like Roadie, Deliv and PiggyBee created platforms for retailer parcels delivery and individual car owners (Dayarian and Savelsbergh 2017). One of the expectations for drivers in Crowdshipping is set in a way to avoid the need for additional driving legs but for a routing that exploits their frequent travel arrangements (Le and Ukkusuri 2019). The Crowdshipping platforms can prefer drivers closest to the delivery route or offering low fees, short reacting time and/or have good reputation (Le et al. 2019). Port Community Systems (PCS) are neutral and open electronic platforms according to the European Port Community Systems Association, which connect information and services from various public and private organizations, allowing the synergy to produce a much wider service. PCA container terminals allow fast e-reports for containers data from transport carriers, forwarding agent and shippers. The container can then be picked up or be delivered faster, thus maximizing goods flow. In order to reduce costs, collaboration by vehicles sharing could allow shipments deliveries to several importers under pressure from physical space and time-window constraints, as is studied in Irannezhad et al. (2017).

Nevertheless, crowdshipping can have both favorable and negative consequences for gas consumption, gas emissions and traffic congestion (Simoni et al. 2019). Time windows or deadlines are complex to fulfill and impose difficulties to the offering process and when deals are achieved, they remain complex for the deliveries. In most cases, large distributions are unlikely to be successful despite being more attractive (Ermagun et al. 2019).

To popularize sustainable transport innovation in truck-sharing, policymakers and potential bidders should understand the factors affecting the willingness of probable users, as happens for other car-sharing paradigms (Klein and Ben-Elia 2016). As stated in Wang et al. (2019), research in behavioral economics shows that cooperation can be reframed to solve social dilemmas. For example, taxi sharing has been analyzed for potential benefits and drawbacks using agent-based modeling (Lokhandwala and Cai 2018). The effects of competition in the vehicle sharing business have also been explored, allowing agents to make decisions based on a discrete choice model that includes car-sharing alternatives (Balac et al. 2019). Other agent-based approaches attempt to infer transport demand from agent’s needs to perform certain activities at specific places and times, as pointed out in Drchal et al. (2019), which could be very interesting to facilitate synergies among carriers, as well as compatible hardware, compatible load characteristics and good zonal covering (Caldwell and Fisher 2008; Cruijssen et al. 2007; Leshchynskyy 2013).

Similar to those studies, prior research in transportation sharing shows that even in favorable environments and with good business opportunities, collaboration requires avoiding opportunistic behaviors and maintaining high levels of trust. Peetijade and Bangviwat (2012) using real data gathered from non-associated truckers, account for the possible savings in transportation costs when several independent trucks are managed considering the diminution of empty trips. Zolfagharinia and Haughton (2014) presents a model that, in Advance Load Information (ALI), considers implementing a dynamic rolling horizon context to include trucks returning to base or the empty repositioning of trucks. It is also possible to consider in these models the short-term problem (distance minimization) vs the long-term goals (future requests for pickups) on the same day, showing the relevance of having a company culture based on a long-term vision based on profits from short-term information. These margins get reduced when advance information is much extended and becomes expensive. Prior studies have also highlighted the role of governmental involvement as a trust agent and facility provider. Other challenges behind collaboration are ‘transportation costs’ allocation, which is essential to determine transportation pricing (Toptal and Bingöl 2011). A more compressive study on transportation cost allocation can be found in Guajardo and Rönnqvist (2016) and Caprara and Letchford (2010).

Optimization may work well for one agent but become ineffective for other agents participating in the collaboration (Agarwal et al. 2009). When centralized optimization is ineffective or too complicated, Cooperative Truckload Delivery (CTLD) (Hezarkhani et al. 2016) can assure agents’ self-interest through the use of several logistics providers, as well as their equipment and delivery requirements. In that case, the optimal delivery plan normally considers empty truck repositioning and slog warehouses and clients, and cost reductions are proportionally allocated based on performance measures. Despite this simplicity, collaboration outcomes are not necessarily fair nor consider the competitiveness of individual companies. For example, delivery shares do not always satisfy a given CTLD situation (Hezarkhani et al. 2016). Besides, revenue distribution is complicated because the proposed agreement does not hold all the desired properties, even for a 2-agent case, or because supplementary optimizations for allocations are needed.

Moreover, under specific restrictions, or when cost and revenue are not easy to split, it becomes difficult either to find an agreement or to keep all the participants within the agreement. The most desirable properties would thus be the existence of a ‘no-disengagement incentive,’ which intends to discourage participants from looking for more lucrative associations. Another more complex and important property is the ‘independence of irrelevant deliveries property (IID)’, which seeks that individual earnings from the coalition only consider the resources involved or engaged in the transportation solution. In that sense, individuals do not have incentives to inflate contributions or to overdo the resources to diminish the competitiveness of small players.

A useful KPI for IID is the “average minimal cost of the delivery (requirements) divided by the full distance (of delivery)” (Hezarkhani et al. 2016). A lower average implies revenues at lower prices. Future cooperation could alter the costs of the network, so a situation with multiple agents requires a complex balance to keep equivalent competitiveness of the agents after the sharing. These combinatorial paradigms need sharing costs methods and concessions to find good-quality solutions. In Dai and Chen (2012), the particular problem of pickup and delivery is studied and three methods for revenue allocation are proposed.

As pointed out in prior literature, horizontal cooperation in logistics (Cruijssen et al. 2007) must deal not only with partner selection and revenue sharing, but also with information sharing, protection and real-time decisions. From a practical perspective, only an approximate real-time solution is needed because platforms will simultaneously solve complicated constraint-satisfaction problems (cargo affinities, origins, destinations, sizes, weights, time window precedency, etc.) on a small number of users. Once the solution is accepted, a more detailed routing problem can be solved. Goods could be tracked precisely from one position to another and thus transparency will avoid unethical behaviors. We argue that logistic collaboration through the online platform could be solved as a matching problem and market design. To our knowledge, there are no studies that tie online sharing platforms with matching theory in order to introduce rewards that help to find solutions that simultaneously attain cost reductions and satisfy the needs of trucks bidders and pickup-and-delivery requesters. As a result of the matching solutions, it is possible to reduce travel distances tied to gas emissions. Our contribution is a numerical simulation that shows how the rewards operate on stable matches and the effect on reducing the travel distance under several conditions of fixed costs and variable costs. The results also show the phenomena of association even under harsh economic conditions in variable costs.

Modeling framework

A Stable Matching Problem consists in finding a stable matching between two equally-sized sets, given an ordering of preferences for each element in the sets. The most common example consists of: given a group of \(n\) men (\(M\)) and \(n\) women (\(W\)), find a suitable’ matching. Participants can rank members of the other sex and list the members through a best-to-worst order of preference. Matches are possible between the two groups.

Stable matching is defined as given \(m,m^{\prime} \in M\) and \(w,w^{\prime} \in W\), with \(w \ne w^{\prime}\), a matching is stable when there is no match \(\left( {m, w} \right)\) by which both \(m \in M\) and  \(w \in W\) would individually be better off than they currently are, i.e. there is no incentive for any pair of participants to undermine the assignment: e.g. \(\left( {m, w} \right)\) dominates any pair \(\left( {m, w'} \right)\) and any pair \(\left( {m', w} \right)\). The algorithm that allows achieving a stable matching can be seen in Fig. 1 (Shapley 1962). This theory has allowed the development of similar algorithms for finding super-stable and strongly stable cases, if any. Nevertheless, stable does not imply optimal for all. For instance, the solution is optimal for the suitor but not for the reviewer (Shapley 1962) and the algorithm can be manipulated by participants using faked preferences.

Fig. 1
figure 1

Gale–Shapley: differed acceptance algorithm (1962)

Regarding market design, it is understood as a place where bidders and requesters usually interact for information, goods or services. Anything can be valuable for trade as long as it follows the prevalent demand and the subjacent offer. The market is summarized as the aggregation of all buyers and sellers in place. Trade mechanisms are rules and operations procedures to which markets must comply, such as price fixation, price notification channels, deal engagement, transaction or exchange security and logistics for delivering goods (Roth 2007). To optimize market functioning, it is expected that markets must be self-regulated by perfect competition. In established markets, unstable mechanisms are abandoned because it is unsustainable to keep the benefits of some actors at the expense of others. Moreover, the lack of market optimality can also play a role in dismissing the market. Therefore, in order to achieve a high degree of optimality, a third party is usually needed to balance smaller participants. On the one hand there are regulatory institutions, and on the other hand, there are the public, managers, workers, dealers and entrepreneurs (Roth 2018). Market design is also used in other fields such as game theory, computer science and marketing (Roth 2018). There are many specific matching market problems that have been studied in the past 50 years such as the hospitals/resident’s problem, the hospitals/resident’s problem with couples (Roth 2018), the college admissions problem among others which are mostly focused on allocations and assignments. Stability and incentives are some of the most interesting topics in these studies (Roth 2018).

The theory of stable matching is applied to find feasible matches, given the short time window to decide. In our model, we have considered a matching model that is derived from the classical model where two sets, bidders and requesters, exist. A stable match exists when there is not another match between a bidder and a requester by which both would be independently satisfied. Doubtless, every match is perfectly distinguishable in terms of its beneficial partnership and there are not two or more matches that have identical demands. Both the truck bidder and the logistics requester input their initial truck warehouses and their pickup and delivery sites with their respective time windows. The platform will check the feasibility of the trips and will estimate the fixed costs for the trucks as well as the variable costs, which are mainly gas consumption and drivers’ hourly wage, based on the projected travel distance to the warehouse.

Modeling approach

The truck-sharing logistics platform simulation is developed in 4 phases, as shown in Fig. 2. A simulated sharing logistics platform will perform all the basic features of registering clients, shippers and carriers in the simulation. Then the system will allow agents to register ‘origin to destination’ needs and offers using a generation algorithm. The platform will consider a journey of pickup-and-deliveries and an algorithm will seek to reduce the number of trucks and thus reduce emissions by matching clients with compatible time constraints. In the simulation, another algorithm will consider the most suitable matches, appealing to the rational behavior and to the theory of stable allocations and market design. For the match, the shippers have to sign a contract with the other carrier which is on the pod. We aim to show that the platform operation could achieve important efficiency, reducing cost and gas emissions for last-mile delivery, which opens new opportunities for research particularly in restricted routing problems. The Truck Sharing logistics platform thus allows contact between truck bidders and logistic requesters. In this platform, the bidders offer their available spaces in their trucks in a zone or neighborhood for pickup and delivery operations. The requesters need to do pickup and delivery within a time window known in advance. The platform is able to match compatible goods with compatible trucks in order to make the pickup and delivery operations in the specific time frames. The platform is not intended for dangerous goods, live animals or food liquids but for most urban common goods in Type 1: general cargo (packed products), like packages, baskets, boxes barrels, bags, bottles, crates and pallets. We consider compatible goods those that fit in the truck’s empty space, given the truck dimensions. The algorithm discriminates size (length, width, and height), quantities and weights for goods and will check the geometrical and technical restrictions in the available space. The bidders must write this information in the platform. Type 4 (refrigerated transport) has its own requirements and regulations to comply with using extra constraints that can also be analyzed under these criteria for acceptance or rejection. We did not include these analyses on the algorithm to not distract attention from the model. The sharing logistics platform is capable of finding several matches between offers and requests in almost real time (in the same journey), so agents would need to make decisions, either accepting or refusing the matches, in a reduced time frame.

Fig. 2
figure 2

Flow chart for the numerical simulation

The basic premise behind the algorithm is that truck bidders have a default solution, which corresponds to making their pickup and delivery alone. Therefore, logistic requesters can always rely on renting a truck at full price to make their delivery. Besides, the algorithm considers whether there are available trucks to hire (bidders) and customers with transportation needs. Both parties are willing to inform their needs in a competitive market, which means that there is always a risk that an early deal could fall apart because another better deal has appeared. Therefore, finding good deals for both parties could be very cumbersome because both sides can act opportunistically. A simple way to characterize the performance of a deal is through its cost, i.e. the lowest cost will always be preferred. We assume that every participant will evaluate the performance of a deal and will prioritize the most interesting one. The stable matching algorithm devised for the problem of city delivery thus evaluates several possible interactions to propose deals that are convenient for both parties in terms of the distance, which reduces variable costs but also implies the decrease of one truck and the reduction of fixed costs.

Algorithm development

An important issue is how to allocate the sharing cost of the association. The cost-sharing formula considers a repartition based on the original travel distance for every party. The match implies a new routing with a different total distance. The sharing cost is thus the performance indicator for the truck-sharing deal. This value is important to help the decision process. As every party can evaluate all the possible deals, the logistics platform can use all these values and prepare a ranking, for every participant, from the lowest sharing cost to the highest sharing cost (the most interesting deal to the least interesting deal). The algorithm will use these ranks to evaluate a stable match and to evaluate the gain from the original situation to the matched situation. Deals positioned at the end of the rank will not be considered because both parties will only accept deals that provide at least a minimum saving, proportional to the original cost. In the other cases, the bidder or the requester will keep its current solution, which is to use its own truck or to rent a truck respectively. The lowest minimum saving, proportional to the original cost is given by a parameter α (\(0 < \alpha \le 1\)). This implies that at least the shared cost must be lower in α times to the original cost, as shown in (1) and (2).

In the Gale–Shapley, Differed Acceptance Algorithm “for solving the matching problem”, there are suitors and reviewers that have different roles in the matching. However, in the problem that we aim to solve with the platform, it is difficult to consider an active suitor and a very passive reviewer. Both logistics bidders and logistic requesters could be equally tempted to propose and review different proposals interactively. The devised algorithm will thus try to find a stable match that creates a benefit, such as a reduced cost sharing.

The purpose of the algorithm in Fig. 3, is to generate a match between bidders and requesters. In the algorithm, the first loop chooses a truck bidder (or a truck requester) to find a match following the rank from very interesting (low sharing cost) to less interesting (high sharing cost). If the opposite partner is available, or the opposite partner is willing to break its current deal, the match would be possible, but if this is not the case, it will walk to the next available partner following the ranking list. It is important to notice that the algorithm allows an already-engaged opposite partner to evaluate a new proposition from a truck bidder (or a truck requester) and thus to drop its current match in order to generate a new one. When it is not possible to continue with this process, the loop is broken.

In the second loop of the algorithm in Fig. 3, the matched couples can continue to propose to other opposites only if they have passively accepted a proposition, so they have a chance to improve their condition following their ranking list. This loop finishes when any participant passively matched has proposed to many opposites in its rank list. Some participants could remain unmatched at the end of the loop. The main loop keeps rotating the flow between matchings and challenges cycles. In the worst case, every participant would remain with its default solution and the algorithm will always finish.

Fig. 3
figure 3

Stable matching algorithm for bidders and requesters

In the end, the algorithm will have matched deals with very close delivery points (from truck bidders and logistic requesters). In other words, the matching algorithm will find shortest routing from truck bidder to logistics requester or will default to keep them as singles in the worst case, which is the initial case.

In a real situation, the devised algorithm will have limited time to calculate, as pickup and delivery situations are constrained. Bidders and requesters will receive a detailed origin to destination list with the ordering of the visits. With this information, the routing process is simplified because every arc in the path can be routed with the current available technology. The platform does not consider complex routings, such as those that consider complex solutions for the Travel Salesman Problems, because the ordering of nodes is known in advance. We consider the number of pickup and delivery locations in practice as very low, 3 or 4 locations at most. The reason is to model common city logistics needs, where there are a limited number of trucks, high concentration of populations and stores, dense vehicular congestion, simple tools for handling, few parking places and tied schedules for servicing, which naturally force coalitions’ changes in real time. Most vehicles will have plenty of free space and will work under considerable time slacks, providing their operations in a small district with few free parking spaces. Therefore, there is almost no need for public enforcing sharing rules or truck sharing incentives. More complex delivery problems, completing dozens of transactions, will also be related to flexible scheduling with probable trans-docking facilities to multi-depot situations and long trucking hours. The platform shields bidders and requesters from knowing details of each other. Indeed, the bidders and the requesters will receive only a matching list with approximate zones and timings in order to avoid providing any information that could give them a market advantage.

An interesting issue is how to improve cost-sharing benefits considering the distance that every user face before a truck sharing. This is important to avoid behaviors where truck bidders are too interested in traveling long distances to fulfill logistic requests, paying for the ride at the expense of the logistic requester that in the end will perceive the behavior as unfair. A simple way to avoid this behavior is by accommodating the rewards model to discourage excessively long trips making the extra distance also a charge of the opportunistic user.

Reward and ranking system to reduce gas consumption

Truck bidders and logistics requesters must comply with a reward system imposed by the platform that helps to limit (feasible) long hauls and to rank Truck Bidders and Logistics Requesters. As mentioned before, for simplicity we consider \({\text{Fixed costs}} = {\text{rental cost}}\) and \({\text{Variable costs}} = {\text{fuel costs}}\;*{\text{distance}}\). We introduce the following notations in Table 1. We note that usually \(d_{T} \ge d_{s} + d_{r}\), but it would be possible that \(d_{T} \approx d_{s} \approx d_{r}\) when a match is very favorable. In the scheme, we note that the ranking procedure is the sum of the fuel cost for the tour and the renting cost for the truck.

Table 1 Notations

The shared costs for Truck Bidders and Logistic Requesters are based on the ranking; they can be expressed in (1) and (2):

$${\text{Suitor Shared Cost}}:S_{s} = \left\{ {\begin{array}{*{20}l} {\frac{{d_{s} \;T}}{{(d_{s} + d_{r} )}}} \hfill & {{\text{if}}\frac{{d_{s} \;T}}{{(d_{s} + d_{r} )}} \le \alpha \;C_{s} \;} \hfill \\ {\text{No match}} \hfill & {{\text{else}} .} \hfill \\ \end{array} ,\forall s \in S.} \right.$$
(1)
$${\text{Reviewer Shared Cost}}:S_{r} = \left\{ {\begin{array}{*{20}l} {\frac{{d_{r} \;T}}{{(d_{s} + d_{r} )}}} \hfill & {{\text{if}}\;\frac{{d_{r} \;T}}{{(d_{s} + d_{r} )}} \le \alpha \;C_{r} \;} \hfill \\ {\text{No match}} \hfill & {{\text{else}} .} \hfill \\ \end{array} ,\forall r \in R.} \right.$$
(2)

Truck bidders shared costs is the portion of Combined Costs that is related to the Combined Truck Bidder-Logistics Requester trip. The formula implies that the longer the individual distance the bigger the share of the cost. The formula also considers T, which is the combined distance for the route. In the case of very good deals, hopefully this combined distance would be very low and the shared beneficial for both parties, so related to half, by example. Therefore, there is enough margin to accomplish for a minimum absolute savings given by \(\alpha\). All possible combinations among Truck Bidders and Logistics Requesters are set in the ranking lists.

It is also important to consider that in most cases users will be interested in matches that produce a tangible cost–benefit, so they would impose a threshold saving. In this case, this threshold benefit is chosen, \(\alpha = 0.1\) which corresponds to 10% of the routing costs (e.g. the costs of single riding before any match). This threshold saving is supposed to cover any other expenses for using the platform and it was chosen to represent a reasonable amount. We can have that the parameter is as \(0 < \alpha \le 1\) for most practical cases.

In this ranking-reward system \(T_{i} = T(d_{s} ,d_{r} )_{i} ,\forall i \in R \cup S\) will be minimized among all the participants that are available, i.e. participants will first try to match with other participants that minimize the total distance in increasing order. In this minimization, the distances consider the ‘origin’ and ‘destination’ points and also the warehouse. For example, for a bidder s, this is similar to get \(\min_{s \in S} \left\{ {\frac{{d_{s} \;T}}{{(d_{s} + d_{r} )}},\;{\text{if}}\;s{\text{ is available}}} \right\}\).

Cost estimation for a journey

The total cost estimation can be resumed in Fig. 4. For a given pair of parameters (“fixed_cost”, “variable_cost”), after applying the matching algorithm, the effective number of Ridding-Trucks (trucks on road) is usually lesser than the original: every feasible matching would reduce by one the total number of used trucks and the FC (Fixed cost sum) is proportional to the number of effective trucks circulating. Also, the routing distance is the combined routing for bidder and router in a stable match, but all the bidders and requesters (without a match) will kept their original routing distance. The VC (Variable cost sum) cost is proportional to the routing distance, which is usually lesser. The total cost is then the sum of FC and VC. We want to take advantage of these reductions in costs.

Fig. 4
figure 4

The total cost estimation considers the sum of FC (parametrized by “fixed_cost”), associated with insurances, leasing or renting trucks and VC (parameterized by “variable_cost”), usually characterized by fuel costs and depreciation. Different parameters result in significant differences. A reduction in the total-cost is the combination of a reduction in trucks and the reductions in routing distance

There are particular cases for very low fixed costs and variable costs. When fixed costs and variable costs are 0, the shared costs are also 0 for any possible feasible match. The ranking mechanism cannot make distinctions among users. The stable algorithm would initially choose at random. This case is not reported. When variable cost is 0, for any fixed cost bigger than zero, every user will be willing to share. The number of matches will be the maximum attainable for truck bidders and logistics requesters. In the converse situation, when fixed cost is 0, and the variable cost is bigger than 0, the total costs increase only with the distance. To obtain cost reductions, all matches must have many points in common, so the offered truck almost does not de-route from the unmatched cases.

For a given set of parameters “fixed_cost” and “variable_cost”, let us consider an example with 5 bidders and 3 requesters, as shown in Tables 2 and 3. We will consider that only the 1-A, 2-B and 3-C have stable matches, in the begging situation. They present expensive routes as shown in the “Row Sum Total Costs”, which represent the sum of Total Costs and Variable Costs, column in both tables. After the matching process there is a benefit expressed in the “Row Sum Total Costs” as variable costs and fixed costs have been reduced because of the sharing, as presented in the Fig. 4. All the process relies in the algorithm for stable matching. The next step is determining how to assign savings from a feasible match to the algorithm, as shown in (1) and (2), as a weighting repartition based on effective traveled distance.

Table 2 Initial situation with 5 bidders and 3 requesters in independents routes (no sharing)
Table 3 Situation after 3 matches

In summary, the general problem of finding compatible pickup and delivery partners with time delivery constraints is not as complex. For this reason, it is possible to use a greedy heuristic capable of solving the problem: the use of the truck for a period [Si, Fi] as an interval. A request and an offer are compatible if they do not overlap and if there is enough time to go from an Origin to a Destination, as shown in Fig. 5.

Fig. 5
figure 5

Pickup and delivery with fixed timing as an interval scheduling problem

The platform simulation

At the beginning, several parameters are defined to initialize the main variables of the simulation, such as the size of the plane, the number of bidders’ trucks and requesters’ trucks and the costs. The simulation consists in considering a journey in a city where there are two vehicle warehouses located far from downtown. In this city, most pickup and delivery operations will be taking place in the city center. Trucks begin their routing journey performing several scheduled pickups and deliveries. The route to the pickup and delivery site is done under feasible conditions of speed, distance and time schedule, with considerable time slacks. The problem generation algorithm simulates feasible cases of delivery trucks and possible requests, because this is a very general delivery problem in cities. To make plausible comparisons, an identical number of simulations is done changing two main parameters, fixed costs and variable costs. The simulation reports all the feasible stable matches. With this information, it is possible to estimate the total cost of the operation for bidders and requesters along with the reductions. The total cost is the sum of cost for the trucks in match and all the trucks without match. A match always implies the reduction of one truck. A large number of matches implies an important reduction in trucks, but the main impact is achieving higher savings because of the existence of both reductions, gas consumption and trucks’ utilization. To consider the process during the simulation, we can see the algorithm in Fig. 6, which presents an estimation of the central tendency of total cost for every pair of fixed and variable costs.

Fig. 6
figure 6

Algorithm which estimates the median of total-cost for “n” replications, given a pair of fixed cost and variable cost. In the algorithm, every replication is very unpredictable because of the random pick-and delivery points generated each time, therefore the median is chosen to represent the central tendency of values

The algorithm also considers that truck bidders and logistics requesters follow a rational behavior and thus they select the most convenient alternative from the list proposed by the platform. To simulate this process, an ad-hoc modification to the classical Gale–Shapley algorithm (already presented in Fig. 3) allows different numbers of bidders and requesters and at the same time, it allows randomly considering everyone as a suitor or as a requester. At the end of the iterative process, not everyone is matched, but every match is stable. The single ones remain with their original trip. The natural match has a truck bidder and a logistics requester together on a trip, which is costly but less costly than both doing independent trips. These costs are allocated in such a way that they respect the proportion of their single trip distances. We note that neither user has interest in lying in terms of the location of their initial truck warehouse, because the most preferable match considers reductions in distance for both the bidder and the requester, so fake information reduces the possibility of finding interesting deals, if any, and it will not improve the benefits of doing it. Because the cost reduction is mainly due to reductions in trucks, in the transported distance and/or in truck emptiness, the model has a direct implication in reducing greenhouse gases and vehicle congestion.

Figure 7 presents an example in which Truck 1 has a working journey between [04:30, 23:00]. We have this time range to consider for the wider operating conditions for a truck rental service. It begins from warehouse A at [04:30] and must pickup at point B at [18:06] and deliver at 2 different sites, point Cat [18:06] and in point D at [19:08], when it should come back to warehouse A at [23:00]. Truck 1 can be offered to do other pickup and delivery operations during the journey. Under these circumstances, it could be possible to find a requester that will ask for a pickup and delivery in the slack time available. In the case of Fig. 8, a requester could think about renting a Truck 2 from a warehouse at point F, to pickup goods from point B at [11:30] to deliver to point E at [14:48]. Because the need happens in the middle of the working day, a new solution can be found by re-routing Truck 1, and still respecting the schedule, to do the pickup at point B and the delivery at point E, as shown in Fig. 9. Then the final route for Truck 1 consists in the sequence of points A–B–E–C–D–A. However, in order to conclude that this case is fair and efficient, a numerical simulation within the platform is required.

Fig. 7
figure 7

Original routing example. Routing for Truck 1, from warehouse to pickup and delivery points, and coming back to the warehouse

Fig. 8
figure 8

Truck 2 pickup and delivery operation on one site, from warehouse F

Fig. 9
figure 9

Truck final routing including new pickup and delivery points from warehouse A

The numerical simulation

A simulator was developed in Python 2.7 and NumPy, coded to use independent parallel threats in a server machine with a CPU Intel® Xeon® E5-2670 v3, 12 cores at 2.60 GHz, 64 Gb Ram. The machine used Microsoft Windows Server 2012 R2 Datacenter [V. 6.3.9600]. For the simulation, the cost values were set as integer numbers to simplify the analysis. For the fixed costs, the range was set between [0, 60] monetary units and the variable costs in the range between [0, 10] monetary units. A time window of 30 min was applied to enforce any delay. We consider a total of 40 bidders’ trucks and 40 (additional) requesters. We consider a threshold benefit (\(\alpha = 0.1\)) of 10%. The dimension was settled in the rectangle to allow a rectangle of 3:4 to allow rides lesser or equal to 50 km in the longest side. The number of pickup/delivery points ranges in [1,4] based on the information from the truck industry.

The simulation took approximately 12 h. In the simulation, an equal fixed number of delivery trucks (the bidders) and delivery requesters is chosen to compare the behavior of the main independent variables, the fixed costs and the variable costs. We note that the number of bidders (offers) and requesters is kept constant during the simulation, as the generator considers a uniform distribution of pickup and delivery points in a rectangular Euclidean plane and also contemplates a uniform distribution of timings to be considered as the time windows for pickups-and-deliveries. The journey is estimated at 8 h of work for the timings. The simulation also studies 4 predetermined warehouses near the corners of the Euclidean plane. The simulation ponders that the requester can deliver the products by using its own fleet of trucks (or renting a truck) and consequently it will perform the routing of its own vehicles starting from the warehouse, followed by the pickup and delivery schedule, and returning the truck back to the warehouse, so the total cost considers all the variable and fixed costs.

Results

Our analysis aims to showcase to what extent the matching between the bidders and requesters could reduce traveling distances and the number of trucks required to deliver all products. The points (dots) in the following figures represent a journey simulation with an identical number of bidders (40 trucks) and requesters (40 additional trucks).

Figure 10 presents the number of trucks on road after running the matching algorithm, i.e. the trucks that will do the pickup and delivery, which includes the trucks in a match and the trucks from bidders and requesters that could not find an interesting match. As the fixed cost increases, it is very likely to find suitable matches, because the fixed cost becomes more and more important; then the truck company is inclined and willing to partner with another truck company to share the burden of this high cost. This implies that bidders and requesters will accept to deliver products (deliveries) that are distant. However, when the variable cost increases, they are more inclined to choose deliveries to customers who are located in the closest locations to reduce the total traveling distance. The number of feasible matches is small because any connecting link to a new site would be too expensive and will not leave profit for the cooperation, as can be seen in Fig. 10.

Fig. 10
figure 10

Relation between # of trucks on road based on fixed cost and variable cost

The points in the mantle are the median of several simulations. When the variable cost is relatively low, the number of trucks used to deliver products gets its minimum value and ranges between 45 and 55 out of the total 80 available trucks. When the variable cost is large, the number of used trucks for deliveries is higher and fluctuates between 70 and 80.

In Fig. 11, it is possible to see a plot of the Total Cost split as Fixed Costs and Variable Costs. This total cost consists in the variable costs and the fixed costs for all the pickup and delivery operations. The points in the mantle are the median of several simulations and it shows the behavior of the total cost of matched and non-matched solutions. Total cost increases linearly with the fixed cost, but even more with the variable costs. We note that for very low fixed and variable costs, there is almost no incentive to share routes and collaborate with other companies. We have arbitrarily imposed that the savings of the match must be at least 10% of the actual cost. When the value of the variable cost is equal to 3 there is a change in slope, which is given by the sudden increase in trucks used for deliveries.

Fig. 11
figure 11

Total cost of trucks transportation based on fixed cost and variable cost

As the variable cost increases, fewer and fewer profitable solution matches are possible. The profitable matches would occur where warehouses and pickup and delivery points are very close to each other. On one side, the average distance would be very high for very few cases because the bidder and the requester have almost identical pickup and delivery points, and these points could be quite separated. In those cases, the reduction in the distance of the solution match is high. We note that this odd situation happens more frequently with lower fixed costs, as the incentive to share is even lower, so the case requires that bidders and requesters will use similar routes. Nevertheless, the tendency remains constant considering all the simulations.

Figure 12 presents the total travel distance for all trucks in the road divided by the number of trucks in the road, so it is an average. This distance is estimated for every fixed cost and variable cost. Figure 12 shows the relationship between the fixed cost and variable cost vs the average distance traveled by used truck to deliver the products. When the variable cost is low, the average distance per truck is very high as the companies are willing to travel further to deliver products. On the other hand, when variable costs are high, the average traveling distance per truck is very low and trucks deliver products to closer destinations, as the price is high.

Fig. 12
figure 12

Relationship between road distances by # of trucks, based on fixed cost and variable cost

Sensitivity analysis considering delays and distance constraints

The number of possible matches depends on the traveling distances between the bidder pickup and delivery points as well as to the requester points. A first sensitivity analysis, performed with an original case, either allows the occurrence of late arrivals or adds a restriction to the travel distances. Another scenario combines both sensitivities (late arrivals and travel distance restriction). We note that as the number of possible matches increases, it becomes more difficult to achieve a stable matching. This would occur, for example, when there is a concentration of pickup and delivery points within a city.

Figure 13 presents the analysis of customers’ locations on the required numbers of trucks, i.e. the number of trucks needed (those that stay on the road after matching) when a restriction on the distance between the pickup and delivery points is imposed. The restriction accounts for the unwillingness to drive excessively. The result is reported in function of the fixed cost and variable cost. A complementary analysis considers the transportation total cost for the same situation, which is presented in Fig. 14. The distance restriction scenario consists in limiting the distance for the generation of random points for pickup and delivery for bidders and requesters. This behavior attempts to reproduce the interest of bidders in fulfilling the needs of close customers, such as those in main neighbors with commercial or industrial sites’ concentrations. This distance restriction also follows the interest in reducing truck traveling time and increasing charging/discharging operations or just freeing the truck for further operations. We note that this scenario reduces the distance/truck ratio, but the number of matching trucks remains very similar or equal. This result is because distance is already penalized through the variable cost and routing timing. Better results could be achieved when the truck’s warehouse coincides for bidders and requesters because adding new sites in the same route is highly feasible and inexpensive.

Fig. 13
figure 13

Sensibility analysis over customers’ locations on the required # of trucks, based on fixed cost and variable cost

Fig. 14
figure 14

Sensibility analysis over customers’ locations on the trucks’ transportation total cost, based on fixed cost and variable cost

The scenario that allows late arrival is represented in Figs. 15 and 16. This scenario represents when we allow trucks to arrive late to their commitments, Fig. 15 presents the number of total trucks in the road in these conditions and Fig. 16 represents the total cost of this situation. In order to increase the number of deliveries, time windows are enlarged. This policy of accepting delayed trucks considerably increases the number of matches, but this gain is rapidly offset by the increase in the variable cost that penalizes the longest routings. The reason is that new routes become economically unattractive and thus it is not an acceptable match.

Fig. 15
figure 15

Sensibility analysis over trucks customer visiting delays on # of trucks on road (ridding trucks), based on the fixed cost and variable cost

Fig. 16
figure 16

Sensibility analysis over trucks visiting customer delays on total truck transportation costs based on the fixed cost and variable cost

The combination of both distance restriction and late arrival is represented in Figs. 17 and 18; Fig. 17 represents the number of trucks when we allow trucks to arrive late at their commitments but there is also a restriction on the travel distance; Fig. 18 represents the cost of the solutions for this situation. The results are not different compared to the ones previously obtained for the distance restriction. This is because pickup and deliver sites are few, they are fixed, and thus distance restrictions impede long trips. Trucks cannot increase their travel distances and reach farther sites that could be reached with wider travel times. We can conclude that there is no advantage in having this extra time because there are no more sites to reach. We note that in this situation warehouse localization plays an important role in allowing a large number of possible new matches using extra-time. When trucks come from the same origin (the warehouse), cost savings for sharing are higher with almost the same travel distance. Consequently, the neighborhood would be better served by a unique nearby warehouse, if warehouses allow the late arrival. In contrast, in the presence of important travel distance restrictions, the farthest neighborhoods still cannot be served (so no feasible matches) and the logistic services will remain costly despite any freedom to arrive late.

Fig. 17
figure 17

Sensibility analysis on truck delays and customers’ locations on the # of trucks on road (ridding trucks) based on the fixed cost and variable costs

Fig. 18
figure 18

Sensibility analysis on truck delays and customers’ locations on the total cost

Discussion and managerial insights

In the following tables, we present a projection of emissions reductions obtained from the instances we simulated in previous sections. The interest is in knowing how much savings can be obtained by the stable matching that reduces one truck. On average, it is possible to see a distance saving by an adequate tour that usually departs and arrives at the same warehouse. Table 4 presents the average total traveling distance that trucks would have traveled when there is a feasible stable match, so those interesting cases that are prone to gas reductions. Table 5 presents the distance saved after finding and executing those stable matchings, thus reducing one truck. Finally, Table 6 shows the percentages of change. We note that these percentages are bigger when there are high variable costs. As mentioned before, when variable costs are higher, almost all matches are the ones happening in a common neighborhood. A neighborhood corresponds to a zone with many pickup and delivery sites, each near to another, and with a proximate warehouse. With the three tables it is possible to understand the reductions of traveled distance by subtracting one truck and re-rerouting its nodes with one single truck. These actions are directly related to gas consumption reductions and GHG emissions reductions but also related to the amount of variable costs, which plays an important role in forcing matches to happen in neighborhoods.

Table 4 Average of total traveling distance of the matching cases in the simulation
Table 5 Average of total traveling distance for matches cases and one truck has taken the pickup and deliveries
Table 6 Presents the difference of Tables 4 and 5 in percentage, showing the distance reductions which is directly related to the reduction of gas emissions

As shown in the previous figures, the variable cost is the most influential independent variable that impacts the number of matches, number of trucks and average traveling distance. In practice, variable costs are usually fuel cost, maintenance costs and drivers’ wages, but it could also consider other government taxations based on traveled distance. A reduction in gas consumption entails a reduction in GHG emissions. At the same time, the increase of variable costs is a deterrent to the platform’s use because feasible matches become economically uninteresting, based on the conceived scheme of sharing costs. Moreover, classical centralized solutions suggested in the literature would be more appropriate for cases with very high costs because they will effectively reduce distances of particular interest. However, the existence of high fixed cost is a good incentive for sharing trucks.

Allowing delays in the deliveries increases the number of matches, but this effect is reversed by the increases in variable costs, which penalize the number of matches, as is shown in the prior figures. The distance restriction added to the simulation, which tries to emulate pickups and deliveries within a neighbor, did not increase the number of matches because there is an important dependence on the distance to the warehouse and to the first point for pickup and delivery.

In summary, our results focus attention on interesting theoretical behaviors related to coalition development and stability, usually misled in the sharing economy literature’s focus on complex truck routing. For example, we note that despite the fact that high fixed costs push users to share, variable costs penalize long distances. In fact, we notice that variable costs can be very restrictive to finding feasible matches at the beginning and to make those matches stable, because shared benefits become small or even null. However, we have shown that the platform is useful for allowing bidders and requesters to find suitable savings and reduce gas emissions.

Conclusions and future research

This study shows the high potential of using a cooperative decentralized decision-support system for reducing travel distances and transportation costs in urban context. The decision-support system is an online and web-based platform service for cooperative LTL trucking using a bidder-requester model for delivering freight in cities. The model represents vehicle routing operations of several fixed pickup and delivery schedules where new deliveries are allowed from requesters within a time-window constraint. The decisional process for bidders and requesters is modeled following perfect matching market-design mechanisms and the profit-sharing mechanism is inspired from prior studies in goods consolidations and sharing economy. The simulations to validate the experiments rely on certain assumptions such as uniform distribution of locations in a plane with schedules for a fixed number of bidders and requesters. The main purpose of the decision-support system is to promote transportation cost reductions which leverage gas consumption and greenhouse gas emissions. Similar to other economic games, the online decision-support system shows the importance of fixed and variable costs in finding fair matches for bidders and requesters.

This platform facilitates the run of several small business-like stores, florists, franchises, restaurants, wine cellars and food yards on the one hand and parcel delivery contractors (on their own), on the other. They can develop loose relationships using the platform to keep pickup and delivery in the same journey. Another group could be tow trucks which have more than 1-car capacity and serve municipalities, police departments, insurance companies, car dealers and car rental companies vs the small internal fleets of these services. A final group could be construction contractors like painters, roofers, plumbers, isolation specialists, landscapers and gardeners, etc. which need to move equipment and tools for days. Some of them have truck rentals and also profit as specialized drivers and machine operators trying to keep their schedule full.

In order to enhance the performance of the platform, we propose to conduct additional real case studies based on real data, which will allow modeling actual bids and requests within real zones in urban areas. The use of real data provided by several rental trucks and delivery truck companies could help to refine the definition of a specific case study. Such case study could allow us to determine precisely the saved traveling distances and GHG emissions per hour and per day in urban context. Other important data to consider for the case study would be volumes, weights, and compatibility of cargo, which are very important characteristics in the city logistics business.

Further studies could also consider that optimal solutions might not always be achieved because the stable matching model that we propose could require extensive calculation time in real cases, which could discourage bidders and requesters from waiting for the final result of that ‘best match’. Therefore, the platform could be modified to calculate and propose ‘a second best’ match if users want to rely on it. The platform could also incorporate price adjustments to protect the entire system of faked requests or offers. Other sharing costs techniques, based on a fixed number of rewards, could also be explored in future research. Another future studies would consider the simulation of large disruptions that could destabilize stablished cooperation and thus decentralization may help to find temporal solutions using the platform.

It is important to notice that gas emissions reductions were calculated using Euclidean distances. However, distances within a city must deal with obstacles and natural fences (rivers, mountains, highways, etc.), which mean that distances are non-Euclidean and non-symmetrical and thus matching and routing could be more difficult than they actually are. Moreover, the platform only approximates the neighboring effect. We acknowledge that real distance between blocks and travel time between neighbors are important elements for simulating the matching process. Therefore, we suggest that future studies concentrate simulations in neighborhoods near a warehouse, which is also proposed in the literature.

We also plan to address in future research the problem of large disruptions that may destabilize cooperation. Decentralization may help to find temporal solutions considering an organised multi-delivery process to transition to a multi-independent platform, for offers and requests, and observe the case for short time decisions.

Another important issue is that carbon taxes pressure the industry to undergo carbon-emissions savings usually through emission-reduction technologies, like fuel-efficient engines or self-driving trucks. Nevertheless, truck sharing and cargo consolidation on last-mile delivery are major changes in the operational behavior that can cut emissions and reduce equipment or driver needs, thus reducing costs.