DESIGN AND OPTIMIZATION OF MILK-RUN
MATERIAL SUPPLY SYSTEM WITH
SIMULTANEOUS PICKUPS AND DELIVERIES IN
TIME WINDOWS
A Thesis submitted to Gujarat Technological University
for the Award of
Doctor of Philosophy
in
Mechanical Engineering
By
Dipteshkumar Rameshbhai Patel
Enrollment No.129990919004
under supervision of
Dr. Mulchandbhai B. Patel
GUJARAT TECHNOLOGICAL UNIVERSITY
AHMEDABAD
[November-2017]
i
DESIGN AND OPTIMIZATION OF MILK-RUN
MATERIAL SUPPLY SYSTEM WITH
SIMULTANEOUS PICKUPS AND DELIVERIES IN
TIME WINDOWS
A Thesis submitted to Gujarat Technological University
for the Award of
Doctor of Philosophy
in
Mechanical Engineering
By
Dipteshkumar Rameshbhai Patel
Enrollment No.129990919004
under supervision of
Dr. Mulchandbhai B. Patel
GUJARAT TECHNOLOGICAL UNIVERSITY
AHMEDABAD
[November-2017]
ii
© Dipteshkumar Rameshbhai Patel
iii
DECLARATION
I declare that the thesis entitled “Design and Optimization of Milk-Run Material Supply
System with Simultaneous Pickups and Deliveries in Time Windows” submitted by me
for the degree of Doctor of Philosophy is the record of research work carried out by me
during the period from October-2012 to March- 2017 under the supervision of Dr.M.B.Patel
and his has not formed the basis for the award of any degree, diploma, associateship,
fellowship, titles in this or any other University or other institution of higher learning.
I further declare that the material obtained from other sources has been duly acknowledged
in the thesis. I shall be solely responsible for any plagiarism or other irregularities, if
noticed in the thesis.
Signature of the Research Scholar: Date:….………………
Name of Research Scholar: Dipteshkumar Rameshbhai Patel
Place: Ahmedabad
iv
CERTIFICATE
I certify that the work incorporated in the thesis title as Design and Optimization of Milk-
Run Material Supply System with Simultaneous Pickups and Deliveries in Time
Windows submitted by Mr. Dipteshkumar Rameshbhai Patel was carried out by the
candidate under my supervision/guidance. To the best of my knowledge: (i) the candidate
has not submitted the same research work to any other institution for any degree/diploma,
Associateship, Fellowship or other similar titles (ii) the thesis submitted is a record of
original research work done by the Research Scholar during the period of study under my
supervision, and (iii) the thesis represents independent research work on the part of the
Research Scholar.
Signature of Supervisor: Date: ………………..
Name of Supervisor: Dr. M.B.Patel
Place: Ahmedabad
v
Originality Report Certificate
It is certified that PhD Thesis titled “Design and Optimization of Milk-Run Material
Supply System with Simultaneous Pickups and Deliveries in Time Windows” by Mr.
Dipteshkumar Rameshbhai Patel has been examined by us. We undertake the following:
a. Thesis has significant new work / knowledge as compared already published or
are under consideration to be published elsewhere. No sentence, equation,
diagram, table, paragraph or section has been copied verbatim from previous
work unless it is placed under quotation marks and duly referenced.
b. The work presented is original and own work of the author (i.e. there is no
plagiarism). No ideas, processes, results or words of others have been presented
as Author own work.
c. There is no fabrication of data or results which have been compiled /
analyzed.
d. There is no falsification by manipulating research materials, equipment or
processes, or changing or omitting data or results such that the research is not
accurately represented in the research record.
e. The thesis has been checked using https://turnitin.com (copy of originality
report attached) and found within limits as per GTU Plagiarism Policy and
instructions issued from time to time (i.e. permitted similarity index <=25%).
Signature of the Research Scholar: Date: ….…………..…
Name of Research Scholar: Dipteshkumar Rameshbhai Patel
Place: Ahmedabad
Signature of Supervisor: Date: ………………...
Name of Supervisor: Dr. M.B.Patel
Place: Ahmedabad
vi
Dipteshkumar Patel Thesis
ORIGINALITY REPORT
%17 %15 %12 %2 SIMILARITY INDEX INTERNET SOURCES PUBLICATIONS STUDENT PAPERS
PRIMARY SOURCES
www.ijsrd.com
%5 1
Internet Source
www.iieom.org
%2
2
Internet Source
Sule Itir Satoglu. "Design of a just-in-time %1
3
periodic material supply system for the
assembly lines and an application in electronics
industry", The International Journal of
Advanced Manufacturing Technology,
05/05/2012
Publication
ijaiem.org
%1
4
Internet Source
cdn.intechopen.com
%1
5
Internet Source
www.commerce.usask.ca
%1
6
Internet Source
www.iaeng.org
%1
7
Internet Source
vii
Publication
EXCLUDE QUOTES ON EXCLUDE MATCHES < 1%
EXCLUDE ON BIBLIOGRAPHY
Submitted to Tashkent International School %1 8 Student Paper
Liang Chun-Hua. "Vehicle routing problem %1
9
with time windows and simultaneous pickups and deliveries", 2009 16th International Conference on Industrial Engineering and Engineering Management, 10/2009
Publication
www.ijaiem.org %1
10 Internet Source
academicjournals.org %1
11 Internet Source
www.logistics.eng.chula.ac.th %1
12 Internet Source
ethesis.nitrkl.ac.in %1
13 Internet Source
14
Tasan, A.S. "A genetic algorithm based approach to vehicle routing problem with simultaneous pick-up and deliveries", Computers & Industrial Engineering, 201204
%1
viii
PhD THESIS Non-Exclusive License to
GUJARAT TECHNOLOGICAL UNIVERSITY
In consideration of being a PhD Research Scholar at GTU and in the interests of the
facilitation of research at GTU and elsewhere, I, Dipteshkumar Rameshbhai Patel having
Enrollment No.129990919004 hereby grant a non-exclusive, royalty free and perpetual
license to GTU on the following terms:
a) GTU is permitted to archive, reproduce and distribute my thesis, in whole or in part,
and/or my abstract, in whole or in part (referred to collectively as the “Work”)
anywhere in the world, for non-commercial purposes, in all forms of media;
b) GTU is permitted to authorize, sub-lease, sub-contract or procure any of the acts
mentioned in paragraph (a);
c) GTU is authorized to submit the Work at any National / International Library, under
the authority of their “Thesis Non-Exclusive License”;
d) The Universal Copyright Notice (©) shall appear on all copies made under the authority
of this license;
e) I undertake to submit my thesis, through my University, to any Library and Archives.
Any abstract submitted with the thesis will be considered to form part of the thesis.
f) I represent that my thesis is my original work, does not infringe any rights of others,
including privacy rights, and that I have the right to make the grant conferred by this
non-exclusive license.
g) If third party copyrighted material was included in my thesis for which, under the terms
of the Copyright Act, written permission from the copyright owners is required, I have
obtained such permission from the copyright owners to do the acts mentioned in
paragraph (a) above for the full term of copyright protection.
h) I retain copyright ownership and moral rights in my thesis, and may deal with the
copyright in my thesis, in any way consistent with rights granted by me to my University
in this non-exclusive license.
ix
i) I further promise to inform any person to whom I may hereafter assign or license my
copyright in my thesis of the rights granted by me to my University in this non-
exclusive license.
j) I am aware of and agree to accept the conditions and regulations of PhD including all
policy matters related to authorship and plagiarism.
Signature of the Research Scholar: Date: ….………………
Name of Research Scholar: Dipteshkumar Rameshbhai Patel
Place: Ahmedabad
Signature of Supervisor: Date: ….…………..….
Name of Supervisor: Dr. M.B.Patel
Place: Ahmedabad
Seal:
x
THESIS APPROVAL FORM
The viva-voce of the PhD Thesis submitted by Shri Dipteshkumar Rameshbhai Patel
(Enrollment No.129990919004) entitled Design and Optimization of Milk-Run Material
Supply System with Simultaneous Pickups and Deliveries in Time Windows was
conducted on …………………….………… (day and date) at Gujarat Technological
University.
(Please tick any one of the following option)
The performance of the candidate was satisfactory. We recommend that
he/she be awarded the PhD degree.
Any further modifications in research work recommended by the panel after 3
months from the date of first viva-voce upon request of the Supervisor or request
of Independent Research Scholar after which viva-voce can be re-conducted
by the same panel again.
(briefly specify the modifications suggested by the panel)
The performance of the candidate was unsatisfactory. We recommend that
he/she should not be awarded the PhD degree.
(The panel must give justifications for rejecting the research work)
Name and Signature of Supervisor with Seal
1) (External Examiner 1) Name and Signature
2) (External Examiner 2) Name and Signature
3) (External Examiner 3) Name and Signature
xi
ABSTRACT
Material handling is one of the most crucial issues that should be taken into account for
eliminating waste, reducing the cost and just in time-based delivery of the product. Many
industries are spending millions of bucks for the transportation of the goods. An effective
transportation management system has to be implemented to control the cost of
transportation and inventory. The optimized milk-run concept can be utilized to overcome
the issue related to the supply chain management system. The milk-run material supply
system is the cyclic trips, where either good are collected from several suppliers and
delivered to one customer, or goods are collected from one supplier and delivered to several
customers. The objective of this research is the minimization of the total material handling
and inventory holding cost. It is also concentrated on just in time delivery to enhance the
customer satisfaction. These saving of cost could be either used for reduction of the product
cost, which will boost up the sales or lift the profit margin of the organization.
The purpose of this research is to develop a mathematical model and a heuristic approach,
which is utilized to construct the routes, calculate the associated cost and determine the
service period for the design of a milk-run material supply system with simultaneous pick-
up and delivery. The material supply by this system occurs on a just-in-time basis from
regional offices to several stations of the courier service. Besides, the proposed heuristic
approach intends to construct routes based on an initial service period value and attempts
to improve the solution by considering different period values. Furthermore, the scheduling
of the vehicles is calculated based on demands and routes of the network. The most
optimum solution is decided on the basis of the least total transportation cost and minimum
time. A genetic algorithm is proposed to solve the vehicle routing with simultaneous pickup
and delivery within time frame (VRPTWSPD) problem related to the milk-run concept.
The algorithm is applied with the help of Matlab and results are presented. The result
showed the performance and effectiveness of the algorithm
xii
ACKNOWLEDGEMENT
I would like to take an opportunity to express my sincere appreciation, who have guided
and supported me during this journey.
Firstly, I am extremely grateful to my honorable supervisor Dr. M. B. Patel, for his
continuous guidance, motivation, encouragement and support for throughout my research
work. His guidance helped me in all the time of research and writing of this thesis, I could
not have imagined having a better advisor and mentor for my research work.
I would like to express my sincere thanks to Dr. Jeetendra Vadher for valuable guidance.
His deep insights supported me at various phases of my research. His valuable suggestion
and constructive criticisms from time to time enabled me to complete my work
successfully.
Besides my advisor, I would like to appreciate to my Doctoral Progress Committee Members
Dr. Jeetendra Vadher, Professor, Government Engineering College, Palanpur and Dr.
Mangal Bhatt, Professor, Shantilal Shah Engineering College, Bhavnagar for their rigorous
examinations and precious suggestion during my research.
I am thankful to Dr, Akshai Aggarwal, Ex. Vice Chancellor, Dr. Navin Sheth, Vice
Chancellor, Shri J. C. Lilani, Registrar and all staff members of Ph.D. Section, GTU.
I would also like to acknowledge the guidance provided by each and every member of
Shankersinh Vaghela Bapu Institute of Technology, Gandhinagar. Without their
support, it may not be possible to reach at this stage of my journey of research.
Finally, I would like to thanks my father Mr. Rameshbhai Patel and my mother Mrs.
Bhanumati Patel for supporting me spiritually during a hard time of this journey. I would
also like to thank my beloved wife Kinjal Patel and my son Aarav for their unconditional
love and moral support.
xiii
Table of Contents
CHAPTER - 1 Milk-run material supply system ……………………………………….1
1.1 Introduction ...…………………………………………………………………………..1
1.2 Milk-run concept ...……………………………………………………………………..2
1.3 History of milk-run material supply system ...…………………………………...….….3
1.4 Lean logistic ...………………..……………………………………………………. .…3
1.5 Major challenges of the material supply system ..………………………….…………..4
1.6 Heuristic search algorithm .……………………………………………….……..……...5
1.7 Keywords .…………………………………………………………………....…………8
CHAPTER - 2 Literature review .…………………………………………………..........9
2.1 Just in time material supply system ………………………….…………………………9
2.2 Vehicle routing in milk-run operations .……………………………………………....11
2.3 Classification and modelling for milk-run distributions system ………...…………....12
2.4 Vehicle routing and scheduling ……………………………………………………….13
2.5 VRP with time windows and simultaneous pick-up and delivery …………………….15
2.6 VRP with split loads …………………………………………………………………..17
2.7 Flexible milk-run for stochastic vehicle routing ………………………………………18
2.8 Milk-run vehicle routing approach for shop-floor logistics …………………………..19
2.9 Milk-run distribution system for the express industry ………………………………...19
2.10 Robust optimization approach for milk-run problem with time window ……….…...20
2.11 Heuristic algorithm for single and multiple depot in VRP …………………….….....21
2.12 VRP with simultaneous pick-up and delivery based on customer satisfaction ……...23
2.13 Milk-run approach by genetic algorithm …………………………………….………23
2.14 Simultaneous pick-up and delivery in VRP with hybrid and multi-objective GA…...25
2.15 Modelling issues and heuristic solution approaches in VRP …………………….......27
2.16 Hybrid meta-heuristic algorithm for VRPSPD problem ………………………..…...27
2.17 Simultaneous pick-up and delivery with decision support system …………….….....28
2.18 Milk-run problem with time windows under inventory uncertainty …………….......30
2.19 Effect of milk-run supply system in global warming ……………….…………..…...31
2.20 Research Gap ………………………………………………………………………...32
CHAPTER - 3 Necessity, Objective and scope of study..……………………………....34
3.1 Problem Statement …………………………………………………………………….34
3.2 Necessity ………………………………………………………………………………34
xiv
3.3 Objective of research work ……………………………………………………………35
3.4 Scope of study ………………………………………………….……………………..36
3.5 Methodology of research ……………………………………………………………...37
CHAPTER - 4 Research methodology ………………………………………………….39
4.1 Formulation of mathematical model ……………………………………….………….39
4.1.1 Assumptions …………………………………………………………….....………..39
4.1.2 Objective function …………………………………………………………..………39
4.1.3 Constraints …………………………………………………………………..………40
4.1.4 Notations ……………………………………………………………………..……...41
4.2 Heuristic approach ………………………………………………………………..…...42
4.2.1 Tabu search algorithm ………………………………………………………………43
4.2.2 Simulated annealing …………………………………………………………….......45
4.2.3 Prim algorithm ………………………………………………………………..…......46
4.2.4 Genetic algorithm ……………………………………………………………..….....49
4.3 Validation ………………………………………………………………………..……50
4.3.1 Existing material supply system ……………………………………………….……51
4.3.2 Milk-run material supply system ………………………………………………........51
CHAPTER - 5 Result and discussion …………………………………………………...68
5.1 Development of routes ………………………………………………………………...68
5.1.1 Mehsana zone …………………………………………………………………….....69
5.1.2 Ahmedabad zone ………………………………………………………………........71
5.1.3 Rajkot zone …………………………………………………………………….........74
5.1.4 Vadodara zone ………………………………………………………………………77
5.1.5 Surat zone ……………………………………………………………………...........79
5.1.6 Gujarat region ………………………………………………………………..……...81
5.2 Express service ……………………………………………………………….….........83
5.3 CO2 emission …………………………………………………….……………...…….85
5.4 Vehicle routing database ………………………………………………………...........87
5.5 Development of routes with uncertain demand ………………………………….........89
CHAPTER - 6 Conclusion and future scope ……………………………………….......93
6.1 Conclusion ………………………….…………………………………………………93
6.2 Future scope ……………………………………………………………………….......94
List of references ……………………..…………………………………………………..95
List of publication ………………………………………..……………………………..102
xv
List of Abbreviations
VRPTWSPD Vehicle Routing with Simultaneous Pickup and Delivery with Time
Window
VRP Vehicle Routing Problem
JIT Just In Time
GA Genetic Algorithm
JITVRP Just In Time Vehicle Routing Problem
JITVRPSPD Just In Time Vehicle Routing with Simultaneous Pickup and
Delivery
CVRP Capacitated Vehicle Routing Problem
VRPTW Vehicle Routing Problem with Time Window
VRPB Vehicle Routing Problem Backhauls
VRPPD Vehicle Routing Problem with Pick-Up and Deliveries
MDVRP Multiple Depots Vehicle Routing Problem
PVRP Periodic Vehicle Routing Problem
SDVRP Split Delivery Vehicle Routing Problem
VRPSPD Vehicle Routing Problem Simultaneous Pick-Up and Delivery
MCPSO Multi Swarm Cooperative Particle Swarm Optimization
VRPSDPSLTW Vehicle Routing Problem Simultaneous Deliveries and Pickups with
Split Loads and Time Windows
VRPSDPD Simultaneous Pickup and Delivery for Single Depot and Multiple
Depot
TSSA Tabu Search and Simulated Annealing
SA Simulated Annealing
DSS Decision Support System
GPS Global Positioning System
TSP Travelling Salesman Problem
xvi
List of Figures
FIGURE 1.1: Milk-run supply system for manufacturing unit ……..……….……….…..2
FIGURE 1.2: Flow chart of genetic algorithm …………………………...…….…….…..7
FIGURE 2.1: Milk-run supply procurement system ..……………………….…….…….11
FIGURE 2.2: Classification of milk-run distribution system ……..………….………...13
FIGURE 2.3: Vehicle routing example ..……………………………………...………...14
FIGURE 2.4: Classification of VRP …………………………………………..………...16
FIGURE 2.5: Construction of path …………………………………………...………...20
FIGURE 2.6: Vehicle routing in multiple depot ……………………………...………....22
FIGURE 2.7: Vehicle routing by multi-objective genetic algorithm …………………..26
FIGURE 2.8: Components of VRP in decision support system ……………..………....29
FIGURE 4.1: Flow chart of tabu search ……………………………..………..…………44
FIGURE 4.2: Flow chart of simulated annealing …………………………...…………...46
FIGURE 4.3: Flow chart of prim algorithm ………………………………...…………...48
FIGURE 4.4: Flow chart of genetic algorithm ………….………………...…..…………50
FIGURE 5.1: Map of Gujarat state ………………………………...…….……………...69
FIGURE 5.2: Scheduling and routing for route 1 for Mehsana zone ………….………..70
FIGURE 5.3: Scheduling and routing for route 2 for Mehsana zone…..………………..70
FIGURE 5.4: Scheduling and routing for Mehsana zone ………………….………..…..71
FIGURE 5.5: Scheduling and routing for route 1 for Ahmedabad zone………….……..72
FIGURE 5.6: Scheduling and routing for route 2 for Ahmedabad zone ………………..72
FIGURE 5.7: Scheduling and routing for route 3 for Ahmedabad zone ………………..73
FIGURE 5.8: Scheduling and routing for Ahmedabad zone ……………….…....…..….73
FIGURE 5.9: Scheduling and routing for route 1 for Rajkot zone ………….…………..74
FIGURE 5.10: Scheduling and routing for route 2 for Rajkot zone …………….………75
FIGURE 5.11: Scheduling and routing for route 3 for Rajkot zone …………….………75
FIGURE 5.12: Scheduling and routing for route 4 for Rajkot zone ………….………....76
FIGURE 5.13: Scheduling and routing for Rajkot zone ………………………...………76
FIGURE 5.14: Scheduling and routing for route 1 for Vadodara zone………….……....77
FIGURE 5.15: Scheduling and routing for route 2 for Vadodara zone ………...….........78
FIGURE 5.16: Scheduling and routing for Vadodara zone ……………...……….……..78
xvii
FIGURE 5.17: Scheduling and routing for route 1 for Surat zone ……………...………79
FIGURE 5.18: Scheduling and routing for route 2 for Surat zone …………...…………80
FIGURE 5.19: Scheduling and routing for Surat zone …………………..…….………..80
FIGURE 5.20: Scheduling and routing of Gujarat region ……………………….……...81
FIGURE 5.21: Express service from Unjha to Vapi …………………………….............84
FIGURE 5.22: Express service from Rapar to Godhara …………………………...........84
FIGURE 5.23: Express service from Junagadh to Gandhinagar …………………..........85
FIGURE 5.24: CO2 emission of Gujarat region ………………….………………..........86
FIGURE 5.25: Vehicle routing android application …………………………………….87
FIGURE 5.26: Vehicle routing weight analysis …………………………………...........88
FIGURE 5.27: Development of routes with uncertain demand (Case: 1) ………………90
FIGURE 5.28: Development of routes with uncertain demand (Case: 2) ………………91
FIGURE 5.29: Development of routes with uncertain demand (Case: 3) ………………92
xviii
List of Tables
TABLE 4.1: Comparison of Various Algorithms for Milk-Run Supply System ……..……43
TABLE 4.2: Existing Material Supply System ………………….………………………...51
TABLE 4.3: Milk-run Material Supply System ………………….……………………......51
TABLE 4.4 Comparison of Existing and Milk-Run Supply System…..…………………...67
TABLE 5.1: Comparison of Conventional Supply System and Milk-Run Material
Supply System (Distance and Overall Cost) …………….…………………...82
TABLE 5.2: Comparison of Conventional Supply System and Milk-Run Material
Supply System (Travelling Time) …………………………………………...83
xix
List of Appendices
Appendix 1: Graphical User Interface……………………………………………..…..…103
Appendix 2: Database of Destination City……………………………………………..…108
Appendix 3: Database of Starting City………………………………………………....…112
Appendix 4: Calculation of CO2 Gas Emission …………………………..…………...…116
Appendix 5: Coding of Milk-Run Routing Supply System ………………….……..……121
Appendix 6: Multiple Travelling Salesman Problem with Genetic Algorithm ….…......…125
Appendix 7: Milk-Run Route with Weight Distribution ………...………………..….…..136
Appendix 8: Scheduling Of Individual Routes…………………………………….…..…143
Appendix 9: Graphical Representation of Milk-Run Routing System…………….......….149
Appendix 10: Construction of Express Routing…………………………….……..……...158
Appendix 11: Development of Dynamic Milk-Run Material Supply System...………......162
1
CHAPTER – 1
Milk-Run Material Supply System
1.1 Introduction
Material handling is a field of growing interest for both industries and research institutions.
Enormous rivalry in today’s global markets, the range of products with shorter life cycles, and
the higher expectations of consumer markets have enforced suppliers to concentrate on their
supply chains services. This, together with innovation and invention in communications and
transportation technologies has encouraged the continuous evolution of the supply chain
techniques. Consequently, to shrink cost and enhance service facility, operational supply chain
policies need to be taken into account.
The supply chain, which is also referred to as the logistics network involves a bunch of varieties
of management (suppliers, manufacturing unit, warehouses, distribution point, and retail
outlets). The material supply system includes the movement of goods from a supplier to a
customer, as well as any customer who returns to the supplier in a logistic distribution network.
It involves supply, storage and control of materials and products throughout distribution in the
system. Material supply system plays an important role in manufacturing and logistic. The
vehicle routing problem is a common central problem in various industries, required to
optimally route a fleet of vehicles to several sets of consumers with simultaneous pickup and
delivery. The environment in which industries nowadays accomplish their supply chain is highly
vigorous. If an effective material supply system is established, it is claimed that the cost will be
reduced by 10% to 30% [2]. Moreover, in a typical manufacturing industry, material handling
accounts for 25% of workers, 55% of all factory space, and 87% of the production time [3].
Milk-Run Material Supply System
2
1.2 Milk-Run Concept
A milk-run is an effective logistic system, which is round trip that facilitates either delivery or
pick-up of the goods. Milk-run supply system can be primarily classified into two categories
external milk-run system and internal milk-run system. Internal milk-run systems consist of
supply of parts from origin to the destination that takes place inside the plant. External milk-run
supply system involves product delivery from main warehouses (origin) to the customer
(destination). Application of milk-run distribution systems in plants is to standardize the
material handling system and eliminates the waste effectively.
Milk-run material supply system is the round trips, where either goods collected from multiple
suppliers and transported to single customer or goods collected from a single supplier and
transported to multiple customers within the predefined path (Fig. 1.1) in a cyclic manner. The
size and length of the routes are predefined, which are considered according to the volume of
the product and carrying capacity of the vehicle. The allocated vehicle has to travel through the
assigned routes at the time of collection or the delivery of the products.
FIGURE 1.1: Milk-Run Supply System for Manufacturing Unit
(Source: http://3rdpartylogistics.blogspot.in/2011/09/what-is-milk-run-system-transportation.html)
History of Milk-Run Material Supply System
3
This research describes “milk-run” as a concept that is a sequential collection of the product
from multiple sources and the direct service to the delivery points within the time frame. The
prime objective of the milk-run material supply system is to minimize the total transportation
and inventory cost.
1.3 History of Milk-Run Material Supply System
The word “milk-run” was introduced in the USA by the milkman during the 19th century, who
used to supply the milk bottles at the door steps of each customer. On the daily basis, the
milkman simultaneously used to deliver the full bottles of milk and pick-up the empty bottles in
the cyclic trip. At the end of the trip, he used to return with the bunch of empty bottles, which
got filled on the next day and trip initiated with the starting point again. During the 20th century,
this technique was implemented in industrial supply chain management system by the
organisation. Soon it became significant concept among many industries due to better control
of inventory and total production cost. Later on, milk-run concept was implemented in aircraft
industries with a long distance flight with multiple stops, military patrol route surveillance,
public transport, courier services and many logistic industries. Nowadays it has become the
significant tool in logistic services of various field of the organisation. Even within the area of
milk-run material supply system, a number of developments have occurred over the past years.
1.4 Lean Logistic
Lean logistics is always driving innovation in the supply chain management system and
enormous benefits are drawn by innovative technology for organisations and consumers. The
objectives of the lean logistics are the delivery of the right mix of products at the right time to
the right place, and carry out these activities, effectively [1]. Assembly lines must satisfy the
customer’s demand neither late nor early, because early production incurs inventory holding
cost and late production causes either loss of sales or backlog. Therefore, part’s supply to the
point of use on the assembly line must be also achieved just-in-time (JIT). Otherwise, either
time losses may occur due to disorganized and insufficient material supply to the assembly line
or excess inventory accumulates that further increases loss to the industries. The exact number
Milk-Run Material Supply System
4
of parts must be delivered to prevent inventory holding. Product delivery within just-in-time
enhances the reliability and satisfaction among the customers.
1.5 Major Challenges of the Material Supply System
The business environment has become increasingly competitive. Industries keep looking to find
a better way to manage and reduce the cost associated with the product. Supply chain
management plays a vital role as logistics costs have a major involvement in total production
cost. Many industries have implemented the just-in-time system to reduce total production costs.
On the other hand, the customer expectations have gone upwards to the sky due to the supersonic
era, while the capability of rivals to deliver superior quality within the short period of time and
at low cost has changed the phase of supply chain management. Uncertainty in demand affects
industries to manage the travel time of the vehicle, reliability among the customer, total transport
cost and inventory holding cost, which will lead dispersed industries to take the prices down
with no or less profit to sustain in the global competition or to remain competitive.
Today, assembly lines usually require many types of components at different stages of assembly
operations simultaneously. The need to move small quantities of a large number of items within
the plant with short and predictable lead times without increasing transportation costs resulted
in the development of milk-run material delivery systems [1]. The milk-run delivery system
picks up and delivers containers of parts along the fixed routes, each comprised of a
predetermined set of stock points of the stations of an assembly line, based on a schedule.
Therefore, integration of pull production control with the milk-run part supply system for the
assembly lines is beneficial. The way of creating an economical advantage is to maintain a
highly sustainable material supply system. Thus, logistics becomes an integral measure of the
product that is being delivered to the customer.
The trend of migrating to the urban area is increasing day by day for better education and
economic conditions, including availability of employment opportunity and higher pay rate in
major cities. At the forefront of the urbanization trend, traffic congestion issue is often reported
in the urban area. As the density of traffic increases on highways and urban roadways, supplier
and delivery service operators have a major challenge to cope with predefined schedules. The
Heuristic Search Algorithm
5
costs incurred as an effect of traffic jams are higher in the urban and its associated area. It has
been experienced by the shippers and carriers, that there are the day-to-day cost implications of
delay and the reliability increases which affects supply chain management adversely. It has now
become inevitable to adopt the innovative technique to deal with a major challenge of the globe.
The milk-run material supply system is a powerful tool to optimise the utilisation of vehicles in
supply chain network.
1.6 Heuristic Search Algorithm
The word heuristic is derived from ancient Greek region known to discover or to find something
innovative, is an approach to solve a practical cumbersome problem, solving by employing a
practical method associated with real life issue. It is used for algorithms which find best
solutions between all imaginable ones. The best example of heuristic search method is the
travelling salesman problem. Heuristic doesn’t ensure that the optimal solution will be found,
but these will be usually close to the optimal. Although the solution finding process is fast,
reliable and easy, most of the time this solution can be accurate that is actually near to the
optimum value. Therefore, a heuristic approach is beneficial to get close to the optimal solution,
within small computational time.
A genetic algorithm was introduced in 1970 by John Holland, in early to mid-1980s, genetic
algorithms were being applied to a broad range of subjects. A genetic algorithm is a heuristic
search algorithm based on mechanics of natural selection and genetics. This heuristic approach
is habitually used to produce suitable results for the optimization of the problem. It is an
evaluation theory which makes the selection natural to produce powerful next coming
generations. The genetic algorithm follows the principle of survival of the fittest laid down by
Charles Darwin. The basic components of the genetic algorithms are chromosomes, population,
fitness function, genetic operator (reproduction, crossover, mutation) and generations. The
random population contains a number of different chromosomes which have different objective
function results. A chromosome consists of genes which represent candidate solution or
features. The algorithm constantly modifies population of an individual solution by a fitness
function. At each phase, the genetic algorithm randomly selects individual from the recent group
Milk-Run Material Supply System
6
of populations, called parents and generate the children as a future generation. This process is
repeated until the population convert into an optimal solution.
The flow chart (Fig. 1.2) describes the process of a genetic algorithm. The algorithm begins by
creating a random initial population. The algorithm then creates a sequence of new populations.
At each step, the algorithm uses the individuals in the current generation to create the child of
next generation population. To create the new population, the algorithm performs the following
steps:
It scores each member of the current population by computing its fitness value.
Parents are selected based on their fitness.
Some of the individuals in the current population have lower fitness value, which are
chosen as elite. These elite individuals are passed to the next population.
Children are produced from the parents of current generation. These children are formed
either by making random changes to a single parent (mutation) or by combining the
vector entries of a pair of parents (crossover).
New produced generation replaces the current population with the children to form the
next generation.
Heuristic Search Algorithm
7
FIGURE 1.2: Flow Chart of Genetic Algorithm
This process runs until the stopping criteria is met, that is the optimum solution of the problem.
There is a wide range of application of the genetic algorithm. It has been widely accepted in
many industries in various areas, some of them are described as below,
Optimization
Automatic Programming
Machine Learning
Economics
Gen = 0
Create initial random population
Designate best chromosome
found so far as a solution
Yes
Evaluate fitness of each individual in population
Reproduction
Crossover
Mutation
Gen = Gen + 1
If Gen=N
End
No
Milk-Run Material Supply System
8
Immune systems
Ecology
Evolution and learning
Social systems
Scheduling
Layout and circuit design
Management Applications
Control
VLSI Design
Identification & Pattern recognition, etc.
1.7 Keywords
Supply Chain Management, Logistics, Vehicle routing problem, Just-in-time, Milk-run problem
with time window, Material supply system, Simultaneous pick-up and delivery, Lean logistic,
Optimization, Heuristic approach, Genetic algorithm, Mathematical model, Linear
programming, Inventory holding cost, Transportation cost, Penalty cost, Fixed cost.
9
CHAPTER – 2
Literature Review
An extensive literature survey was carried out on the theme of the milk-run material supply
system and optimisation of the vehicle routing problem with simultaneous pick-up and delivery
considering time window. During the review of milk-run supply chain management, papers of
two inter-related topics were studied: internal and external milk-run material supply system. The
various optimisations mathematical methods (algorithm) were reviewed and analysed to
understand the effect and limitations of computer modelling in solving vehicle routing problem.
The study literature review has directed to the necessity of the research in the field of supply
chain management for effective optimisation as transportation cost has a significant impact on
overall cost of the product or service.
2.1 Just-in-time Material Supply System
The just-in-time material supply system is the logistics measurement of the lean manufacturing
[1]. It represents lean philosophy to logistic activities supported within the plant among the
suppliers and the manufacturer. Vaidyanathan et al. [4] analysed the JITVRP (Just-in-time
vehicle routing problem) and emphasized the unique characteristic of this problem. JITVRP
requires that the quantity to be delivered at each of the demand nodes is a function of the route
taken by the vehicle assigned to serve that node. The authors developed a nonlinear
mathematical model for vehicle routing problem, relaxed it by making some assumptions and
proposed a linear model that attempts to determine the lower bound for the number of vehicles
required [4]. Moreover, a two-stage heuristic algorithm was proposed in research work, for the
optimal solution of the problem. Satoglu S. and Sahin E. [15] explained JIT periodic material
supply system for an assembly line. They approached heuristic algorithm and mathematical
method for routing. However, the researchers did not attempt scheduling of the vehicles in their
research.
Literature Review
10
The objective of the proposed mathematical model is the minimization of the total transportation
and inventory cost [15]. The proposed heuristic approach is anticipated for the construction of
routes based on an initial service period value and attempts to improve the optimal solution by
considering different period values.
Domingo et al. [9] explained an implementation of the milk-run material supply system that
serves a lean assembly line. Researchers have followed a practical approach. Initially, the stock
points where pickups and deliveries were determined. Then, the sequence of operations was
defined and alternative feasible routes were identified. The stock points with high demand rates
and those with lower demand rates were included in two separate routings. Then, the pickup and
delivery schedule were determined. However, the researchers did not attempt to make an
optimal milk-run delivery system design. Alvarez et al. [10] presented a case study of the
redesign of an assembly line by using lean production tools. To reduce lead time and excessive
stocks and to improve material flow within the manufacturing system, Kanban-based production
control and a milk-run material handling system were implemented. The authors realized that
the design of Kanban production control system is insufficient without implementing an
appropriate material handling vehicle [10]. Boysen and Bock [11] considered scheduling JIT
part supply to a mixed-model assembly line where assembly line and the warehouse are at
different factory floors. The authors used dynamic programming and simulated annealing for
the solution of the problem. Hao and Shen [8] developed a prototype software system that
integrates discrete event simulation with agent-based simulation technique to evaluate the
performance of a Kanban-based milk-run system serving an assembly line. In addition, Nemotoa
et al. [16] explained JIT external milk-run applications of the Toyota automobile assembly
factories located in Thailand. It has been revealed by the case study that implementing the milk-
run supply system even under highly congested traffic conditions can have full control on the
procurement process, which reduces the number of vehicles in supply network by optimisation.
It resolves the traffic problem to some extent level in urban areas and highways.
Vehicle Routing in Milk-Run Operations
11
2.2 Vehicle Routing in Milk-Run Operations
The vehicle routing involves optimisation of the routes for a fleet of vehicle to several sets of
consumers and supplier. In large scale industries, various transportation systems are considered
in order to deliver the material. However, it is very complicated especially dealing with large
scale industries with an enormous number of materials need to be delivered at various locations
[20]. Theeratham Meethet and Manoj Lohatepanont [21] have addressed the vehicle routing
problem in a milk-run system by applying optimization techniques to find the overall material
handling cost minimizing milk-run plan and satisfying the demands.
FIGURE 2.1: Milk-run Supply Procurement System [21]
The milk-run operation usually consists of a sequential collection of the goods from the various
supplier and delivery to the central warehouse. The milk-run material supply system can
increase vehicle utilization efficiency by doing the round trip to collect only required amount of
parts from each supplier shown in fig. 2.1. The authors have proposed a mathematical model
expressing two solution approaches; an ordinary mathematical programming algorithm and a
column generation based branch and bound algorithm. The model was tested with large scale
real world problems. The results described that the column generation based branch and bound
algorithm can solve the problems relatively quickly but at the expense of more complicated
Literature Review
12
implementation [21]. Authors also described that solving a problem by column generation based
branch and bound algorithm requires three efficient components: (i) linear programming solver,
(ii) branch and bound framework, and (iii) column generation implementation, whereas
mathematical modelling solve the problem with fewer resources.
Large scale real life manufacturing problem requires a different logistic approach to cope with
the demand of various goods. Effective vehicle routing approach needs to be adopted to bolster
the industries against the vehicle capacity and time consumption issues. Milk run schedule
approach is deliberated as a distinct vehicle routing problem (VRP) with time windows and a
restricted number of fleets. David Gyulai et al. [21] have proposed local search algorithm for
vehicle routing. Innovative approach has introduced that employ a primary solution generation
algorithm and a local search method to solve the milk run problem. The software prototype has
been verified with real-life industrial data to determine the abilities of the proposed solution.
The aim of authors is to test the model in real life condition to minimize the requirement of
vehicles in the supply chain network by reducing the time of the trip.
2.3 Classification and Modelling for Milk-Run Distributions System
Milk-run material supply system can be classified in various ways according to the application
in industry. Huseyin Selcuk Kilic et al. [37] have used assignment methodology for the
classification and modelling of the problem. The milk-run distribution system can be divided
into three main categories; such as general assignment problem, dedicated assignment problem
and determined time periods assignment problem as shown in fig. 2.2. Each main category can
be subdivided based on a number of routes and service period of the vehicle. The first category
general assignment problem can be sub divided as one routed vehicle and multiple routed
vehicles as routes and time period is unknown. These can be further divided as differently time
period and equally time period according to the time period. Dedicated assignment problem can
also be divided as differently time period and equally time period since the routes are known
but time period needs to be determined. The last category is sub divided into the one routed
vehicle and multiple routed vehicles since time periods are known but routes are unknown.
Vehicle Routing and Scheduling
13
FIGURE 2.2: Classification of Milk-run Distribution System [37]
Authors have proposed mixed integer linear programming model for the category called
“determined time period assignment problem” with multiple routed vehicle where the service
period time was known but a number of vehicles and routes are unknown. The results are
analyzed by constructing the numerical example. The result is compared to check the
performance; such as time and cost. However, it is seen that optimum result is difficult to
achieve in a large problem. More efficient heuristic approach needs to be developed for such
kind of problem.
2.4 Vehicle Routing and Scheduling
The scheduling of customer service and the routing of vehicles play a vital role in the supply
chain management system. Both the routing and scheduling of service vehicles have a major
impact on the quality of the supply chain industries. The objective of most routing and
scheduling problems is to minimize the total transportation cost of service within the predefined
Milk-run distribution
system
General
assignment
problem
Dedicated
assignment
problem
Determined
time period
assignment
problem
One
routed
vehicle
Multiple
routed
vehicle
Differently
time
period
Equally
time
period
Equally
time
period
Differently
time
period
Equally
time
period
Differently
time
period
One
routed
vehicle
Multiple
routed
vehicle
Literature Review
14
time. This includes vehicle capital costs, running cost, and fixed costs. The classification of
routing and scheduling problems depends on the size of the supply network, capacities of the
vehicles, and routing and scheduling objectives of the delivery system. It is classified as
travelling salesman problem, multiple travelling salesman, vehicle routing problem, Chinese
postman problem.
FIGURE 2.3: Vehicle Routing Example [36]
Routing and scheduling problems are often represented by graphical networks. Fig. 2.3 shows
the example of vehicle routing problem. It consists of five circles called station. Four stations
(2, 3, 4, and 5) represent pickup and delivery points, and remaining one station (1) represents a
depot. Tour of the vehicle initiated from the depot, which passes through each station and returns
to the origin at the end of the trip. Authors have discussed the features of vehicles routing,
vehicles scheduling, combined vehicles routing and scheduling problems. Various mathematical
programming methods are described to obtain an optimal solution for such types of problems.
Vehicle routing and scheduling of vehicles are an important factor to be handled by supply
chain service provider. An effective planning requires ensuring the necessity of the consumers
in terms of time and cost effectiveness. However, the objectives may vary according to the
nature of business; such as reducing customer inconvenience and reducing the time to serve the
VRP with Time Windows and Simultaneous Pick-Up and Delivery
15
customer. A solution of routing and scheduling problems initiates with an explanation of the
features of the service; such as whether activity on the nodes or the arrows, delivery-time
constraints, and capacity of vehicles. Several heuristic solution approaches can be employed to
obtain an effective solution. Authors have presented the nearest neighbor procedure and the
Clark and Wright savings heuristic for solving the vehicle routing and scheduling problem [36].
2.5 VRP with Time Windows and Simultaneous Pick-Up and Delivery
Vehicle routing problem simultaneous pick-up and delivery is a complex version of the classical
vehicle routing problem (VRP). This service often arise in supply chain network, for example
in the delivery of the product with the exchange offer, where new product needs to be delivered
to the consumer’s door step and against the new one, old or used product has to be picked-up
from the consumer within the certified time period. Another example is delivering perishable
goods to the retailer and collection of the empty container from the retailer for the packing
purpose within the predefined time period as there will be chances of loss if the product gets
melt. There are many types of VRP models which are employed according to the nature of
problem, such as Capacitated VRP (CVRP), VRP with time window (VRPTW), VRP with
backhauls (VRPB), VRP with pick-up and deliveries (VRPPD), Multiple depots VRP
(MDVRP), Periodic VRP (Deliveries in some days) (PVRP), Split delivery VRP (SDVRP);
which are shown in fig. 2.4. Some of the studies have considered time windows and VRPSPD
(vehicle routing problem simultaneous pick-up and delivery). Angelelli and Mansini [13]
formulated a mixed-integer nonlinear model of the VRP with time windows and simultaneous
pickup and delivery. The term of “time windows” means that the material handling vehicle's
pickup and delivery service at a supplier must be initiated and finished between the predefined
time periods.
Literature Review
16
FIGURE 2.4: Classification of VRP [19]
Vehicle routing problem with time window simultaneous pick-up and delivery (VRPTWSPD)
system involve both; delivery of a product from warehouse to the consumer and pick-up and
return goods from the consumer to the warehouse and each task time window, penalty cost may
implant due to the slow movement. Xiaobing Gan et al. [25] have worked on the uncertainty of
the number of vehicle and simultaneous delivery and pick-up service. The mathematical model
is constructed with the objective of optimum transportation cost. Multi swarm cooperative
particle swarm optimization (MCPSO) algorithm is applied and two dimensions encoding
method is proposed for VRPTWSPD. The result indicates that MCPSO algorithm is more
effective, simple and robust. It can be more significant for transport industries in the real world.
The proposed encoding method is beneficial to uncover and deal with the hidden problems
associated with the material supply system.
VRP with Split Loads
17
2.6 VRP with Split Loads
The concern of split load in vehicle routing problem is taken into account when the load
allocated to a particular vehicle is having irregular size than the capacity of a single vehicle. The
use of split loads method could minimize the total transportation cost at an extent level. Several
studies have been carried out on split load vehicle routing problem. Various heuristic methods
have been applied to resolve the problem. Ohlman, Fry and Thomas [14] considered the VRP
with time windows and split deliveries, where demands are picked up from a network of
suppliers and goods are delivered to the depot of a lean production system. The authors divided
the problem into two phases: the routing phase and the scheduling phase that is solved by a
heuristic approach. Similarly, Chuah and Yingling [5] developed a nonlinear mathematical
model of the VRP with time windows and considered high-frequency and small-quantity
deliveries from suppliers to a JIT assembly plant. Yong Wang et al. [23] formulated mixed
integer model for vehicle routing problem with simultaneous deliveries and pickups with split
loads and time windows. A hybrid heuristic algorithm is developed to solve the problem of
VRPSDPSLTW. Solomon datasets are applied with minor modifications to test the
effectiveness of the solution algorithm. The proposed algorithm established optimal solution
approaches for VRPSDPSLTW in terms of the total transportation cost, utilisation of vehicles
and loading rate. It might work as a universal analytical tool for optimizing vehicle routing in a
supply chain management system.
Chuanzhong Yin et al [24] studied the split load vehicle routing problem in order to optimise
the transportation cost by implementing simultaneous delivery and pickup with multi-element
vehicle routing problem. Authors have made certain preconditions and assumptions and
proposed tabu search algorithm to obtain the effective result. In this algorithm, nearest
neighbourhood method is used to achieve a basic feasible initial solution. Data were collected
from China Railway Express to test the effectiveness and feasibility of the model and algorithm
by comparing characteristics of solution convergence, solution quality and computing time with
those of present analogous studies. Results revealed that algorithm solved the problem
efficiently and achieve an optimum solution. VRP problem with split loads is applied widely in
the various area of a logistic network, especially when total delivery demands are larger than
Literature Review
18
the total loads [24]. However, it has been also noticed that the solution difference is more than
4% and it still needs to improve to achieve an optimal solution.
2.7 Flexible Milk-Run for Stochastic Vehicle Routing
Globalisation has raised the necessity to change the conventional vehicle routing problem.
Stochastic vehicle routing is a part of innovation in classical vehicle routing, in which demands
are probabilistic in nature rather than deterministic. The objective of the model is to minimize
the number of vehicle and travel time, which will lead to lower transportation cost. Supplier
faces the optimisation issue while handling with stochastic vehicle routing problem in which the
demands are split and uncertain. Various industries have employed this variant due to the
enormous advantages of the system. However, when a vehicle is dealing with multiple suppliers,
there is a chance of fluctuation in vehicle load, which may lead to underload or overload problem
in transportation. Flexible milk-runs design allows handling the variation of load in associated
route. The objective of consolidated shipment is to maintain great flexibility with respect to
variation in the volume of goods.
Ben Peterson et al. [38] have studied the vehicle routing problem with an objective to optimize
the sets of routes, such that the capacity of each vehicle is not exceeded with a given probability.
Authors have introduced a flexible milk-run model to optimize the stochastic demand problem.
The proposed method was designed to construct routes for North-American division of
Bosch/Siemens home appliance corporation. The solution consists of the careful selection of
supplier into consolidated routes, which is also called as flexible run. The model is designed in
such a way that change in volume of one supplier is inversely proportional to the change in
volume of another supplier. In other word, the vehicle capacity in each flexible route is higher
than demand. The concept is to cluster the stations in such a way that joint demand of all stations
is lower than the capacity of a vehicle. Thus the formed routes are flexible to the fluctuation of
demand. The result indicated a probability of the reduction of 25% of total transportation cost
along with the improvement of the robustness with respect to demand fluctuations.
Milk-run vehicle routing approach for shop-floor logistics
19
2.8 Milk-run vehicle routing approach for shop-floor logistics
The effective material supply system in shop floor logistics, especially in large scale production
unit is crucial to obtain. It has an important role in balancing the workload and ensuring a
continuous and smooth running of production. The shop-floor logistic system influences on the
performance of production system and order management. In order to manage material supply
system properly, efficient transportation system is required with an objective of minimum cost.
Various material supply systems are employed in order to manage the real world practical, large
scale shop floors. The effective vehicle routing approaches are required against the constraints
of a restricted capacity of vehicles and time to support production planning. David Gyulaia et
al. [22] have given an overview of the most effective solver algorithms of the vehicle routing
problem. Authors have proposed a unique approach that generates an initial basic solution and
applied local search method to solve the milk-run vehicle routing problem. The milk-run planner
employed that includes user interface and the solver algorithms in a .NET environment using
C# language. The proposed application offers user-friendly and efficient milk-run planning
environment. The proposed approach mainly focuses on the industrial necessities such as time
frame, effective layout planning and demand. In order to evaluate the effectiveness of the
solution, a software prototype has been developed and tested on real-life industrial data.
2.9 Milk-Run Distribution Systems for the Express Industry
Milk-run material supply system has been employed by the various logistic industries. However
very few have applied the milk-run system in express industries. As the world has become the
global village, competition of express delivery industry is passing through the bottle neck. Each
one is trying to cut down the transportation cost as low as possible along with the production
cost. It is a technique to minimize the transportation cost and improve quality of service in terms
of customer satisfaction. The combination between Milk-run material supply system and
express industry can stimulate the development of express enterprises.
Literature Review
20
Before Optimization After Optimization
FIGURE 2.5: Construction of Path [43]
Zhenlai You and Yang Jiao [43] have introduced milk-run supply system into the express
distribution industry based on a real scenario of the market through the feasibility analysis. This
module highlights the characteristics of the milk-run distribution system and described the size
and volume of routes and demand respectively. The proposed method improved the traditional
method and adopted multi-objective path optimization decision in order to satisfy full load
distribution; shown in fig. 2.5. It combines advantages of milk-run scheme and express
distribution that saves transportation cost by optimizing distribution scheme. The applied
traditional models used the savings algorithm to obtain the scheduling of the vehicles.The
module of proposed research is different from traditional distribution module. It has been seen
from the result analysis that feasible solution is achieved which effectively determined the route,
improved load factor and minimize cost.
2.10 Robust Optimisation Approach for Milk-Run Problem with Time
Window
The robust optimization approach is introduced to solve the milk run problem with time window
while uncertainty in inventory arises due to fluctuation in demand. The robust approach could
be implemented in action for the construction of routes that minimize transportation costs while
nourishing all inventories in a given restricted uncertainty due to volatility in the market. Jafari-
Eskandari M. et al. [19] have developed a mathematical formulation for the problem of robust
Heuristic Algorithm for Single and Multiple Depot in VRP
21
resource milk run, as a mixed integer approach to manage supply chain problems. The robust
optimization method was employed, mixed integer model was formulated for milk-run systems
with a time window and the results were compared with the optimal solutions of the proposed
milk run method. Uncertainty in supply in mathematical modelling has been considered as a
crucial issue in optimization [19]. There are two primary methods that have been proposed to
address uncertainty over the past years: (a) stochastic programming and (b) robust optimization.
Authors have proposed a deterministic, numerically tractable methodology to address a problem
of optimal control of supply chain subject to uncertain inventory. Robust optimization is
proposed in the research to obtain effective routing solutions for problems under uncertain
demand. It has been observed that robust optimization is an efficient alternative for formulating
milk-run problem under uncertainty since it does not require distribution assumptions on the
uncertainty or a cumbersome representation through scenarios [19]. The computational results
expressed that the robust solution can be protected from unmet inventory while incurring a little
additional cost over deterministic optimal routes. Results of investigation show that the robust
solution enforces additional cost to the transportation and inventory warehouse, though the
unnecessary inventory in the network is removed that make it more efficient than the
deterministic solution. Although the method is not implemented in large scale problems, it is a
suitable tool to validate the heuristic algorithms.
2.11 Heuristic Algorithm for Single and Multiple Depot in VRP
The vehicle routing problem with pickups and deliveries (VRPPD) is an extended version of the
classical vehicle routing problem (VRP), where customers may both receive and deliver goods
[52]. Single depot and multiple depot problems consist of the simultaneous delivery and pick-
up of goods from either one or multiple sources which makes it more complicated to solve and
achieve an optimal solution. In real life situation, due to the fact that capacity of demand is less
than the capacity of the vehicle, collection or delivery of the goods from the various stations has
become inevitable to reduce the transportation cost and improve the vehicle utilisation.
Literature Review
22
FIGURE 2.6: Vehicle Routing in Multiple Depot [32]
Nagy G. and Salhi S. [52] proposed heuristic approach of simultaneous pickup and delivery for
single depot and multiple depots (VRPSDPD).Fig. 2.6 represents the vehicle routing in multiple
depot. It has been assumed that the pickups and deliveries have taken place simultaneously or
according to the nature of the supply network. The method is proposed that treats pickups and
deliveries in an integrated manner with ignoring the theory of insertion. The approach tends to
find an optimal solution to the corresponding VRP problem and revises the result to make it
more feasible for the VRPSDPD. Such improvement is achieved mainly by heuristic approach
for routing of the vehicle adopted from VRP methodology but reformed such that the objective
becomes the declination of infeasibilities, although a number of problems for particular routing
is also constructed. The mathematical model has proposed to cope up the changes in a variation
of maximum demand. The proposed methodology is also proficient of solving single-depot and
multi-depot problems. The result achieved by the authors for single and multiple depot problems
are motivating for the industries and research institutes.
VRP with Simultaneous Pick-Up and Delivery based on Customer Satisfaction
23
2.12 VRP with Simultaneous Pick-Up and Delivery based on Customer
Satisfaction
In order to sustain in this global competitive market, higher customer satisfaction level is highly
desirable attribute. Product delivery should be taken place at right place at right time to enhance
the reliability among the consumers. Transportation service industries strive to improve the
customer satisfaction level as it is a key element to keep the reputation of the company. It is
clear that transportation industries should take effective operational decisions to optimize the
methods in supply chain more efficiently. Many industries have achieved the success at a certain
level based on considering customer satisfaction criteria as it reflects the quality of service. On
the other hand, time window has an inevitable impact in the operational decision since service
quality assessed by the customers is affected by the time required to serve the customer.
Although the number of vehicles is limited and all customer’s requirement cannot be achieved.
The vehicle routing problem with simultaneous pickup and delivery, considering customer
satisfaction is based on a time window at each customer location [26]. Transportation service
has to be as quick as possible to cope with such kind of problems, otherwise the penalty cost is
imposed to the overall cost. Jing Fan [26] has modelled VRPTWSPD to solve the minimization
of the total length of vehicle’s paths and maximization of all customer satisfaction to enhance
service quality. The author has considered the service quality is inversely proportional to the
waiting time for the delivery of product to the consumer. Customer satisfaction level improves
as the waiting time is reduced. The initial basic feasible solution is obtained by the nearest
neighbour method, which is improved by tabu search algorithm in later stages. Various group
tests have been undertaken and computational results indicate that problem size and time
windows have a different impact on the problem.
2.13 Milk-Run Approach by Genetic Algorithm
Genetic algorithm (GA) is a search heuristic based on the natural selection of evaluation theory.
It is often used to generate a solution of optimisation. A genetic algorithm is a random search
algorithm and widely used to solve the various kind of VRP problem. Liang Chun-Hua et al.
[27] proposed a mathematical model for VRPTWSPD and demonstrated the significance of the
Literature Review
24
introduction of time windows. The improved genetic algorithm is proposed for the problem.
Authors have used roulette wheel selection operator with an elitist model. They have also
adopted enhanced edge recombination crossover to improve the legacy of good characters of
the parents. GA has adopted an improved crossover to maintain the legacy of an excellent
chromosome and enhance capability of population search. Premature convergence is avoided
by applying a self-adaptation strategy to control crossover and mutation probability. Numerical
experiments have been conducted on a large scale test problem. Computational results were
admirable and proposed procedure represents an outstanding performance. However, there are
many uncertainties existing in a real situation, like the reliability of delivery and fluctuation in
demand.
Serdar Tasan and Mitsuo Gen [28] have studied an alternative approach to solve vehicle routing
problem with simultaneous pick-up and delivery (VRPSPD). The study has proposed a genetic
algorithm (GA) based approach, which uses permutation based representation and ensures
feasibility, for solving VRPSPD more efficiently and effectively. The computational model is
presented with parameter settings in order to illustrate the proposed approach. The performance
of the proposed approach is evaluated by solving several test problems formulated as mixed
integer linear programming models. Results of the solver are compared with the solution
provided by the developed approach and found to be efficient. Abbas Gharib Garakani and
Mohammad Reza Razzazi [29] have modeled genetic algorithm for multi capacitated depot
vehicle routing problem with pickup and delivery and time window, where the routes are
constructed in such a way that vehicles collect the demand and products are delivered to all
consumer with satisfactory level. The capacity of each depot is considered, which is different
from each other. Minimization of travelling costs, the fixed cost of depots and vehicles and
penalty cost of time window are the objective function of proposed research. During the
scheduling of vehicle, various constraints, such as time window, the capacity of depots and
capacity of vehicles are taken into account. A Genetic algorithm is used and solved by Matlab.
A set of feasible solutions to minimize total distance is generated and presented, which leads to
an optimal result.
Sadjadi SJ et al. [30] proposed a milk-run method as a mixed integer mathematical model and
meta-heuristic approach for a special case of auto-industry supply chain since problem belongs
Simultaneous Pick-Up and Delivery in VRP with Hybrid and Multi-Objective GA
25
to NP-Hard. Authors have developed a genetic algorithm to compare the result with an optimal
solution of proposed milk-run for large industrial case problems. The result indicated that the
proposed solution could be effective to minimize the cost of the logistic network. The primary
objective of the proposed model is to determine the pick-up time, diversify the order among the
suppliers and assignment of the routes to each vehicle.
2.14 Simultaneous Pick-Up and Delivery in VRP with Hybrid and Multi-
Objective GA
Due to the globalisation, business environment of supply chain industries has become more
challenging. It deals with managing product delivery to the customers with consistent quality at
reasonable low cost. Effective systems have become a basic need to achieve effectiveness and
efficiency. As it contributes to delivery processes in order to avoid tardiness and thus
minimizing transportation cost and improve the customer service level. Various delivery
methods are used by industries according to the nature of the problem. Milk-run material supply
method is used when the demand is less than full vehicle load per consumer. In milk-run, a
common vehicle delivers or picks-up the goods from the various destinations in cyclic routes.
Various mathematical and heuristics models are proposed for finding optimal routes, quantities
and vehicle loads. Most of them are focused on either the vehicle routing, loading or scheduling
individually. Hence, a more common approach is required to achieve the solutions that
effectively balance the vehicle routing, scheduling and loading schemes and can be implemented
for heterogeneous goods. Duygu Yilmaz Eroglu et al [31] have proposed a milk-run
methodology to control the procurement system. The hybrid genetic local search algorithm is
proposed which simultaneously solved vehicle routing and order loading problems. Volume and
weight capacities are taken into account for different types of transportation vehicles to make
the solution more adaptive. Genetic algorithms are the most desired approach of heuristics
method to get the satisfied solution. The chromosome structure of the proposed genetic
algorithm is established by random numbers to abolish infeasibility. The better chromosome of
each generation is developed using local search method. The algorithm is implemented in
Comau S.P., a manufacturing industry that produces welding robots and automation equipment.
The results showed the effectiveness of the algorithm.
Literature Review
26
FIGURE 2.7: Vehicle Routing by Multi-objective Genetic Algorithm [32]
Sangeeta and Sonia Sharma [32] modeled multiple objective genetic algorithm for multi depot
vehicle routing problem with simultaneous pickup and delivery. The proposed algorithm
simultaneous determines the routes for numerous vehicles from multiple depots to a set of
clients and then returning to the origin. Each depot has its own certain capacity and it has been
assumed that the total sum of demand in particular routes to assigned depot will not be more
than its maximum capacity. The objectives of the problem are to find the routes for vehicles to
facilitate all the customers at an optimal cost with the optimization of the total length of routes
and utilization of vehicles without changing the capacity of the vehicles. A multi objective
genetic algorithm is employed to solve the proposed problem with new constraints. The
assignment of stations to a particular origin in multi depots is shown in fig. 2.7. Multi objective
GA is applied on the population and routing of the vehicle is obtained. Matlab is used to run the
algorithm and optimal results are achieved.
Modelling Issues and Heuristic Solution Approaches in VRP
27
2.15 Modelling Issues and Heuristic Solution Approaches in VRP
Vehicle routing problem with different nature of issues are challenging to handle in a practical
situation. Different heuristics and metaheuristics methods can be applied to solve the problem
according to the nature of a problem. However, no exact algorithm can be definitely confirmed
to find an optimal solution within reasonable computing time when the problem is real life and
large scale. Niaz A. Wassan and Gabor Nagy [33] have investigated the different version of
vehicle routing problem including traditional and new one with the difference in terms of
practical approach and modeling issues especially focusing on the assumption made in the
literature and not making a restrictive assumption. The researchers have described the
backhauling aspect of vehicle routing problem, which has practical application in supply chain
industries, especially in reserve logistic. The proposed research work mainly concentrates on
restriction on making an assumption. Authors have investigated two assumptions; single
demands and combined demands. These assumptions have uncovered rise of other problems,
such as VRP with a restricted mixing of deliveries and pick-ups, VRP with divisible deliveries
and pickups, VRP with a restricted mixing of divisible deliveries and pickup etc. Universal
Integer linear programming is formulated, which is adoptable to the range of various problems.
Various solution methodologies including meta-heuristic to solve the problem are discussed.
2.16 Hybrid Meta-Heuristic Algorithm for VRPSPD Problem
In the last few years, the vehicle routing problem with simultaneous pickup and delivery
(VRPSPD) has drawn attention because of its significance in real life applications. The
VRPSPD problem comes across in practice during the daily life. Basically, simple heuristics are
often used to gain initial basic feasible solution and hybrid metaheuristics are implemented
during the search process to obtain the optimal solution. Operation research plays an important
role for the development of metaheuristics for the VRPSPD. Qingguo Jiang et al. [34] have
addressed a vehicle routing problem with simultaneous pickup and delivery service. The
VRPSPD problem is an NP-hard optimization problem; therefore some heuristic models are
unable to obtain an optimal solution for large scale VRPSPD. The authors have developed
hybrid metaheuristics algorithm for the VRPSPD problem. The proposed metaheuristic
approach is a hybridization of two well-known metaheuristics, such as tabu search and simulated
Literature Review
28
annealing. A tabu embedded simulated annealing metaheuristic (TSSA) employed four types of
improvement methods; such as randomly insertion move, swap move, 2-opt move and cross-
exchange move to explore the neighbourhood. The tabu list of prohibited movements is
employed to reduce computation time and overcome local optima encountered of simulated
annealing. The tabu list prohibited revisiting previously visited solutions. The proposed tabu
embedded simulated annealing metaheuristic is employed to test the performance of Montane
and Galvao’s VRPSPD benchmark data with 18 test problems and 100–400 customers.
Computational results demonstrate that TSSA could produce high-quality solutions.
2.17 Simultaneous Pick-Up and Delivery with Decision Support System
Vehicle routing problem involve discovery of a set of fleets routes with optimum cost such that
origin and destination of each route are same, each customer is visited precisely once by one
vehicle in the same route, vehicle capacity should be higher than the total demand of each route
and the time duration of each route (including travel and service times) does not exceed a
predefined time limit. Pick-up and delivery are the two different kinds of demands of each
consumer in vehicle routing problems with pick-up and delivery, involve product delivery from
the depot to consumer and goods pick-up from consumer to depot. VRPPD is classified into
three groups according to nature of delivery and pick up demands as [35],
Delivery first- pick-up second
Mixed pick-ups and deliveries
Simultaneous pick-ups and deliveries.
Simultaneous Pick-Up and Delivery with Decision Support System
29
FIGURE 2.8: Components of VRP in Decision Support System [35]
Operation research’s algorithms have limitation to cope up with the necessity of business
decision. This problem has led to the development of the concept of a decision support system
(DSS) as shown in fig. 2.8. The DSS consists of the combination of data, analysis of models and
tools, and software into one integrated system that can support semi structured or unstructured
decision making. The prime function of DSS is not to make a decision but to assist making a
decision. Cevriye Gencer et al. [35] proposed the DSS to obtain the optimal solution for the
homogeneous and heterogeneous fleet. DSS allows assisting decision-maker to understand the
data about the decision, to make more precise decision options and to obtain a further alternative
solution. DSS VRP2.0 program consists of two interfaces, such as data collection interface and
calculation interface. The system supports to find the shortest routes and to computerize the
routes. Initially data, calculation criteria, delivery and pick-up demand from the depots and
capacity of a vehicle are entered into this interface. Calculation interface performs the
calculation process and presents the result. The result involves the number and length of routes
of the supply network with the information of the total amount of load to be delivered and
picked-up on each route. It also shows the penalty cost and bonus coefficients related to the
particular route. In VRP2.0 software, interfaces are derived from visual basic 6.0 programming
language and calculations are derived via a program which is coded in C++ 6.0 language. DSS
Literature Review
30
enhances the opportunity of making the effective decision options and increases the possibility
of making the right decision in terms of satisfied customers (receive a right product in the
reasonable time limit) and industries (delivery within predefined time with lower cost).
2.18 Milk-Run Problem with Time Windows under Inventory Uncertainty
Milk-run material supply system constructs the route, determine scheduling and number of
vehicles with the primary assumption that all vehicles must return with the collected goods from
the supplier to the depot. This kind of modelling involves different objectives, whether
minimization of transportation cost or minimization of inventory holding cost. The milk-run
problem under uncertain inventory is the excessive risk loss. Lack of supply can ruin
manufacturing plan and excessive stock on an inventory level are also obstacles to management.
The industry has to face an enormous amount of loss if proper care is not taken in both the cases.
The prime goal of inventory management is to make a balance between the minimization of
total cost and maximization of the customer satisfaction. Robust optimization could be
implemented to obtain the optimal solution of optimization problems with data uncertainty.
M. Jafari-Eskandari et al. [19] have proposed a robust optimization approach to solve the milk
run system with time window with inventory uncertainty. This approach constructs routes that
minimize total transportation costs along with the satisfaction of all inventory in a given
bounded uncertainty set. The milk-run material supply system problem has been utilised to
manage the transportation of materials. Since the resulted problem formulation is NP-Hard, in
order to solve the underlying problem, a novel algorithm entitled robust optimization has been
proposed. The robust solution efficiency is compared with deterministic by applying the model
in numerical examples. Particle swarm optimization has also been proposed to solve the problem
in practical large scale. In order to analyse the performance of the proposed method, initially
mixed integer software package was implemented by data from SAIPA for three different
variables: the number of suppliers, the number of parts and the time horizon for planning.
However due to many variables in proposed model, robust optimization approach became
inevitable to solve the problem. It has been seen from the result that robust optimization is an
effective substitute for formulating milk run problem under uncertainty as it does not count on
distribution assumptions about the uncertainty or a cumbersome demonstration through
Effect of Milk-Run Supply System in Global Warming
31
circumstances. The results represent unmet inventory which can be reduced in robust solution
while acquiring a small additional cost over deterministic optimal routes. Although the robust
optimisation solution levies extra cost to the system but unmet inventory can be controlled in
the logistic network.
2.19 Effect of Milk-Run Supply System in Global Warming
An extensive amount of industrial revolution has raised the threat of global warming as human
activity is increasing. The level of carbon emission has been rising extensively since many years.
The response to the environmental problem is a major issue on a global level. Proper steps must
be undertaken to reduce the growing emission in the environment. In the logistics field, the
crucial aim is to decrease the amount of carbon emission, which is exhausted from the vehicles.
The problem of global warming in the environment due to the direct shipment can be controlled
by implementing the milk run logistics. The overall transportation cost can be optimized by
milk-run material supply system in a logistic network.
Gurinder Singh Brar and Gagan Saini [39] have studied the effects of the conventional
transportation on the traffic conditions and environment. It has been observed that the
implementation of milk run logistics can be more effective even under highly dense traffic
conditions. The milk-run process can allow the optimisation of the number of trucks, which
results in the reduction of the vehicle on the road. On the other hand, reduction in the utilisation
of a number of vehicles for supply network leads to the reduction of carbon emission in the
environment. Milk-run supply chain management system enhances the average loading factor
rates in terms of vehicle utilisation at an optimum level, which leads to decrease in the number
of vehicles in a logistic network. It also effectively constructs and schedules the routes to reduce
travel distances. Accordingly, it is an effective method of transport in which exhaust gases from
the vehicle can be reduced. Therefore, Milk-run supply system can be extremely significant
from the environmental point of view. Furthermore, as milk-run is accurate supply chain
management system, it leads to increase in transportation reliability.
Literature Review
32
2.20 Research Gap
It has been observed that many companies around the world aim to implement milk-run material
supply approach though very few have successfully adopted it into the logistic network. Milk-
run supply system studies usually involve formulating a mathematical model of the associated
VRPTWSPD and attempt to solve it using heuristics approach, since it is difficult to get
optimum solution, especially in real world setting. The study of literature review demonstrated
that various heuristic approaches have been attempted by the researchers so far, such as Robust
optimisation approach, Route construction algorithm, Iterated local search, Differential
evolution algorithm, Genetic algorithm, Nearest neighbour method, Multi swarm optimisation
algorithm, Branch and cut algorithm, Variable neighbourhood descent method, Modified saving
algorithm, Simulated annealing, Greedy algorithm, Dynamic programming, Taboo search etc.
However, there is often conflict for selection of an appropriate heuristic model, as it has impact
on optimality of the solution. Thus, there is a considerable amount of studies required for
optimisation of the milk-run supply system. Therefore, the contribution of this research will be
significant to both the industry and the literature.
Study of extensive literature review illustrates that with all the progress in the design of milk-
run material supply systems which have been made over the last few years, it still has some
major challenges, which are described below.
Some automobile industries have adopted milk-run material supply system, though it is
still a challenging issue for other industries to adopt effective milk-run in the logistic
network, such as perishable industries believe more in the direct shipment than a cyclic
route as there will be chances of loss if the product gets melt. Even one of the
disadvantage of milk-run system is that all suppliers cannot implement a milk-run.
The Milk-Run logistics requires accurate management, based on the operational plan. In
case of poor planning the number of extra trips may increase which may lead to
additional transportation cost.
Research Gap
33
In case of, handling split, consolidation or heterogeneous goods may increase the
number of trip that leads to additional transportation cost. It is challenging to achieve
optimal solution in such scenario.
Customer’s waiting time and penalty cost have not been considered in the overall
transportation cost, if delivery does not take place in predefined time period.
Dynamic, fuzzy, and stochastic goods with different processing routes can make
problem more difficult and cumbersome to solve.
It has been observed that when the demand is very small, the pure milk-run strategy can
be used, as for large scale demand, holding cost is high and fixed truck cost is low, the
milk-run strategy is used with the direct shipment. When milk run strategy is used, it
carries only a small quantity of shipment so that the demand can be closely matched or
an additional truck cost can be prevented.
The studies of environmental pollution (amount of carbon emission) issues have not
been observed and calculated, which can be reduced by effective utilization of vehicle.
There are many uncertainties existing in practical scenario, such as delivery reliability,
stochastic customer demand, etc. These uncertainties greatly influence the vehicle
scheduling, which has not been attempted.
There are several open issues that deserve attention to extend VRPSPD problem, which
include more practical considerations, such as time windows, multiple objectives and
travel times to move the problem even closer to real world problems.
Although minimizing total cost is an important criterion but for some services, criteria
such as minimizing customer inconvenience and minimizing response time may be
equally important that has to be accounted.
34
CHAPTER – 3
Necessity, Objective & Scope of Study
3.1 Problem Statement
To address the problem of having route development for milk-run supply system, effective
mathematical model and heuristic approach need to be developed that constructs the routes and
determines the number of vehicles, scheduling and service period of just-in-time basis to
minimize material handling and total inventory holding cost.
3.2 Necessity
Nowadays the industries are experiencing cut throat competition due to globalisation.
International organisations are in competition with the local business, which makes tough for
local industries to sustain. Enormous invention and innovations have been carried out to reduce
the production cost, which has major involvement in total production cost. However,
transportation cost also has a major impact, especially while the product delivery has to be made
for long and isolated distances. The adoption of an optimised transportation system has become
inevitable due to competitive business environment among the industries and higher
expectations of customers. It has also been observed that congestion and variability in demand
and travel times affect industries on four major service dimensions, such as; travel time,
reliability, cost of transport and cost of inventory [19]. These challenges have to be dealt
efficiently to achieve effective supply chain. On the other hand, waiting time directly influences
the satisfaction of the customer; therefore transportation problem becomes multi-objective along
with the transportation cost. One of the crucial issues is exhaust gases of vehicles, which
contains carbon dioxide and carbon monoxide that have an adverse effect on the environment.
Carbon emission enhances the global warming, which is the major problem that the world
Objective of Research Work
35
currently faces. Effective utilisation of the vehicle can reduce the number of vehicles in supply
network by optimised allocation and scheduling.
The critical issue noted in supply industries are:
The competition in business environment is increasing day by day that makes supplier
to employ effective logistic system to reduce the transportation cost as low as possible.
Lean practice requires the adoption of the lean supply chain management for the
foundation of business.
Transportation system has a vital effect on inventory holding cost.
As the traffic congestion is a major issue in urban area and highway, supplier has to
make sure that product delivery takes place in shortest time and distance along with low
cost by determining effective route.
Customer’s reliability and satisfaction must be taken into account among the customer,
which is achieved by delivering a right product in right time and low charges.
Inappropriate utilisation of the vehicle can enhance the number of vehicles in the supply
network.
3.3 Objective of Research Work
The main goal of the study is to investigate the implementation of milk-run material supply
system in local courier industry with simultaneous pick-up and delivery within time limitation
and examine its effects on overall performance and total cost. Our aim is that the conduction of
the research provides optimization of the supply chain network for the development of milk-run
supply system in courier industry as an alternative system. For suppliers and researchers, it is
hoped that the study also contributes to better understanding of inventory management. Besides,
research will contribute to set up feasible routes and offer quickest response to the demand of
the customers.
The overall objectives of the research work are as following:
Necessity, Objective & Scope of Study
36
Determine the scheduling of vehicle, period of the pick-up and delivery services and
quantity of vehicles.
Construction of the routes based on lowest time and cost required to travel to facilitate
both distribution and collection.
Optimization of total material handling and inventory holding cost.
To deliver the products on just in time to achieve higher customer satisfaction.
To reduce the carbon dioxide and carbon monoxide emission in the environment by
optimizing vehicles utilisation in the transportation network.
3.4 Scope of Study
The proposed model is focused on building robust optimisation approach for the courier supply
chain network. The model mainly concentrates on the construction of the routes and scheduling
of vehicle to optimize the transportation cost, inventory holding cost and travelling time. The
optimized model can be successfully implemented in the transportation services which involve
simultaneous pick-up and delivery within the certain time limit, such as courier services, grocery
chain services, perishable supply, industrial supply chain management etc.
The scope of the research is defined as:
Conventional material supply system for the courier services has been studied to
understand the previous construction of routes, location of the stations, average demand
and supply on daily basis, scheduling and requirement of a number of vehicles in supply
network.
Mathematical model has been developed based on the application of logistic network of
courier industry.
Genetic algorithm has been proposed to solve the mathematic model.
Routes have been constructed based on milk-run material supply system to optimize
transportation cost and travelling time.
Methodology of Research
37
The number of vehicles is determined for the network, based on the demand of the
consumer with optimized fixed cost.
Scheduling of the vehicles is determined based on the frequency for the reduction of the
penalty cost and inventory holding cost.
User-friendly application for the android handset has been developed for the easy
assessment of the overall system.
The database has been developed based on the previous record to forecast the average
demand of the consumer and determine average travelling time and cost between each
station.
Overall surveillance of the whole network by global positioning system (GPS) located
in each vehicle.
3.5 Methodology of Research
The methodology adopted for the development of milk-run material supply system is described
step by step as below;
1. Conventional material supply system has been studied and transportation cost is
calculated for the courier services.
2. Location of stations, number of routes and vehicles in transportation networks are
studied and analysed.
3. Identification of the quantity of the product to be picked-up and delivered on everyday
basis for each station.
4. Establishment of the routes according to milk- run supply system for the pick-up and
delivery service.
5. The time frame constraint has been accounted for each route for penalty cost.
Necessity, Objective & Scope of Study
38
6. Adjustment of the similar routes for the delivery of the product (according to the time
frame).
7. Establishment of the period of delivery and pick up services.
8. Calculation of no. of vehicle need to be required in each route.
9. Scheduling of vehicle on the basis of demand and number of vehicle.
10. Determination of the overall cost (Transportation cost, fixed cost and penalty cost) and
evaluation of the performance of the model.
11. Development and evaluation of milk run alternatives.
12. Implementation of milk runs: Definition of a milk run schedule, conduct supplier
workshops, testing and controlling.
39
CHAPTER – 4
Research Methodology
4.1 Formulation of Mathematical Model
The mathematical model of the milk-run supply system is formulated to analyse the problem,
according to the necessity and application of the logistic chain of courier industry. The
mathematical model helps to explain the system and to study the effect of different parameters
for overall transportation cost.
4.1.1 Assumptions
Following assumptions are made for the formulation of the mathematical model.
The buffer stock at each pickup point should be predefined.
The vehicle assigned to the route must visit each point.
The distance and plan of each route must be known.
The delivery rate of each station should be predetermined.
4.1.2 Objective Function
The objective function of the mathematical model is to minimize the total cost. The first part of
the objective function indicates total transportation cost. The second part explains the total fixed
cost of the vehicle (Initial cost of a vehicle, Taxes, Insurance charges, Vehicle permit charges
etc.) according to the milk-run. The third part shows the penalty cost if the delivery does not
take place in predefined time period.
Research Methodology
40
𝑀𝑖𝑛𝑖𝑚𝑖𝑧𝑒 𝑍 = ∑ ∑ ∑ 𝑐𝑖𝑗 𝑥𝑖𝑗𝑘
𝑛
𝑗=0
𝑛
𝑖=0
𝐾
𝑘=1
+ ∑ 𝑐𝑓𝑘 + ∑ 𝑝𝑖 𝑡𝑖
𝑛
𝑖=1
𝐾
𝑘=1
(1)
4.1.3 Constraints
Subject to,
∑ ∑ 𝑥𝑖𝑗𝑘 ≥ 1, 𝑖 = 1,2, … . , 𝑛
𝑛
𝑖=0
(2)
𝐾
𝑘=1
∑ ∑ 𝑥𝑖𝑗𝑘 ≥ 1, 𝑗 = 1,2, … . , 𝑛
𝑛
𝑗=0
(3)
𝐾
𝑘=1
Each Point is visited by minimum one vehicle.
∑ 𝑥𝑖𝑗𝑘 −
𝑛
𝑖=0
∑ 𝑥𝑗𝑖𝑘 = 0, 𝑗 = 0,1, … . , 𝑛 𝑘 = 1,2, … . , 𝐾 (4)
𝑛
𝑖=0
Same vehicle arrives and departs from each point between the node i and j.
𝑋𝑖𝑟 = 𝑋𝑗𝑟 (5)
The related stock point assigned to a same “r” route.
𝑞𝑖 = 𝑡𝑓𝑖𝑥𝑒𝑑 . 𝑋𝑖𝑟 . (6)
The total demand of a point “i” at “r” route is determined.
𝑞𝑖 ≤ 𝑐𝑘, 𝑖𝑓 𝑥𝑖𝑗𝑘 = 1 (7)
The vehicle capacity should be higher than demand.
𝑞𝑖 ≤ 𝑐𝑖𝑘, 𝑖𝑓 𝑥𝑖𝑗𝑘 = 1 (8)
Each vehicle has free capacity at the arrival at point “i”. It should be greater than pick up demand
at that respective point.
𝑏𝑜 ≤ 𝑎𝑖 ≤ 𝑡𝑜 (9)
Arrival time must be within time frame.
𝑤𝑖 = 𝑑𝑖 − (𝑎𝑖 + 𝑠𝑖) (10)
Formulation of Mathematical Model
41
Calculate the waiting time before the departure at point “i”.
4.1.4 Notations
The necessary notations are defined for the formulation of mathematical model, which are
explained in following sections.
Indices
Z = Total cost
k = Vehicle index
t = Time period
i, j = Pick-up and delivery point indexes
n = Set of clients
r = Route index
K = Maximum number of vehicles in distribution centres
Parameter
𝑐𝑘 = Capacity of vehicle “k”
𝑐𝑖𝑘 = Free capacity of vehicle “k” on arrival at node “i”
𝑞𝑖 = Pick-up and delivery demand at point “i”
𝑏𝑜 = Bottom end of the time frame at point “i”
𝑡𝑜 = Top end of the time frame at point “i”
𝑠𝑖 = Service time at point “i”
𝑑𝑜= The output and input ratio of point “i”
Research Methodology
42
𝑡𝑓𝑖𝑥𝑒𝑑 = The determined time period
Variable
𝑐𝑖𝑗 = Delivery cost between “i” and “j”
𝑥𝑖𝑗𝑘 = 1 if vehicle “k” departs point “i” to point “j”; 0 otherwise
𝑐𝑓𝑘 = Fixed cost of the vehicle “k”
𝑋𝑖𝑟 = Point “i” is assigned or not assigned to route “r” (1 or 0)
𝑋𝑗𝑟 = Point “j” is assigned or not assigned to route “r” (1 or 0)
𝑎𝑖 = Arrival time at node “i”
𝑤𝑖 = Waiting time before departure
𝑑𝑖 = Departure time from point “i”
𝑝𝑖 = Penalty cost per unit time at point “i”
𝑡𝑖 = Tardiness for point “i”
4.2 Heuristic Approach
As explained earlier, the design of the milk-run material supply system requires the construction
of routes, scheduling of vehicle and determination of the service period. Mathematical model is
typically formulated and attempted to be solved by heuristics approach for the route
construction. The proposed mathematical model of the JITVRPSPD is nonlinear due to the
continuous large scale demand for each station. Vaidyanathan et al. [4] described that the
problem size increases exponentially with the increase in a number of vehicles and stations that
makes even small scale problem difficult to solve. Hence, a heuristic approach is used to reach
at a close to the optimal solution, through short computational times. The assumptions of the
mathematical model are valid also for the proposed heuristic approach.
Tabu Search Algorithm
43
Initially, four various approaches (Tabu search algorithm, Prim algorithm, Simulated annealing
and Genetic algorithm) are tested by considering the small region of the problem to find an
optimal solution. Mehsana zone of Gujarat state is considered to compare the optimal result of
each algorithm. Table 4.1 shows the comparison of various approaches for the milk-run material
supply system.
TABLE 4.1 Comparison of Various Algorithms for Milk-Run Supply System
Tabu Search
Algorithm
Simulated
Annealing
Prim Algorithm
Genetic
Algorithm
Route 1 3440 3440 1932 1840
Route 2 4030 3790 2887 2655
Route 3 6710 6450 5092 4570
Total Cost (Rs.) 14180 13680 9911 9065
The optimal solution achieved by each algorithm is evaluated and compared with each other to
choose the most suitable algorithm for the concerned problem. Out of the four different
algorithms, genetic algorithm is found to be more suitable and accurate for the nature of our
problem. Based on the comparison, genetic algorithm is selected to study and analyse the entire
problem. The methodology and flowchart of each algorithm are explained in following sections.
4.2.1 Tabu Search Algorithm
Tabu search is a metaheuristic search approach for solving a mathematical or combinatorial
optimization problem. It employs local search procedure or neighbourhood procedure to achieve
an improved solution. Local search procedure has a limitation to stick to subregions that can be
optimised by carefully exploring each neighbourhood solution and determined through memory
structure by tabu search. The flow chart of the tabu search algorithm is shown in fig 4.1 and the
methodology is explained in below section.
Research Methodology
44
Methodology
Generate initial solution.
Generate neighbouring solution.
Each neighbouring solution is measured.
Explore solution region.
Aspiration criteria (Global minima).
Flow Chart
FIGURE 4.1: Flow Chart of Tabu Search
Evaluate solution
Choose best
admissible solution
Optimal Solution
Update Tabu and
aspiration
conditions
Initialize solution
Create list of
solution
Stopping
criteria
satisfied
End
Simulated Annealing
45
4.2.2 Simulated Annealing
Simulated annealing is a metaheuristic technique to find a good solution (may not be optimum).
It is a method for the approximate global optimisation of given function. For the problem where
an accurate solution is not important than finding an acceptable local optimum, simulated
annealing is most preferable. It is the fastest tool to find the local optimum, but it cannot get
global optimum. The flow chart of simulated annealing is shown in fig. 4.2.
Methodology
Generate initial solution.
Determine control parameters.
If the final solution is not reached.
Randomised test is undertaken.
Downhill and uphill moves on the basis of feasible solution.
Generate neighbouring solution.
Generate frozen state (Final solution).
Research Methodology
46
Flow Chart
FIGURE 4.2: Flow Chart of Simulated Annealing
(Source: http://dx.doi.org/10.5772/51126.pdf)
4.2.3 Prim Algorithm
The prim algorithm is also called as a greedy algorithm that discovers a minimum spanning tree
for a connected weighted undirected graph. It finds a subset of the edges that forms a tree which
includes every vertex, where the total weight of all the edges in the tree is minimized. Initially,
the algorithm builds tree by one vertex at a time from an arbitrary starting vertex. It adds the
Prim Algorithm
47
minimum possible connection in each step from the tree to another vertex. The fig. 4.3 represents
the flow chart of prime algorithm.
Methodology
Generate basic feasible solution.
Generate neighbouring solution.
Generate weight on the basis of available feasible solution.
Removal of the loops and parallel edges between the vertexes.
Formation residual table.
Generate optimum solution on the basis of TSP.
Research Methodology
48
Flow Chart
FIGURE 4.3: Flow Chart of Prim Algorithm
(Source: http://www.ijcat.com/archives/volume5/issue2/ijcatr05021010.pdf)
Genetic Algorithm
49
4.2.4 Genetic Algorithm
A genetic algorithm is a metaheuristic approach to solve mathematical optimization problems
based on a natural selection process that is based on biological evolution theory. The algorithm
repeatedly modifies individual solutions by producing the children for the next generation of
their parents called current generation. Genetic algorithm generates optimised solutions by
relying on bio-inspired operators such as mutation, crossover and selection. Over successive
generations, the population "evolves" toward an optimal solution. The flowchart of the genetic
algorithm is shown in fig. 4.4.
Methodology
It scores each member of the current population by computing its fitness value.
Parents are selected based on their fitness.
Some of the individuals in the current population have lower fitness value, which are
chosen as elite. These elite individuals are passed to the next population.
Children are produced from the parents of current generation. These children are formed
either by making random changes to a single parent (mutation) or by combining the
vector entries of a pair of parents (crossover).
New produced generation replaces the current population with the children to form the
next generation.
Research Methodology
50
Flow chart
FIGURE 4.4: Flow Chart of Genetic Algorithm
4.3 Validation
The validation of the proposed model has been carried out based on the routes developed by
milk-run material supply system. The transportation cost of the existing material supply system
is compared with the cost of the milk-run material supply system. Mehsana zone, which is
located in Mehsana district and Gujarat state is considered for the purpose of the validation
process.
Gen = 0
Create initial random population
Designate best chromosome
found so far as a solution
Yes
Evaluate fitness of each individual in population
Reproduction
Crossover
Mutation
Gen = Gen + 1
If Gen=N
End
No
Existing Material Supply System
51
4.3.1 Existing Material Supply System
The courier service currently practices seven routes to manage the supply in north Gujarat
region. The routes and its distance are specified below in the table.
TABLE 4.2: Existing Material Supply System
Sr. No. Route Distance (km.)
Route : 1 Mehsana-Ahmedabad 140
Route : 2 Mehsana- Bechraji 60
Route : 3 Mehsana- Gojariya 40
Route : 4 Mehsana- Visnagar- Vadnagar- Kheralu- Satalasana 140
Route : 5 Mehsana-Patan 100
Route : 6 Mehsana- Chansma- Harij- sami- Radhanpur-
Bhabhar- Diyodar- Vav- Tharad
300
Route : 7 Mehsana-Unjha- Sidhpur- Palanpur- Deesa-
Dhanera
240
4.3.2 Milk-run Material Supply System
The existing routes are redefined by the concept of the milk-run material supply system and
specified in below tables. The route followed the cyclic manner and pick-up and delivery takes
place during the visit of each station.
TABLE 4.3: Milk-run Material Supply System
Sr. No. Route Distance (km.)
Route : 1 Mehsana- Bechraji- Ahmedabad-Mehsana 225
Route : 2 Mehsana- Gozariya- Visnagar- Vadnagar- Kheralu-
Satlasana- Palanpur- Sidhpur- Unjha- Mehsana
240
Route : 3 Mehsana- Chansma- Harij- Sami- Radhanpur-
Bhabhar- Diyodar- Vav- Tharad- Dhanera- Deesa-
Patan- Mehsana
390
Research Methodology
52
The travelling salesman problem solver and the generator are used to arrange the sequence of
each station and calculate the transportations cost. The calculations are shown below for each
route, which are formed according to the milk-run material supply system.
Route: 1
Variant #1 Task
Task:
--- 320 600
320 --- 800
600 800 ---
Variant #1 Solution
Step #1
--- 0 0
0 --- 200
0 200 ---
Selected route with (1;2) part.
3 alternate candidates for branching: (1;3), (2;1),
(3;1).
Step #2
--- --- ---
--- --- 0
0 --- ---
Milk-run Material Supply System
53
Selected route with (2;3) part.
1 alternate candidate for branching: (3;1).
Optimal path:
City 1 -> City 2 -> City 3 -> City 1
The price is 1720 units.
Route: 2
Variant #2 Task
Task:
--- 200 160 280 400 610 560 320 240
200 --- 200 320 440 600 760 520 400
160 200 --- 120 24 440 560 320 200
280 320 120 --- 120 320 465 320 300
400 440 240 120 --- 200 360 240 255
610 600 440 320 200 --- 440 440 440
560 760 560 465 360 440 --- 240 385
320 520 320 320 240 440 240 --- 135
240 400 200 300 255 440 385 135 ---
Variant #2 Solution
Step #1
--- 0 0 120 240 370 295 160 80
0 --- 0 120 240 320 455 320 200
Research Methodology
54
136 136 --- 96 0 336 431 296 176
160 160 0 --- 0 120 240 200 180
280 280 120 0 --- 0 135 120 135
410 360 240 120 0 --- 135 240 240
320 480 320 225 120 120 --- 0 145
185 345 185 185 105 225 0 --- 0
105 225 65 165 120 225 145 0 ---
Selected route with (1;2) part.
Step #2
--- --- --- --- --- --- --- --- ---
--- --- 0 120 240 320 455 320 200
136 --- --- 96 0 336 431 296 176
160 --- 0 --- 0 120 240 200 180
280 --- 120 0 --- 0 135 120 135
410 --- 240 120 0 --- 135 240 240
320 --- 320 225 120 120 --- 0 145
185 --- 185 185 105 225 0 --- 0
105 --- 65 165 120 225 145 0 ---
Selected route with (8;7) part.
1 alternate candidate for branching: (8;9).
Step #3
Milk-run Material Supply System
55
--- --- --- --- --- --- --- --- ---
--- --- 0 120 240 320 --- 320 65
31 --- --- 96 0 336 --- 296 41
55 --- 0 --- 0 120 --- 200 45
175 --- 120 0 --- 0 --- 120 0
305 --- 240 120 0 --- --- 240 105
215 --- 320 225 120 120 --- --- 10
--- --- --- --- --- --- --- --- ---
0 --- 65 165 120 225 --- 0 ---
Selected route with (5;6) part.
1 alternate candidate for branching: (9;8).
Step #4
--- --- --- --- --- --- --- --- ---
--- --- 0 24 240 --- --- 320 65
31 --- --- 0 0 --- --- 296 41
55 --- 0 --- 0 --- --- 200 45
--- --- --- --- --- --- --- --- ---
305 --- 240 24 --- --- --- 240 105
205 --- 310 119 110 --- --- --- 0
--- --- --- --- --- --- --- --- ---
0 --- 65 69 120 --- --- 0 ---
Research Methodology
56
Selected route with (9;8) part.
Step #5
--- --- --- --- --- --- --- --- ---
--- --- 0 24 240 --- --- --- 24
0 --- --- 0 0 --- --- --- 0
24 --- 0 --- 0 --- --- --- 4
--- --- --- --- --- --- --- --- ---
250 --- 216 0 --- --- --- --- 40
64 --- 200 9 0 --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
Selected route with (6;4) part.
Step #6
--- --- --- --- --- --- --- --- ---
--- --- 0 --- 240 --- --- --- 24
0 --- --- --- 0 --- --- --- 0
24 --- 0 --- 0 --- --- --- 4
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
64 --- 200 --- 0 --- --- --- ---
--- --- --- --- --- --- --- --- ---
Milk-run Material Supply System
57
--- --- --- --- --- --- --- --- ---
Selected route with (7;5) part.
Step #7
--- --- --- --- --- --- --- --- ---
--- --- 0 --- --- --- --- --- 24
0 --- --- --- --- --- --- --- 0
24 --- 0 --- --- --- --- --- 4
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
Selected route with (2;3) part.
1 alternate candidate for branching: (3;1).
2
Step #8
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- 0
0 --- --- --- --- --- --- --- 0
--- --- --- --- --- --- --- --- ---
Research Methodology
58
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- ---
Selected route with (3;9) part.
1 alternate candidate for branching: (4;1).
Resulting path:
City 1 -> City 2 -> City 3 -> City 9 -> City 8 -> City 7 -> City 5 -> City 6-> City 4 -> City 1
The price is 2135 units.
Route: 3
Variant #3 Task
Task:
--- 280 465 585 780 1010 905 1330 1250 1030 755 435
280 --- 190 310 510 735 630 1025 1080 815 545 140
465 190 --- 130 330 555 450 840 905 945 750 250
585 310 130 --- 230 455 570 740 800 1065 365 375
780 510 330 230 --- 260 375 545 605 905 705 470
1010 735 555 455 260 --- 165 285 350 700 575 650
905 630 450 570 375 165 --- 445 385 610 415 495
1330 1025 840 740 545 285 445 --- 100 465 575 935
1250 1080 905 800 605 350 385 100 --- 370 495 880
Milk-run Material Supply System
59
1030 815 945 1065 905 700 610 465 370 --- 275 685
755 545 750 365 705 575 415 575 495 275 --- 410
435 140 250 375 470 650 495 935 880 685 410 ---
Variant #3 Solution
Step #1
--- 0 185 305 405 730 625 1050 970 750 475 155
0 --- 50 170 275 595 490 885 940 675 405 0
195 60 --- 0 105 425 320 710 775 815 620 120
315 180 0 --- 5 325 440 610 670 935 235 245
410 280 100 0 --- 30 145 315 375 675 475 240
705 570 390 290 0 --- 0 120 185 535 410 485
600 465 285 405 115 0 --- 280 220 445 250 330
1090 925 740 640 350 185 345 --- 0 365 475 835
1010 980 805 700 410 250 285 0 --- 270 395 780
615 540 670 790 535 425 335 190 95 --- 0 410
340 270 475 90 335 300 140 300 220 0 --- 135
155 0 110 235 235 510 355 795 740 545 270 ---
Selected route with (9;8) part.
Step #2
--- 0 185 305 405 730 625 --- 970 750 475 155
0 --- 50 170 275 595 490 --- 940 675 405 0
Research Methodology
60
195 60 --- 0 105 425 320 --- 775 815 620 120
315 180 0 --- 5 325 440 --- 670 935 235 245
410 280 100 0 --- 30 145 --- 375 675 475 240
705 570 390 290 0 --- 0 --- 185 535 410 485
600 465 285 405 115 0 --- --- 220 445 250 330
1090 925 740 640 350 185 345 --- --- 365 475 835
--- --- --- --- --- --- --- --- --- --- --- ---
615 540 670 790 535 425 335 --- 95 --- 0 410
340 270 475 90 335 300 140 --- 220 0 --- 135
155 0 110 235 235 510 355 --- 740 545 270 ---
Selected route with (11;10) part.
Step #3
--- 0 185 305 405 730 625 --- 875 --- 475 155
0 --- 50 170 275 595 490 --- 845 --- 405 0
195 60 --- 0 105 425 320 --- 680 --- 620 120
315 180 0 --- 5 325 440 --- 575 --- 235 245
410 280 100 0 --- 30 145 --- 280 --- 475 240
705 570 390 290 0 --- 0 --- 90 --- 410 485
600 465 285 405 115 0 --- --- 125 --- 250 330
905 740 555 455 165 0 160 --- --- --- 290 650
--- --- --- --- --- --- --- --- --- --- --- ---
Milk-run Material Supply System
61
615 540 670 790 535 425 335 --- 0 --- --- 410
--- --- --- --- --- --- --- --- --- --- --- ---
155 0 110 235 235 510 355 --- 645 --- 270 ---
Selected route with (10;9) part.
Step #4
--- 0 185 305 405 730 625 --- --- --- 240 155
0 --- 50 170 275 595 490 --- --- --- 170 0
195 60 --- 0 105 425 320 --- --- --- 385 120
315 180 0 --- 5 325 440 --- --- --- 0 245
410 280 100 0 --- 30 145 --- --- --- 240 240
705 570 390 290 0 --- 0 --- --- --- 175 485
600 465 285 405 115 0 --- --- --- --- 15 330
905 740 555 455 165 0 160 --- --- --- 55 650
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
155 0 110 235 235 510 355 --- --- --- 35 ---
Selected route with (1;2) part.
1 alternate candidate for branching: (2;1).
Step #5
--- --- --- --- --- --- --- --- --- --- --- ---
Research Methodology
62
--- --- 50 170 275 595 490 --- --- --- 170 0
195 --- --- 0 105 425 320 --- --- --- 385 120
315 --- 0 --- 5 325 440 --- --- --- 0 245
410 --- 100 0 --- 30 145 --- --- --- 240 240
705 --- 390 290 0 --- 0 --- --- --- 175 485
600 --- 285 405 115 0 --- --- --- --- 15 330
905 --- 555 455 165 0 160 --- --- --- 55 650
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
120 --- 75 200 200 475 320 --- --- --- 0 ---
Selected route with (2;12) part.
Step #6
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
75 --- --- 0 105 425 320 --- --- --- 385 ---
195 --- 0 --- 5 325 440 --- --- --- 0 ---
290 --- 100 0 --- 30 145 --- --- --- 240 ---
2
585 --- 390 290 0 --- 0 --- --- --- 175 ---
480 --- 285 405 115 0 --- --- --- --- 15 ---
Milk-run Material Supply System
63
785 --- 555 455 165 0 160 --- --- --- 55 ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
0 --- 75 200 200 475 320 --- --- --- 0 ---
Selected route with (6;7) part.
Step #7
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
75 --- --- 0 100 425 --- --- --- --- 385 ---
195 --- 0 --- 0 325 --- --- --- --- 0 ---
290 --- 100 0 --- 30 --- --- --- --- 240 ---
--- --- --- --- --- --- --- --- --- --- --- ---
480 --- 285 405 110 --- --- --- --- --- 15 ---
785 --- 555 455 160 0 --- --- --- --- 55 ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
0 --- 75 200 195 475 --- --- --- --- 0 ---
Selected route with (4;5) part.
Step #8
Research Methodology
64
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
75 --- --- 0 --- 425 --- --- --- --- 385 ---
--- --- --- --- --- --- --- --- --- --- --- ---
290 --- 25 --- --- 30 --- --- --- --- 240 ---
--- --- --- --- --- --- --- --- --- --- --- ---
465 --- 195 390 --- --- --- --- --- --- 0 ---
785 --- 480 455 --- 0 --- --- --- --- 55 ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
0 --- 0 200 --- 475 --- --- --- --- 0 ---
Selected route with (3;4) part.
Step #9
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
0 --- 0 --- --- 5 --- --- --- --- 215 ---
--- --- --- --- --- --- --- --- --- --- --- ---
200 --- 195 --- --- --- --- --- --- --- 0 ---
Milk-run Material Supply System
65
520 --- 480 --- --- 0 --- --- --- --- 55 ---
--- --- --- --- --- --- --- --- --- --- --- ---
3
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- 0 --- --- 475 --- --- --- --- 0 ---
Selected route with (5;1) part.
Step #10
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- 195 --- --- --- --- --- --- --- 0 ---
--- --- 480 --- --- 0 --- --- --- --- 55 ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- 0 --- --- 475 --- --- --- --- 0 ---
Selected route with (8;6) part.
Research Methodology
66
Step #11
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- 0 --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- --- --- --- --- --- --- --- --- --- ---
--- --- 0 --- --- --- --- --- --- --- 0 ---
Selected route with (7;3) part.
1 alternate candidate for branching: (12;11).
Resulting path:
City 1 -> City 2 -> City 12 -> City 11 -> City 10 -> City 9 -> City 8 -> City 6 -> City 7 ->
City 3 -> City 4 -> City 5 -> City 1
The price is 3615 units.
Milk-run Material Supply System
67
TABLE 4.4 Comparison of Existing and Milk-Run Supply System
Sr. No. Existing Supply
System (km.)
Milk-Run Supply
System (km.)
Route 1 140 225
Route 2 60 240
Route 3 40 390
Route 4 140
Route 5 100
Route 6 300
Route 7 240
Total Distance 1020 855
Transportation Cost
(Rs.) 8160 6840
Table 4.3 shows the comparison of the transportation cost between the existing material supply
system and milk-run material supply system. It has been observed that the implementation of
the milk-run material supply system in existing logistic services can have reduction in the
transportation cost to a greater extent.
68
CHAPTER – 5
Result and Discussion
A genetic algorithm is applied to resolve the current routing problem in the courier industry
using the milk-run material supply system. Input data is used to solve the problem;
Matrix of distance, position and travelling time of each station zone wise
Demand data of each station (Volume per cycle) with the cycle
5.1 Development of Routes
The routes have been constructed by genetic algorithm in Matlab based on the geographical
location and distance between each station. The algorithm performed using a graphic user
interface to display the routes, scheduling, total cost, distance and time of travelling of each
zone. The Gujarat state is considered for solving the vehicle routing problem in courier industry.
It is basically divided into five different zones based on the location of the regional offices i.e.
Mehsana, Ahmedabad, Rajkot, Vadodara and Surat. Each zonal office covers the nearby stations
or area. The routes are developed in a cyclic manner based on milk-run material supply system
for various zones. Fig. 5.1 shows the map of Gujarat with all major cities. The location of five
regional offices covers almost all major area of the state.
Development of Routes
69
FIGURE 5.1: Map of Gujarat State
5.1.1 Mehsana Zone
Mehsana regional office covers the area of north Gujarat. It distributes and collects goods from
20 cities around the northern area of the state. A couple of routes are developed by the genetic
algorithm based on a location of stations. Following fig. 5.2 to fig. 5.4 show the routes, total
cost, scheduling of vehicles, travelling distance and travelling time.
Result and Discussion
70
FIGURE 5.2: Scheduling and Routing for Route 1 for Mehsana Zone
FIGURE 5.3: Scheduling and Routing for Route 2 for Mehsana Zone
Development of Routes
71
FIGURE 5.4: Scheduling and Routing for Mehsana Zone
5.1.2 Ahmedabad Zone
Ahmedabad regional office is a centre point of Gujarat state. It is one of the busiest stations of
state. It covers the area of middle Gujarat and Kutch region. It runs service to 29 cities around
the middle-west area of the state. Three routes are developed by the genetic algorithm based on
the location of stations. Following fig. 5.5 to fig. 5.8 show all three routes, total cost, scheduling
of vehicles, travelling distance and travelling time.
Result and Discussion
72
FIGURE 5.5: Scheduling and Routing for Route 1 for Ahmedabad Zone
FIGURE 5.6: Scheduling and Routing for Route 2 for Ahmedabad Zone
Development of Routes
73
FIGURE 5.7: Scheduling and Routing for Route 3 for Ahmedabad Zone
FIGURE 5.8: Scheduling and Routing for Ahmedabad Zone
Result and Discussion
74
5.1.3 Rajkot Zone
Rajkot regional office covers the area of Saurashtra region. It has to go through the longest
travelling distance. It serves in 27 cities around the southern-east part of the state. Four routes
are developed by the genetic algorithm based on the location of stations. Following fig. 5.9 to
fig. 5.13 show the routes, total cost, scheduling of vehicles, travelling distance and travelling
time.
FIGURE 5.9: Scheduling and Routing for Route 1 for Rajkot Zone
Development of Routes
75
FIGURE 5.10: Scheduling and Routing for Route 2 for Rajkot Zone
FIGURE 5.11: Scheduling and Routing for Route 3 for Rajkot Zone
Result and Discussion
76
FIGURE 5.12: Scheduling and Routing for Route 4 for Rajkot Zone
FIGURE 5.13: Scheduling and Routing for Rajkot Zone
Development of Routes
77
5.1.4 Vadodara Zone
Vadodara regional office covers the area of south Gujarat. It runs service to 16 cities in the
southern part of the state. Two routes are developed by the genetic algorithm based on the
location of stations. Following fig. 5.14 to fig. 5.16 show the routes, total cost, scheduling of
vehicles, travelling distance and travelling time.
FIGURE 5.14: Scheduling and Routing for Route 1 for Vadodara Zone
Result and Discussion
78
FIGURE 5.15: Scheduling and Routing for Route 2 for Vadodara Zone
FIGURE 5.16: Scheduling and Routing for Vadodara Zone
Development of Routes
79
5.1.5 Surat Zone
Surat regional office covers the area of south Gujarat. It distributes and collects the goods from
10 cities across the southern part of the state. Two routes are developed by the genetic algorithm
based on the location of stations. Following fig. 5.17 to fig. 5.19 show the routes, total cost,
scheduling of vehicles, travelling distance and travelling time.
FIGURE 5.17: Scheduling and Routing for Route 1 for Surat Zone
Result and Discussion
80
FIGURE 5.18: Scheduling and Routing for Route 2 for Surat Zone
FIGURE 5.19: Scheduling and Routing for Surat Zone
Development of Routes
81
5.1.6 Gujarat Region
Gujarat state has been divided into five major zones. The routes are developed zone wise based
on the location and distance of the each station. Total 17 routes are developed that covers 110
cities, which almost cover the whole Gujarat state. Fig. 5.20 shows the routes and location of
the regional offices of the Gujarat.
FIGURE 5.20: Scheduling and Routing of Gujarat Region
Based on the output of the program, Table 5.1 shows comparison of conventional supply system
and the milk-run material supply system in terms of total travelling distance and transportation
cost per day for supplier in the entire Gujarat region. The current transportation system has a
total travelling distance and transportation cost which is 7435 km. and Rs. 59480 per day in
Gujarat state respectively. It is way too high as compared to the optimal total travelling distance
and transportation cost which is 5555 km. and Rs. 48730 per day respectively by using the milk-
run material system. It can be concluded from the below table that milk-run supply system
optimize the travelling distance by 25.28 % or 1880 km. in a day and total transportation cost
as Rs. 10750 or 18.07 % per day.
Result and Discussion
82
TABLE 5.1: Comparison of Conventional Supply System and Milk-Run Material Supply System (Distance
and Overall Cost)
In linear correlation between travelling distance and travelling time, Table 5.2 represents the
reduction in total travelling time. It can be seen from the below table that the milk-run supply
system can optimize the travelling time by 24.40 % in a day in all zones. According to the
current material supply system, the total travelling time is 184.20 hrs., which can be reduced to
139.25 hrs. by successfully implementing milk-run material supply system.
Sr. No. Conventional supply
system (km.)
Milk-run supply
system (km.)
Mehsana Zone 1020 643
Ahmedabad Zone 2000 1753
Rajkot Zone 2580 2047
Vadodara Zone 965 611
Surat Zone 870 501
Total Distance 7435 5555
Transportation Cost
(Rs./Day) 59480 48730
Express Service
83
TABLE 5.2: Comparison of Conventional Supply System and Milk-Run Material Supply System (Travelling
Time)
5.2 Express Service
The provision for express service delivery is also employed in the proposed milk-run material
supply system, if total load is equivalent to the capacity of a vehicle, which needs to be delivered
from one station to another destination. Some of the examples have been shown in fig. 5.21 to
fig. 5.23. The graphical user interface represents the travelling time, distance, detail map and
total transportation cost of one station to another if full vehicle’s capacity load is distributed. As
it requires the origin station name, destination station name and number of travelling vehicle for
the respective route as an input data, the route is developed by the help of genetic algorithm in
Matlab based origin and destination. Total cost, travelling time and distance are calculated by
Matlab based on each route.
Sr. No. Conventional supply
system (Time)
Milk-run supply
system (Time)
Mehsana Zone 26.40 Hrs. 18.55 Hrs.
Ahmedabad Zone 49.10 Hrs. 40.10 Hrs.
Rajkot Zone 60.10 Hrs. 50.10 Hrs.
Vadodara Zone 28.20 Hrs. 19.05 Hrs.
Surat Zone 20.40 Hrs. 11.45 Hrs.
Total 184.20 Hrs. 139.25 Hrs.
Result and Discussion
84
FIGURE 5.21: Express Service from Unjha to Vapi
FIGURE 5.22: Express Service from Rapar to Godhara
CO2 Emission
85
FIGURE 5.23: Express Service from Junagadh to Gandhinagar
5.3 CO2 Emission
The problem of air pollution has become a global issue. As the technology is growing rapidly,
the fatal diseases in human being are increasing which includes lung cancer due to the polluted
air. It also contributes to smog, acid rain and damage to other living organisms such as birds,
animals and food crops. This research optimised the vehicle’s utilisation rate and distance by
constructing the cyclic routes instead of direct shipment. The result indicates improvement in
utilisation of vehicle and shortens the distance by implementing simultaneous pick-up and
delivery in a cyclic manner. The gas emission in the environment can be calculated from the
given formula also the GUI to calculate the CO2 emission of Gujarat is developed, which is
shown in fig. 5.24. The aim of this research work is to achieve effective utilisation of the vehicle
and reduction of overall carbon emission in the environment.
Result and Discussion
86
CO2 EM = VH × MI × D × EF (11)
where,
CO2 EM = CO2 emission in (kg)
VH = Number of Vehicle
MI = Mileage of vehicle (Km/Lt)
D = Distance travelled by vehicle (km)
EF = Emission Factor (Kg/Lt)
FIGURE 5.24: CO2 Emission of Gujarat Region
Vehicle Routing Database
87
5.4 Vehicle Routing Database
The android application has been developed to track the vehicle throughout the route. This
application will be installed and run into each station of the respective route for supervision and
inspection purpose. It will be also installed into the mobile handset of a driver to make sure that
the data input is authentic and correct. It will indicate the detailed schedule and weight
distribution (Both pick-up and delivery) of the entire route. The analysis was made through the
available database, which will indicate the weight distribution across the logistic network. Fig.
5.25 shows the input page of the application, through which data entry can be done.
FIGURE 5.25: Vehicle Routing Android Application
Result and Discussion
88
FIGURE 5.26: Vehicle Routing Weight Analysis
This android application is run as a trial testing to obtain the database for one week. The prepared
database will be used for the future reference to forecast the demand and supply, which will
support to determine the number of vehicles and scheduling of vehicles required in each route.
Based on the trial testing the database is prepared and analyzed in Matlab by using the graphical
user interface to determine the weight distribution in entire Gujarat state, which is shown in fig.
5.26. It will also indicate the travelling time required between two stations and driver’s detail of
the delivery took place in the past. The above fig. 5.26 shows the amount of weight carried
between each station. The red line indicates the weight distribution taken place above 750 kg.
between two stations. Likewise, orange line, yellow line and green line represent the weight
distribution between 350 kg. to 750 kg., 175 kg. to 350 kg. and below 175 kg. respectively. It
has been observed from the fig. 5.26 that the ratio of weight distribution is higher between major
cities and regional offices as compared to the small cities and isolated places.
Red: Above 750 kg.
Orange: Between 350 kg.
to 750 kg.
Yellow: Between 175 kg.
to 350 kg.
Green: Below 175 kg.
Development of Routes with Uncertain Demand
89
5.5 Development of Routes with Uncertain Demand
There are many uncertainties existing in the practical environment, such as delivery reliability,
stochastic customer demand, dynamic environment etc. These uncertainties are having influence
on vehicle scheduling and transportation cost. The demand and supply highly depend on the
market scenario. It varies according to the seasons, customer’s nature, festivals and various
regions. In supply chain management, demand of the consumer impact on the transportation
system extremely. Transportation cost, no. of vehicles and scheduling depends on the demand
and supply to a greater extent. Uncertain and stochastic demand may lead to additional
transportation cost and dissatisfaction of customer. In such kind of situation, it is inevitable to
develop the model, which has an ability to form the routes according to the necessity and
optimize the transportation cost and travelling time.
The genetic algorithm has been modified to overcome the issues of the dynamic environment.
Mehsana zone (Route: 1) has been considered to demonstrate the model with uncertain demand.
It has 9 stations, which are listed below.
Mehsana
Gozaria
Visnagar
Vadnagar
Kheralu
Satlasana
Palanpur
Sidhpur
Unjha
Mehsana
Initially, the route is developed with the full demand of each station. Fig. 5.27 shows the
development of routes with an uncertain environment (Case: 1) with demand at each station. It
has been noticed that the distance, travelling time and cost are 241 km., 7 hr. 25 min., Rs. 2258
respectively with demand at each station.
Result and Discussion
90
FIGURE 5.27: Development of Routes with Uncertain Demand (Case: 1)
Fig. 5.28 shows the development of routes with an uncertainty in demand (Case: 2). In the
simulation of second case the demand of two stations (Vadnagar and Satlasana) are considered
to be zero. The genetic algorithm has developed a new route according to the demand of each
station. It has formed the route by removing theses stations (Vadnagar and Satlasana) from the
network, which have different travelling distance, time and cost as compared to previous case.
It can be seen from fig. 5.28 that the distance, travelling time and cost are reduced to 202 km.,
6 hr. 15 min., Rs. 1946 respectively.
Development of Routes with Uncertain Demand
91
FIGURE 5.28: Development of Routes with Uncertain Demand (Case: 2)
The modified genetic algorithm has tested one more time by considering the zero demand of
any other stations, which is shown in fig. 5.29 (Case: 3). The demand of Gozaria and Satlasana
are considered to be zero in another trial. According to the demand of each station, the route is
developed by an algorithm, which has different value than previous cases. It has been observed
that the distance, travelling time and cost is changed to 212 km., 6 hr. 45 min., Rs. 2016
respectively with demand at each station except Gozaria and Satlasana (Case: 3).
Result and Discussion
92
FIGURE 5.29: Development of Routes with Uncertain Demand (Case: 3)
It has been observed through above cases that the modified genetic algorithm can be employed
when the demand is uncertain. It has an ability to form the routes according to the demand of
each station. The algorithm can take out the stations from the route whose demand is nil and
construct the optimized route accordingly.
93
CHAPTER – 6
Conclusion and Future Scope
The Gujarat state is considered to study and implement the milk-run material supply system.
The vehicle routing problem in supply chain management has been studied for courier industry,
as it has a major involvement in the logistic industry. The mathematical model is formulated
and solved by heuristics approach for the route construction. A genetic algorithm is employed
in Matlab to solve the current travelling salesman problem. Gujarat has 196,024 km2 of total
area, which has been divided into five zones. According to the concept of the milk-run material
supply system total seventeen routes are constructed, which covers 110 cities across Gujarat.
It has been observed from the result that the overall cost, time and distance is significantly
reduced by implementing the milk-run material supply system in courier industry.
6.1 Conclusion
The following points can be concluded from the results;
In this study, the mathematical formulation and genetic algorithm is proposed for
homogeneous and heterogeneous fleets for VRPTWSPD encountered in real life
situations. In this research work, routes are constructed, service and delivery periods are
determined and schedule is obtained. Computational results and proposed procedure
represent an excellent performance.
The overall supply chain cost has minimized by implementing the milk-run system in
transportation network instead of direct shipment. It is seen from the results that the
overall cost is reduced by 18.07 % in a day, which is Rs. 10750 less per day as compared
to direct shipment.
Conclusion and Future Scope
94
The result shows the reduction in the carbon dioxide emission from the transportation
system by improving the vehicle utilization. The overall reduction of CO2 emission is
24.94 % per day in the environment.
The overall distance of the constructed routes is lower than the previous system. It is
seen from the result that vehicle’s travelling distance is decreased to 1880 km. per day,
which is 25.28 % less as compared to the conventional material supply system.
With the linear connection between vehicle’s travelling distance and travelling time, the
reduction of vehicle’s travelling time is calculated as 44.95 hrs. per day, which is
optimized by 24.40 %.
The model has also modified for uncertain and stochastic demand.
Hence implementation of the milk-run supply system can compress cycle time, minimize
distance, decrease total cost, reduce carbon emission, increase vehicle utilization and
improve profitability of the industry.
6.2 Future Scope
Future research will be mainly addressed towards extending the application of the
algorithm to various manufacturing environment to test its suitability and foster the
necessary improvement.
95
List of Reference
1. Baudin M (2004) Lean logistics: the nuts and bolts of delivering materials and goods.
Productivity press, New York.
2. Drira A, Pierreval H, Hajri-Gabouj S (2007) Facility layout problems: a survey.
Annual rev control 31, pp. 255–267.
3. Gamberi, M., Manzini, R., and Regattieri, A. (2009) An new approach for the
automatic analysis and control of material handling systems: Integrated layout flow
analysis (ILFA). The International Journal of Advanced Manufacturing Technology
41(1), pp. 156- 167.
4. Vaidyanathan BS, Matson JO, Miller DM, Matsona JE (1999) A capacitated vehicle
routing problem for just-in-time delivery. IIE Transportation 31, pp. 1083–1092.
5. Chuah KH, Yingling JC (2005) Routing for a just-in-time supply pickup and delivery
system. Transportation science 39, pp. 328–339.
6. Kumar CS, Panneerselvam R (2007) Literature review of JITKANBAN system.
International journal of advanced manufacturing technology 32, pp. 393–408.
7. Junior ML, Filho MG (2010) Variations of the Kanban system: literature review and
classification. Internal Journal production economics 125 pp. 13–21.
8. Hao Q, Shen W (2008) Implementing a hybrid simulation model for a Kanban-based
material handling system. Robot computer integer manufacturing 24 pp. 635–646.
9. Domingo R, Alvarez R, Pena MM, Calvo R (2007) Materials flow improvement in
a lean assembly line: a case study. Assembly automation 27 pp. 141–147.
96
10. Alvarez R, Calvo R, Pena MM, Domingo R (2009) Redesigning an assembly line
through lean manufacturing tools. International journal of advanced manufacturing
technology. pp. 949–958.
11. Boysen N, Bock S (2010) Scheduling just-in-time part supply for mixed-model
assembly lines. Europe Journal operation research 211, pp.15–25.
12. Costa B, Dias LD, Oliveira JA, Pereira G (2008) Simulation as a tool for planning a
material delivery system to manufacturing lines, IEMC international engineering
management conference.
13. Angelelli E, Mansini R (2002) The vehicle routing problem with time windows and
simultaneous pickup and delivery. In: Quantitative approaches to distribution
logistics and supply chain management, Lecture notes in economics and
mathematical systems, pp. 249– 267, Springer.
14. Ohlman JW, Fry MJ, Thomas BW (2008) Route design for lean production systems.
Transportation science 42, pp.352–370.
15. Satoglu S, Sahin E (2012) Design of JIT periodic material supply system for the
assembly line and an application in electronics industry. International journal of
advanced manufacturing technology. DOI 10.1007/s00170-012-4171-7.
16. Nemoto T, Hayashi K, Hashimoto M (2010) Milk-run logistics by Japanese
automobile manufacturers in Thailand. Proc Soc Behav Sci 2, pp. 5980–5989.
17. Kilic HS, Durmusoglum MB, Baskak M (2012) Classification and modelling for in-
plant milk-run distribution systems. International journal of advanced manufacturing
technology. doi: 10.1007/s00170-011-3875-4.
97
18. Brar G, Saini G (2011) Milk run logistics: Literature review and directions.
Proceedings of the world congress on engineering 2011 Vol I. WCE 2011, July 6 -
8, 2011, London, U.K.
19. M. Jafari-Eskandari, S.G.H. Jalali-Naiini, A.R. Aliahmadi, S.J. Sadjadi (2010) A
Robust optimization approach for the milk run problem with time windows under
inventory uncertainty - An auto industry supply chain case study. Proceedings of the
2010 International conference on industrial engineering and operations management,
Dhaka, Bangladesh, January 9 – 10, 2010.
20. Dipteshkumar Patel, Dr. M. B. Patel, Dr. J. A. Vadher (2014) Implementation of
milk run material supply system in vehicle routing problem with simultaneous
pickup and delivery. International journal of application or innovation in engineering
& management, Volume 3, Issue 11, November 2014.
21. Theeratham M., Manoj Lohatepanont. (2006). Vehicle routing in milk-run
operations: A column generation based approach. Proceedings of the 2006 national
conference of the operations research network in Thailand. Bangkok, Thailand.
22. David Gyulaia, Andras Pfeiffera, Thomas Sobottkab, Jozsef Vanczaa (2013) Milk-
run vehicle routing approach for shop-floor logistics. Forty sixth cirp. Conference
on manufacturing systems, pp. 127 – 132.
23. Yong Wang, Xiaolei Ma, Yunteng Lao, Yinhai Wang, Haijun Mao (2012) Vehicle
routing problem: simultaneous deliveries and pickups with split loads and time
windows. 92nd Annual meeting of the transportation research board.
24. Chuanzhong Yin, Lei Bu, Haitao Gong (2013) Mathematical model and algorithm
of split load vehicle routing problem with simultaneous delivery and pickup.
International journal of innovative computing, information and control, Volume 9,
98
Number 11, November 2013, Volume 9, Number 11, November 2013, pp. 4497-
4508.
25. Xiaobing Gan, Yan Wang, Shuhai Li, Ben Niu (2012) Vehicle routing problem with
time windows and simultaneous delivery and pick-up service based on MCPSO.
Hindawi publishing corporation mathematical problems in engineering, Volume
2012, Article ID 104279.
26. Jing Fan (2011) The vehicle routing problem with simultaneous pickup and delivery
based on customer satisfaction. Advanced in control engineering and information
science, Procedia engineering 15 (2011), pp. 5284 – 5289.
27. Liang Chun-Hua, Zhou Hong, Zhao Jian (2009) Vehicle routing problem with time
windows and simultaneous pickups and deliveries.
28. A. Serdar Tasan, Mitsuo Gen (2012) A genetic algorithm based approach to vehicle
routing problem with simultaneous pick-up and deliveries. Computers & industrial
engineering 62 (2012), pp. 755–761.
29. Abbas Gharib Garakani, Mohammad Reza Razzazi (2012) A solution to multi
capacitated depot vehicle routing problem with pickup and delivery customers and
soft time window using genetic algorithm. International journal of science and
research (IJSR), Volume 3 Issue 9, September 2014, pp. 80-82.
30. Sadjadi SJ, Jafari M, Amini T (2009) A new mathematical modelling and a genetic
algorithm search for milk run problem an auto industry supply chain case study.
International journal advanced manufacturing technology 44, pp. 194–200.
31. Duygu Yilmaz Eroglu, Carlo Rafele, Anna Corinna Cagliano, Sultan Sevilay Murat,
Massimo Ippolito (2014) Simultaneous routing and loading method for milk-run
99
using hybrid genetic search algorithm. XII. International logistics and supply chain
congress, 30-31 October 2014 - Istanbul, Turkey.
32. Sangeeta, Sonia Sharma (2015) Simultaneously pickup and delivery MDVRP with
multi objective GA. International journal of computer application, Volume 5– No.
4, June 2015 pp. 2250-1797.
33. Niaz A. Wassan, Gabor Nagy (2014) vehicle routing problem with deliveries and
pickups: modelling issues and meta-heuristics solution approaches. International
journal of transportation, Vol.2, No.1 (2014), pp. 95-110.
34. Qingguo Jiang, Chao Wang, Dong Mu, Lingyun Zhou (2015) A hybrid metaheuristic
algorithm for the VRPSPD problem. Journal of computational information systems
11: 13, pp. 4845–4856.
35. Cevriye Gencer, Emel Kizilkaya Aydogan, Suna Cetin (2010) Simultaneous pick-up
and delivery decision support systems, Advances in decision support systems, Book
edited by: Ger Devlin, ISBN 978-953-307-069-8, pp. 342, March 2010, INTECH,
Croatia.
36. C. Haksever, B. Render, R. Russell, and R. Murdick (2000) Vehicle routing and
scheduling, Service management and operations, 2nd edition prentice hall: Upper
saddle river, NJ, pp. 476–497.
37. Huseyin Selcuk Kilic, M. Bulent Durmusoglu, Murat Baskak (2012) Classification
and modeling for in-plant milk-run distribution systems. International journal of
advanced manufacturing technology. DOI 10.1007/s00170-011-3875-4.
38. Ben Peterson, Willem-Jan van Hoeve, Sham Kekre, Laurens Debo (2010) Flexible
milk-runs for stochastic vehicle routing, research showcase, Carnegie mellon
university.
100
39. Gurinder Singh Brar, Gagan Saini (2011) Milk run logistics: literature review and
directions, Proceedings of the world congress on engineering 2011, Vol I, WCE
2011, July 6 - 8, 2011, London, U.K.
40. Pacharawan Suebsangin, Naruemol Ratanamalakul, Aussadavut Dumrongsiri
(2013) Planning of production, inventory and logistics with direct shipment and milk
run strategies: Numerical experiment, Journal of social and development sciences,
Vol. 4, No. 2, pp. 39-46, Feb 2013 (ISSN 2221-1152).
41. Xin Zhou, Liangping Shi, Bingzhi Huang (2012) Integrated inventory model with
stochastic lead time and controllable variability for milk runs, Journal of industrial
and management optimization, Volume 8, Number 3, pp.657-672.
42. Manik G. Vig, Nomesh Bolia, G. Sundararaman (2013) Optimization of ‘Milk Run’
of JCB India Ltd. (Ballabhgarh Plant). Journal of traffic and logistics engineering,
Vol, 1, No. 2 December 2013.
43. Zhenlai You, Yang Jiao (2014) Development and application of milk-run
distribution systems in the express industry based on saving algorithm, Hindawi
publishing corporation mathematical problems in engineering, Volume 2014, Article
ID 536459, 6 pages.
44. Ran Liu, Xiaolan Xie, Vincent Augusto, Carlos Rodriguez (2013) Heuristic
algorithms for a vehicle routing problem with simultaneous delivery and pickup and
time windows in home health care, European journal of operational research 230,
pp. 475–486.
45. Kiran M., Cijo Mathew, Jacob Kuriakose (2013) A modified savings algorithm
based approach for vehicle routing problem with simultaneous pick-up and delivery,
101
International journal of emerging technology and advanced engineering, Volume 3,
Issue 10, October 2013.
46. Aravind.P., Deepak Eldho Babu, Brijesh Paul (2014) A review of vehicle routing
problem with simultaneous pickup and delivery, International journal of engineering
trends and technology (IJETT) – Volume 15 Number 4 – Sep 2014.
47. Pandhapon Sombuntham, Voratas Kachitvichayanukul (2010) a particle swarm
optimization algorithm for multi-depot vehicle routing problem with pickup and
delivery requests, International conference of engineers and computer scientists,
Vol. III, March 17-19, 2010, Hong Kong.
48. Ismail Karaoglan, Fulya Altiparmak, Imdat Kara, Berna Dengiz (2011) A branch and
cut algorithm for the location-routing problem with simultaneous pickup and
delivery, European journal of operational research 211 (2011), pp. 318–332.
49. Jafari-Eskandari M., Sadjadi SJ., Jabalameli MS., Bozorgi-Amiri A. (2009) A robust
optimization approach for the milk run problem (An auto industry supply chain case
study). International conference on computers & industrial engineering, 6–9 July
2009, Troyes, France, pp. 1076–1081.
50. T. Du, F. K. Wang, P. Y. Lu (2007) A real-time vehicle-dispatching system for
consolidating milk-runs, Transportation research , Vol. 43, No. 5, pp. 565–577,
2007.
51. Maria Jose, Subha Sreekumar (2016) Comparison of BFS and prim's algorithm when
used in MANETs routing, International journal of computer applications technology
and research, Volume 5– Issue 2, pp. 92 - 94, 2016, ISSN:- 2319–8656.
52. Nagy G, Salhi S (2005) Heuristic algorithms for single and multiple depot vehicle
routing problems with pickups and deliveries. Europe journal operation research
162, pp. 126–141.
102
List of Publication
1. Diptesh Patel and Dr. M.B.Patel (2013): Optimization approach of vehicle routing by a
milk-run material supply system, International Journal for Scientific Research &
Development, ISSN: 2321-0613, Volume 1, Issue 6, July 2013, pp: 1315-1318.
2. Diptesh Patel and Dr. M.B.Patel (2013): Design and development of an internal milk-
run material supply system in automotive industry, International Journal of Application
or Innovation in Engineering & Management, ISSN: 2319 – 4847, Volume 2, Issue 8,
August 2013, pp: 233-235.
3. Diptesh Patel, Dr. M.B.Patel and Dr. J.A. Vadher (2014): Implementation of milk run
material supply system in vehicle routing problem with simultaneous pickup and
delivery, International Journal of Application or Innovation in Engineering &
Management, ISSN: 2319 – 4847, Volume 3, Issue 11, November 2014, pp: 122-124.
4. Diptesh Patel, Dr. M.B.Patel and Dr. J.A. Vadher (2017): Design and development of
milk-run material supply system with time windows and simultaneous pickups and
deliveries, International Journal for Innovative Research in Science & Technology,
ISSN : 2349-6010, Volume 4, Issue 2, July 2017 : 156-166.
103
APPENDIX – 1
Graphical User Interface
function varargout = All_in_one(varargin)
% ALL_IN_ONE MATLAB code for All_in_one.fig
% ALL_IN_ONE, by itself, creates a new ALL_IN_ONE or raises the existing
% singleton*.
%
% H = ALL_IN_ONE returns the handle to a new ALL_IN_ONE or the handle to
% the existing singleton*.
%
% ALL_IN_ONE('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in ALL_IN_ONE.M with the given input arguments.
%
% ALL_IN_ONE('Property','Value',...) creates a new ALL_IN_ONE or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before All_in_one_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to All_in_one_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help All_in_one
% Last Modified by GUIDE v2.5 03-Oct-2016 16:11:16
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @All_in_one_OpeningFcn, ...
104
'gui_OutputFcn', @All_in_one_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before All_in_one is made visible.
function All_in_one_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% varargin command line arguments to All_in_one (see VARARGIN)
% Choose default command line output for All_in_one
handles.output = hObject;
%create an axes that spans the whole gui
ah = axes('unit', 'normalized', 'position', [0 0 1 1]);
% import the background image and show it on the axes
bg = imread('images.jpg'); imagesc(bg);
% prevent plotting over the background and turn the axis off
set(ah,'handlevisibility','off','visible','off')
% making sure the background is behind all the other uicontrols
uistack(ah, 'bottom');
105
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes All_in_one wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = All_in_one_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
% --- Executes on button press in Schedule.
function Schedule_Callback(hObject, eventdata, handles)
% hObject handle to Schedule (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run untitled1.m
% --- Executes on button press in WD.
function WD_Callback(hObject, eventdata, handles)
% hObject handle to WD (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run untitled.m
% --- Executes on button press in VR.
function VR_Callback(hObject, eventdata, handles)
% hObject handle to VR (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
106
% handles structure with handles and user data (see GUIDATA)
run Vad.m
% --- Executes on button press in AR.
function AR_Callback(hObject, eventdata, handles)
% hObject handle to AR (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run Ahm.m
% --- Executes on button press in MR.
function MR_Callback(hObject, eventdata, handles)
% hObject handle to MR (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run Meh.m
% --- Executes on button press in RR.
function RR_Callback(hObject, eventdata, handles)
% hObject handle to RR (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run Raj.m
% --- Executes on button press in GA.
function GA_Callback(hObject, eventdata, handles)
% hObject handle to GA (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run mtspf_ga_GOOOD_ONE.m
% --- Executes on button press in S2S.
function S2S_Callback(hObject, eventdata, handles)
% hObject handle to S2S (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run XPERIMENT.m
107
% --- Executes on button press in SR.
function SR_Callback(hObject, eventdata, handles)
% hObject handle to SR (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run Sur.m
% --- Executes on button press in Close.
function Close_Callback(hObject, eventdata, handles)
% hObject handle to Close (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
close All_in_one.fig
% --- Executes on button press in GR.
function GR_Callback(hObject, eventdata, handles)
% hObject handle to GR (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run Gujarat.m
% --- Executes on button press in co2.
function co2_Callback(hObject, eventdata, handles)
% hObject handle to co2 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
run CO2_EMISSION.m
Published with MATLAB® R2015a
108
APPENDIX – 2
Database of Destination City
function [w22,w0,w01]=city_name_dt(dt_in)
[x,ahm]=xlsread('city_name.xlsx','ahm')
[x,meh]=xlsread('city_name.xlsx','meh')
[x,raj]=xlsread('city_name.xlsx','raj')
[x,sur]=xlsread('city_name.xlsx','sur')
[x,vad]=xlsread('city_name.xlsx','vad')
X1=strcmpi(ahm,dt_in)
X01=strcmpi(meh,dt_in)
X02=strcmpi(raj,dt_in)
X03=strcmpi(sur,dt_in)
X04=strcmpi(vad,dt_in)
if sum(sum(X1))==1
[w0,st_loc]=find(X1==1)
if st_loc==1
w01=num2str(st_loc)
w22=strcat('Ahm_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w22=strcat('Ahm_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w22=strcat('Ahm_',w01)
else
109
w01=num2str(st_loc)
w22=strcat('Ahm_',w01)
end
%11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111
11111111%
elseif sum(sum(X01))==1
[w0,st_loc]=find(X01==1)
if st_loc==1
w01=num2str(st_loc)
w22=strcat('Meh_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w22=strcat('Meh_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w22=strcat('Meh_',w01)
else
w01=num2str(st_loc)
w22=strcat('Meh_',w01)
end
%22222222222222222222222222222222222222222222222222222222222222222222222222222222222222222
2222222222222%
elseif sum(sum(X02))==1
[w0,st_loc]=find(X02==1)
if st_loc==1
w01=num2str(st_loc)
w22=strcat('Raj_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w22=strcat('Raj_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w22=strcat('Raj_',w01)
else
w01=num2str(st_loc)
110
w22=strcat('Raj_',w01)
end
%33333333333333333333333333333333333333333333333333333333333333333333333333333333333333333
33333333333%
elseif sum(sum(X03))==1
[w0,st_loc]=find(X03==1)
if st_loc==1
w01=num2str(st_loc)
w22=strcat('Sur_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w22=strcat('Sur_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w22=strcat('Sur_',w01)
else
w01=num2str(st_loc)
w22=strcat('Sur_',w01)
end
%44444444444444444444444444444444444444444444444444444444444444444444444444444444444444444
444444%
elseif sum(sum(X04))==1
[w0,st_loc]=find(X04==1)
if st_loc==1
w01=num2str(st_loc)
w22=strcat('Vad_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w22=strcat('Vad_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w22=strcat('Vad_',w01)
else
w01=num2str(st_loc)
w22=strcat('Vad_',w01)
end
111
else disp('Enter the valid city name')
end
%55555555555555555555555555555555555555555555555555555555555555555555555555555555555555555
5555555%
end
Published with MATLAB® R2015a
112
APPENDIX – 3
Database of Starting City
function [w002,w0,w01]=city_name_st(st_in)
major={'Ahmedabad','Mehsana','Vadodara','Surat','Rajkot'}
[x,ALL]=xlsread('city_name.xlsx','All')
[x,ahm]=xlsread('city_name.xlsx','ahm')
[x,meh]=xlsread('city_name.xlsx','meh')
[x,raj]=xlsread('city_name.xlsx','raj')
[x,sur]=xlsread('city_name.xlsx','sur')
[x,vad]=xlsread('city_name.xlsx','vad')
X0=strcmpi(ALL,st_in)
X1=strcmpi(ahm,st_in)
X01=strcmpi(meh,st_in)
X02=strcmpi(raj,st_in)
X03=strcmpi(sur,st_in)
X04=strcmpi(vad,st_in)
if sum(sum(X0))==1
[st_loc,w0]=find(X0==1)
if st_loc==1
w01=num2str(st_loc)
w002='Rajkot'
elseif st_loc==2
w01=num2str(st_loc)
w002='Ahmedabad'
elseif st_loc==3
w01=num2str(st_loc)
113
w002='Vadodara'
elseif st_loc==4
w01=num2str(st_loc)
w002='Surat'
elseif st_loc==5
w01=num2str(st_loc)
w002='Mehsana'
end % ALL are considered ...................................................%
elseif sum(sum(X1))==1
[w0,st_loc]=find(X1==1)
if st_loc==1
w01=num2str(st_loc)
w002=strcat('Ahm_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w002=strcat('Ahm_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w002=strcat('Ahm_',w01)
else
w01=num2str(st_loc)
w002=strcat('Ahm_',w01)
end
%11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111
11111111%
elseif sum(sum(X01))==1
[w0,st_loc]=find(X01==1)
if st_loc==1
w01=num2str(st_loc)
w002=strcat('Meh_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w002=strcat('Meh_',w01)
elseif st_loc==3
w01=num2str(st_loc)
114
w002=strcat('Meh_',w01)
else
w01=num2str(st_loc)
w002=strcat('Meh_',w01)
end
%22222222222222222222222222222222222222222222222222222222222222222222222222222222222222222
2222222222222%
elseif sum(sum(X02))==1
[w0,st_loc]=find(X02==1)
if st_loc==1
w01=num2str(st_loc)
w002=strcat('Raj_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w002=strcat('Raj_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w002=strcat('Raj_',w01)
else
w01=num2str(st_loc)
w002=strcat('Raj_',w01)
end
%33333333333333333333333333333333333333333333333333333333333333333333333333333333333333333
33333333333%
elseif sum(sum(X03))==1
[w0,st_loc]=find(X03==1)
if st_loc==1
w01=num2str(st_loc)
w002=strcat('Sur_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w002=strcat('Sur_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w002=strcat('Sur_',w01)
115
else
w01=num2str(st_loc)
w002=strcat('Sur_',w01)
end
%44444444444444444444444444444444444444444444444444444444444444444444444444444444444444444
444444%
elseif sum(sum(X04))==1
[w0,st_loc]=find(X04==1)
if st_loc==1
w01=num2str(st_loc)
w002=strcat('Vad_',w01)
elseif st_loc==2
w01=num2str(st_loc)
w002=strcat('Vad_',w01)
elseif st_loc==3
w01=num2str(st_loc)
w002=strcat('Vad_',w01)
else
w01=num2str(st_loc)
w002=strcat('Vad_',w01)
end
else disp('Enter the Valid city name')
%55555555555555555555555555555555555555555555555555555555555555555555555555555555555555555
5555555%
end
end
Published with MATLAB® R2015a
116
APPENDIX – 4
Calculation of CO2 Gas Emission
function varargout = CO2_EMISSION(varargin)
% CO2_EMISSION MATLAB code for CO2_EMISSION.fig
% CO2_EMISSION, by itself, creates a new CO2_EMISSION or raises the existing
% singleton*.
%
% H = CO2_EMISSION returns the handle to a new CO2_EMISSION or the handle to
% the existing singleton*.
%
% CO2_EMISSION('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in CO2_EMISSION.M with the given input arguments.
%
% CO2_EMISSION('Property','Value',...) creates a new CO2_EMISSION or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before CO2_EMISSION_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to CO2_EMISSION_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help CO2_EMISSION
% Last Modified by GUIDE v2.5 03-Oct-2016 12:44:25
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @CO2_EMISSION_OpeningFcn, ...
117
'gui_OutputFcn', @CO2_EMISSION_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before CO2_EMISSION is made visible.
function CO2_EMISSION_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% varargin command line arguments to CO2_EMISSION (see VARARGIN)
% Choose default command line output for CO2_EMISSION
handles.output = hObject;
%create an axes that spans the whole gui
ah = axes('unit', 'normalized', 'position', [0 0 1 1]);
% import the background image and show it on the axes
bg = imread('images.jpg'); imagesc(bg);
% prevent plotting over the background and turn the axis off
set(ah,'handlevisibility','off','visible','off')
% making sure the background is behind all the other uicontrols
uistack(ah, 'bottom');
118
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes CO2_EMISSION wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = CO2_EMISSION_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
function NV_Callback(hObject, eventdata, handles)
% hObject handle to NV (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
input=(get(hObject,'String'))
% Hints: get(hObject,'String') returns contents of NV as text
% str2double(get(hObject,'String')) returns contents of NV as a double
% --- Executes during object creation, after setting all properties.
function NV_CreateFcn(hObject, eventdata, handles)
% hObject handle to NV (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
119
set(hObject,'BackgroundColor','white');
end
function MV_Callback(hObject, eventdata, handles)
% hObject handle to MV (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
input=(get(hObject,'String'))
% Hints: get(hObject,'String') returns contents of MV as text
% str2double(get(hObject,'String')) returns contents of MV as a double
% --- Executes during object creation, after setting all properties.
function MV_CreateFcn(hObject, eventdata, handles)
% hObject handle to MV (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function DT_Callback(hObject, eventdata, handles)
% hObject handle to DT (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
input=(get(hObject,'String'))
% Hints: get(hObject,'String') returns contents of DT as text
% str2double(get(hObject,'String')) returns contents of DT as a double
120
% --- Executes during object creation, after setting all properties.
function DT_CreateFcn(hObject, eventdata, handles)
% hObject handle to DT (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
% --- Executes on button press in pushbutton1.
function pushbutton1_Callback(hObject, eventdata, handles)
% hObject handle to pushbutton1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
EFCO2=0.515
MV=(get(handles.MV,'string'))
NV=(get(handles.NV,'string'))
DT=(get(handles.DT,'string'))
NV1= str2double(NV)
DT1= str2double(DT)
MV1= str2double(MV)
X=1/MV1
CO2EM=NV1*(DT1+100)*X*EFCO2
set(handles.text5,'String',CO2EM)
Published with MATLAB® R2015a
121
APPENDIX – 5
Coding of Milk-Run Routing Supply System
st=input('Enter the name of starting city:','s')
dt=input('Enter the name of Destination city:','s')
Vehicle=input('Enter the number of Vehicles:')
major={'Ahmedabad','Mehsana','Vadodara','Surat','Rajkot'}
major01=xlsread('city_name.xlsx','All')
major02=xlsread('city_name.xlsx','All_1')
major03=xlsread('city_name.xlsx','All_2')
[Major_Name,Major_kms]=xlsread('Major kms.xlsx')
[ans,ans01,ans02]=city_name_st(st)
st_cl=ans01
st_rw=str2num(ans02)
st_name=ans
[ans,ans01,ans02]=city_name_dt(dt)
dt_cl=ans01
dt_rw=str2num(ans02)
dt_name=ans
% Startinf route Data ...................................................%
st01=st_name(1:3)
sheetnoS=st_name(5)
[x,y]=xlsread('city_name.xlsx',st01)
st_row=y(:,st_rw)
st_route=st_row(st_cl:length(st_row))
% Destination route data..................................................%
dt01=dt_name(1:3)
122
sheetnoD=dt_name(5)
[x1,y1]=xlsread('city_name.xlsx',dt01)
dt_row=y1(:,dt_rw)
dt_route=dt_row(1:dt_cl)
if strcmpi(dt01,'ahm')==1
MAJOR_dt=major(1)
elseif strcmpi(dt01,'meh')==1
MAJOR_dt=major(2)
elseif strcmpi(dt01,'vad')==1
MAJOR_dt=major(3)
elseif strcmpi(dt01,'sur')==1
MAJOR_dt=major(4)
elseif strcmpi(dt01,'raj')==1
MAJOR_dt=major(5)
end
% ............MAJOR DESTINATION .......................................................%
if strcmpi(st01,'ahm')==1
MAJOR_st=major(1)
elseif strcmpi(st01,'meh')==1
MAJOR_st=major(2)
elseif strcmpi(st01,'vad')==1
MAJOR_st=major(3)
elseif strcmpi(st01,'sur')==1
MAJOR_st=major(4)
elseif strcmpi(st01,'raj')==1
MAJOR_st=major(5)
end
% .... MAJOR CITY ROUTING DATA EXCEL SHEET.........................................................%
Mejor_city=strcat(st01,'_',dt01)
MJR_XL=xlsread('Regional.xlsx',Mejor_city)
route_sheet=xlsread('ROUTE SHEET.xlsx',st_name)
st_num_S=num2str(route_sheet(st_cl,2))
L0=length(route_sheet)
st_num_E=num2str(route_sheet(L0,2))
123
RANGE_S=num2str(strcat('A',st_num_S,':','B',st_num_E))
ST_XL=xlsread('Routing_data.xlsx',st_name,RANGE_S)
%___________________________________________________________________________________%
route_sheet=xlsread('ROUTE SHEET.xlsx',dt_name)
dt_num_D1=num2str(route_sheet(dt_cl,2))
RANGE_D=num2str(strcat('A1',':','B',dt_num_D1))
DT_XL=xlsread('Routing_data.xlsx',dt_name,RANGE_D)
Origin_st_data=[ST_XL;MJR_XL;DT_XL]
% ............................................................%
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'r','Marker','.', 'LineWidth', 3.5);
line(Origin_st_data(1, 1), Origin_st_data(1, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
line(Origin_st_data(end, 1), Origin_st_data(end, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
xlim([69.50,74.30]);
% Google map%
plot_google_map('maptype', 'roadmap');
[Major_Kms,Major_Name]=xlsread('Major kms.xlsx')
if strcmpi(MAJOR_st,Major_Name(1))==1
Q=1
elseif strcmpi(MAJOR_st,Major_Name(2))==1
Q=2
elseif strcmpi(MAJOR_st,Major_Name(3))==1
Q=3
elseif strcmpi(MAJOR_st,Major_Name(4))==1
Q=4
elseif strcmpi(MAJOR_st,Major_Name(5))==1
Q=5
end
124
if strcmpi(MAJOR_dt,Major_Name(1))==1
O=1
elseif strcmpi(MAJOR_dt,Major_Name(2))==1
O=2
elseif strcmpi(MAJOR_dt,Major_Name(3))==1
O=3
elseif strcmpi(MAJOR_dt,Major_Name(4))==1
O=4
elseif strcmpi(MAJOR_dt,Major_Name(5))==1
O=5
end
M_KMS=Major_Kms(Q,O)
St_range_cost=xlsread('All Routes kms.xlsx',st_name)
st_KMS=St_range_cost(st_cl,3)
Dt_range_cost=xlsread('All Routes kms.xlsx',dt_name)
dt_KMS=Dt_range_cost(dt_cl,2)
Total_KMS=st_KMS+dt_KMS+M_KMS
Vehicle_cost=Vehicle*330
Travelling_cost=Total_KMS*8
T_K=num2str(Total_KMS)
SUB_TIME=Total_KMS/50
TOTAL_HOUR=fix(SUB_TIME)
TOTAL_HOUR1=num2str(TOTAL_HOUR)
TOTAL_MIN=num2str(round((SUB_TIME*60)-(TOTAL_HOUR*60),0))
Total_cost=Vehicle_cost+Travelling_cost
Veh=num2str(Vehicle)
T_C=num2str(Total_cost)
DIPS1=strcat('For Traveling of : ',T_K,'','Kms','with',Veh,'of vehicals','.The Expected time for Journey
is:',TOTAL_HOUR1,' HOURS and','',TOTAL_MIN,' minutes','and total cost for traveling is',T_C)
125
APPENDIX – 6
Multiple Travelling Salesman Problem with Genetic
Algorithm
% MTSPF_GA Fixed Multiple Traveling Salesmen Problem (M-TSP) Genetic Algorithm (GA)
% Finds a (near) optimal solution to a variation of the M-TSP by setting
% up a GA to search for the shortest route (least distance needed for
% each salesman to travel from the start location to individual cities
% and back to the original starting place)
%
% Summary:
% 1. Each salesman starts at the first point, and ends at the first
% point, but travels to a unique set of cities in between
% 2. Except for the first, each city is visited by exactly one salesman
%
% Note: The Fixed Start/End location is taken to be the first XY point
%
% Input:
% USERCONFIG (structure) with zero or more of the following fields:
% - XY (float) is an Nx2 matrix of city locations, where N is the number of cities
% - DMAT (float) is an NxN matrix of city-to-city distances or costs
% - NSALESMEN (scalar integer) is the number of salesmen to visit the cities
% - MINTOUR (scalar integer) is the minimum tour length for any of the
% salesmen, NOT including the start/end point
% - POPSIZE (scalar integer) is the size of the population (should be divisible by 8)
% - NUMITER (scalar integer) is the number of desired iterations for the algorithm to run
% - SHOWPROG (scalar logical) shows the GA progress if true
% - SHOWRESULT (scalar logical) shows the GA results if true
% - SHOWWAITBAR (scalar logical) shows a waitbar if true
%
% Input Notes:
% 1. Rather than passing in a structure containing these fields, any/all of
% these inputs can be passed in as parameter/value pairs in any order instead.
126
% 2. Field/parameter names are case insensitive but must match exactly otherwise.
%
% Output:
% RESULTSTRUCT (structure) with the following fields:
% (in addition to a record of the algorithm configuration)
% - OPTROUTE (integer array) is the best route found by the algorithm
% - OPTBREAK (integer array) is the list of route break points (these specify the indices
% into the route used to obtain the individual salesman routes)
% - MINDIST (scalar float) is the total distance traveled by the salesmen
%
% Route/Breakpoint Details:
% If there are 10 cities and 3 salesmen, a possible route/break
% combination might be: rte = [5 6 9 4 2 8 10 3 7], brks = [3 7]
% Taken together, these represent the solution [1 5 6 9 1][1 4 2 8 10 1][1 3 7 1],
% which designates the routes for the 3 salesmen as follows:
% . Salesman 1 travels from city 1 to 5 to 6 to 9 and back to 1
% . Salesman 2 travels from city 1 to 4 to 2 to 8 to 10 and back to 1
% . Salesman 3 travels from city 1 to 3 to 7 and back to 1
%
% Usage:
% mtspf_ga
% -or-
% mtspf_ga(userConfig)
% -or-
% resultStruct = mtspf_ga;
% -or-
% resultStruct = mtspf_ga(userConfig);
% -or-
% [...] = mtspf_ga('Param1',Value1,'Param2',Value2, ...);
%
% Example:
% % Let the function create an example problem to solve
% mtspf_ga;
%
% Example:
% % Request the output structure from the solver
% resultStruct = mtspf_ga;
127
%
% Example:
% % Pass a random set of user-defined XY points to the solver
% userConfig = struct('xy',10*rand(35,2));
% resultStruct = mtspf_ga(userConfig);
%
% Example:
% % Pass a more interesting set of XY points to the solver
% n = 50;
% phi = (sqrt(5)-1)/2;
% theta = 2*pi*phi*(0:n-1);
% rho = (1:n).^phi;
% [x,y] = pol2cart(theta(:),rho(:));
% xy = 10*([x y]-min([x;y]))/(max([x;y])-min([x;y]));
% userConfig = struct('xy',xy);
% resultStruct = mtspf_ga(userConfig);
%
% Example:
% % Pass a random set of 3D (XYZ) points to the solver
% xyz = 10*rand(35,3);
% userConfig = struct('xy',xyz);
% resultStruct = mtspf_ga(userConfig);
%
% Example:
% % Change the defaults for GA population size and number of iterations
% userConfig = struct('popSize',200,'numIter',1e4);
% resultStruct = mtspf_ga(userConfig);
%
% Example:
% % Turn off the plots but show a waitbar
% userConfig = struct('showProg',false,'showResult',false,'showWaitbar',true);
% resultStruct = mtspf_ga(userConfig);
%
% See also: mtsp_ga, mtspo_ga, mtspof_ga, mtspofs_ga, mtspv_ga, distmat
%
% Author: Joseph Kirk
% Email: [email protected]
128
% Release: 2.0
% Release Date: 05/01/2014
function varargout = mtspf_ga(varargin)
% Initialize default configuration
defaultConfig.xy = xlsread('METRIX_All.xlsx','Vado_1');
defaultConfig.dmat = xlsread('METRIX_All.xlsx','Vado_2');
defaultConfig.nSalesmen = 2;
defaultConfig.minTour = 5;
defaultConfig.popSize = 80;
defaultConfig.numIter = 5e3;
defaultConfig.showProg = true;
defaultConfig.showResult = true;
defaultConfig.showWaitbar = false;
% Interpret user configuration inputs
if ~nargin
userConfig = struct();
elseif isstruct(varargin{1})
userConfig = varargin{1};
else
try
userConfig = struct(varargin{:});
catch
error('Expected inputs are either a structure or parameter/value pairs');
end
end
% Override default configuration with user inputs
configStruct = get_config(defaultConfig,userConfig);
% Extract configuration
xy = configStruct.xy;
dmat = configStruct.dmat;
nSalesmen = configStruct.nSalesmen;
minTour = configStruct.minTour;
popSize = configStruct.popSize;
129
numIter = configStruct.numIter;
showProg = configStruct.showProg;
showResult = configStruct.showResult;
showWaitbar = configStruct.showWaitbar;
if isempty(dmat)
nPoints = size(xy,1);
a = meshgrid(1:nPoints);
dmat = reshape(sqrt(sum((xy(a,:)-xy(a',:)).^2,2)),nPoints,nPoints);
end
% Verify Inputs
[N,dims] = size(xy);
[nr,nc] = size(dmat);
if N ~= nr || N ~= nc
error('Invalid XY or DMAT inputs!')
end
n = N - 1; % Separate Start/End City
% Sanity Checks
nSalesmen = max(1,min(n,round(real(nSalesmen(1)))));
minTour = max(1,min(floor(n/nSalesmen),round(real(minTour(1)))));
popSize = max(8,8*ceil(popSize(1)/8));
numIter = max(1,round(real(numIter(1))));
showProg = logical(showProg(1));
showResult = logical(showResult(1));
showWaitbar = logical(showWaitbar(1));
% Initializations for Route Break Point Selection
nBreaks = nSalesmen-1;
dof = n - minTour*nSalesmen; % degrees of freedom
addto = ones(1,dof+1);
for k = 2:nBreaks
addto = cumsum(addto);
end
cumProb = cumsum(addto)/sum(addto);
% Initialize the Populations
130
popRoute = zeros(popSize,n); % population of routes
popBreak = zeros(popSize,nBreaks); % population of breaks
popRoute(1,:) = (1:n) + 1;
popBreak(1,:) = rand_breaks();
for k = 2:popSize
popRoute(k,:) = randperm(n) + 1;
popBreak(k,:) = rand_breaks();
end
% Select the Colors for the Plotted Routes
pclr = ~get(0,'DefaultAxesColor');
clr = [1 0 0; 0 0 1; 0.67 0 1; 0 1 0; 1 0.5 0];
if nSalesmen > 5
clr = hsv(nSalesmen);
end
% Run the GA
globalMin = Inf;
totalDist = zeros(1,popSize);
distHistory = zeros(1,numIter);
tmpPopRoute = zeros(8,n);
tmpPopBreak = zeros(8,nBreaks);
newPopRoute = zeros(popSize,n);
newPopBreak = zeros(popSize,nBreaks);
if showProg
figure('Name','MTSPF_GA | Current Best Solution','Numbertitle','off');
hAx = gca;
end
if showWaitbar
hWait = waitbar(0,'Searching for near-optimal solution ...');
end
for iter = 1:numIter
% Evaluate Members of the Population
for p = 1:popSize
d = 0;
pRoute = popRoute(p,:);
pBreak = popBreak(p,:);
131
rng = [[1 pBreak+1];[pBreak n]]';
for s = 1:nSalesmen
d = d + dmat(1,pRoute(rng(s,1))); % Add Start Distance
for k = rng(s,1):rng(s,2)-1
d = d + dmat(pRoute(k),pRoute(k+1));
end
d = d + dmat(pRoute(rng(s,2)),1); % Add End Distance
end
totalDist(p) = d;
end
% Find the Best Route in the Population
[minDist,index] = min(totalDist);
distHistory(iter) = minDist;
if minDist < globalMin
globalMin = minDist;
optRoute = popRoute(index,:);
optBreak = popBreak(index,:);
rng = [[1 optBreak+1];[optBreak n]]';
if showProg
% Plot the Best Route
for s = 1:nSalesmen
rte = [1 optRoute(rng(s,1):rng(s,2)) 1];
if dims > 2, plot3(hAx,xy(rte,1),xy(rte,2),xy(rte,3),'.-','Color',clr(s,:));
else plot(hAx,xy(rte,1),xy(rte,2),'.-','Color',clr(s,:)); end
hold(hAx,'on');
end
if dims > 2, plot3(hAx,xy(1,1),xy(1,2),xy(1,3),'o','Color',pclr);
else plot(hAx,xy(1,1),xy(1,2),'o','Color',pclr); end
title(hAx,sprintf('Total Distance = %1.4f, Iteration = %d',minDist,iter));
hold(hAx,'off');
drawnow;
end
end
% Genetic Algorithm Operators
randomOrder = randperm(popSize);
132
for p = 8:8:popSize
rtes = popRoute(randomOrder(p-7:p),:);
brks = popBreak(randomOrder(p-7:p),:);
dists = totalDist(randomOrder(p-7:p));
[ignore,idx] = min(dists); %#ok
bestOf8Route = rtes(idx,:);
bestOf8Break = brks(idx,:);
routeInsertionPoints = sort(ceil(n*rand(1,2)));
I = routeInsertionPoints(1);
J = routeInsertionPoints(2);
for k = 1:8 % Generate New Solutions
tmpPopRoute(k,:) = bestOf8Route;
tmpPopBreak(k,:) = bestOf8Break;
switch k
case 2 % Flip
tmpPopRoute(k,I:J) = tmpPopRoute(k,J:-1:I);
case 3 % Swap
tmpPopRoute(k,[I J]) = tmpPopRoute(k,[J I]);
case 4 % Slide
tmpPopRoute(k,I:J) = tmpPopRoute(k,[I+1:J I]);
case 5 % Modify Breaks
tmpPopBreak(k,:) = rand_breaks();
case 6 % Flip, Modify Breaks
tmpPopRoute(k,I:J) = tmpPopRoute(k,J:-1:I);
tmpPopBreak(k,:) = rand_breaks();
case 7 % Swap, Modify Breaks
tmpPopRoute(k,[I J]) = tmpPopRoute(k,[J I]);
tmpPopBreak(k,:) = rand_breaks();
case 8 % Slide, Modify Breaks
tmpPopRoute(k,I:J) = tmpPopRoute(k,[I+1:J I]);
tmpPopBreak(k,:) = rand_breaks();
otherwise % Do Nothing
end
end
newPopRoute(p-7:p,:) = tmpPopRoute;
newPopBreak(p-7:p,:) = tmpPopBreak;
end
133
popRoute = newPopRoute;
popBreak = newPopBreak;
% Update the waitbar
if showWaitbar && ~mod(iter,ceil(numIter/325))
waitbar(iter/numIter,hWait);
end
end
if showWaitbar
close(hWait);
end
if showResult
% Plots
figure('Name','MTSPF_GA | Results','Numbertitle','off');
subplot(2,2,1);
if dims > 2, plot3(xy(:,1),xy(:,2),xy(:,3),'.','Color',pclr);
else plot(xy(:,1),xy(:,2),'.','Color',pclr); end
title('City Locations');
subplot(2,2,2);
imagesc(dmat([1 optRoute],[1 optRoute]));
title('Distance Matrix');
subplot(2,2,3);
rng = [[1 optBreak+1];[optBreak n]]';
for s = 1:nSalesmen
rte = [1 optRoute(rng(s,1):rng(s,2)) 1];
if dims > 2, plot3(xy(rte,1),xy(rte,2),xy(rte,3),'.-','Color',clr(s,:));
else plot(xy(rte,1),xy(rte,2),'.-','Color',clr(s,:)); end
title(sprintf('Total Distance = %1.4f',minDist));
hold on;
end
if dims > 2, plot3(xy(1,1),xy(1,2),xy(1,3),'o','Color',pclr);
else plot(xy(1,1),xy(1,2),'o','Color',pclr); end
subplot(2,2,4);
plot(distHistory,'b','LineWidth',2);
title('Best Solution History');
134
set(gca,'XLim',[0 numIter+1],'YLim',[0 1.1*max([1 distHistory])]);
end
% Return Output
if nargout
resultStruct = struct( ...
'xy', xy, ...
'dmat', dmat, ...
'nSalesmen', nSalesmen, ...
'minTour', minTour, ...
'popSize', popSize, ...
'numIter', numIter, ...
'showProg', showProg, ...
'showResult', showResult, ...
'showWaitbar', showWaitbar, ...
'optRoute', optRoute, ...
'optBreak', optBreak, ...
'minDist', minDist);
varargout = {resultStruct};
end
% Generate Random Set of Break Points
function breaks = rand_breaks()
if minTour == 1 % No Constraints on Breaks
tmpBreaks = randperm(n-1);
breaks = sort(tmpBreaks(1:nBreaks));
else % Force Breaks to be at Least the Minimum Tour Length
nAdjust = find(rand < cumProb,1)-1;
spaces = ceil(nBreaks*rand(1,nAdjust));
adjust = zeros(1,nBreaks);
for kk = 1:nBreaks
adjust(kk) = sum(spaces == kk);
end
breaks = minTour*(1:nBreaks) + cumsum(adjust);
end
end
135
end
% Subfunction to override the default configuration with user inputs
function config = get_config(defaultConfig,userConfig)
% Initialize the configuration structure as the default
config = defaultConfig;
% Extract the field names of the default configuration structure
defaultFields = fieldnames(defaultConfig);
% Extract the field names of the user configuration structure
userFields = fieldnames(userConfig);
nUserFields = length(userFields);
% Override any default configuration fields with user values
for i = 1:nUserFields
userField = userFields{i};
isField = strcmpi(defaultFields,userField);
if nnz(isField) == 1
thisField = defaultFields{isField};
config.(thisField) = userConfig.(userField);
end
end
end
Published with MATLAB® R2015a
136
APPENDIX – 7
Milk-Run Routes with Weight Distribution
function varargout = untitled(varargin)
% UNTITLED MATLAB code for untitled.fig
% UNTITLED, by itself, creates a new UNTITLED or raises the existing
% singleton*.
%
% H = UNTITLED returns the handle to a new UNTITLED or the handle to
% the existing singleton*.
%
% UNTITLED('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in UNTITLED.M with the given input arguments.
%
% UNTITLED('Property','Value',...) creates a new UNTITLED or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before untitled_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to untitled_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help untitled
% Last Modified by GUIDE v2.5 22-Sep-2016 11:00:51
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @untitled_OpeningFcn, ...
137
'gui_OutputFcn', @untitled_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before untitled is made visible.
function untitled_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% varargin command line arguments to untitled (see VARARGIN)
% Choose default command line output for untitled
handles.output = hObject;
%create an axes that spans the whole gui
ah = axes('unit', 'normalized', 'position', [0 0 1 1]);
% import the background image and show it on the axes
bg = imread('images.jpg'); imagesc(bg);
% prevent plotting over the background and turn the axis off
set(ah,'handlevisibility','off','visible','off')
% making sure the background is behind all the other uicontrols
uistack(ah, 'bottom');
138
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes untitled wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = untitled_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
% --- Executes on button press in SIMU.
function SIMU_Callback(hObject, eventdata, handles)
% hObject handle to SIMU (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
Data006=xlsread('E01.xlsx','All')
Data007=xlsread('E01.xlsx','All_1')
axes(handles.MAP)
% plot route data
plot(Data006(:, 1), Data006(:, 2),'color',rgb('Crimson'), 'LineWidth', 2);
hold on
% plot route data
plot(Data007(:, 1), Data007(:, 2),'color',rgb('Crimson'), 'LineWidth', 2);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
139
%Plotting coloures .................................................%
Red='r'
Magenta='m'
Cyan='c'
Green='g'
C01=rgb('Green')
C02=rgb('OrangeRed')
C03=rgb('Salmon')
C04=rgb('DarkRed')
%......................... ROUTE SHEET ...............................%
ahm01=xlsread('ROUTE SHEET.xlsx','Ahm_1')
ahm02=xlsread('ROUTE SHEET.xlsx','Ahm_2')
ahm03=xlsread('ROUTE SHEET.xlsx','Ahm_3')
meh01=xlsread('ROUTE SHEET.xlsx','Meh_1')
meh02=xlsread('ROUTE SHEET.xlsx','Meh_2')
raj01=xlsread('ROUTE SHEET.xlsx','Raj_1')
raj02=xlsread('ROUTE SHEET.xlsx','Raj_2')
raj03=xlsread('ROUTE SHEET.xlsx','Raj_3')
raj04=xlsread('ROUTE SHEET.xlsx','Raj_4')
sur01=xlsread('ROUTE SHEET.xlsx','Sur_1')
sur02=xlsread('ROUTE SHEET.xlsx','Sur_2')
vad01=xlsread('ROUTE SHEET.xlsx','Vad_1')
vad02=xlsread('ROUTE SHEET.xlsx','Vad_2')
% ......................... ACTUAL ROUTING DATA............... %
Ahm011=xlsread('Routing_data.xlsx','Ahm_1')
Ahm021=xlsread('Routing_data.xlsx','Ahm_2')
Ahm031=xlsread('Routing_data.xlsx','Ahm_3')
Meh011=xlsread('Routing_data.xlsx','Meh_1')
Meh021=xlsread('Routing_data.xlsx','Meh_2')
Raj011=xlsread('Routing_data.xlsx','Raj_1')
Raj021=xlsread('Routing_data.xlsx','Raj_2')
Raj031=xlsread('Routing_data.xlsx','Raj_3')
Raj041=xlsread('Routing_data.xlsx','Raj_4')
Sur011=xlsread('Routing_data.xlsx','Sur_1')
Sur021=xlsread('Routing_data.xlsx','Sur_2')
Vad011=xlsread('Routing_data.xlsx','Vad_1')
140
Vad021=xlsread('Routing_data.xlsx','Vad_2')
% ................... CODING........................................%
Xpres={'Ahm011','Ahm021','Ahm031','Meh011','Meh021','Raj011','Raj021','Raj031','Raj041','Sur011','Sur021','V
ad011','Vad021'}
for k=1:length(Xpres)
hold on
O=Xpres(k)
O1=char(O)
w01=O1(1:3)
w02=O1(5)
X=strcat(w01,'_',w02)
Universal_data=xlsread('Routing_data.xlsx',X)
plot(Universal_data(:, 1), Universal_data(:, 2),'color',rgb('Crimson'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
end
hold on
for i=1:length(Xpres)
hold on
O=Xpres(i)
O1=char(O)
w01=O1(1:3)
w02=O1(5)
X=strcat(w01,'_',w02)
Universal_data=xlsread('Routing_data.xlsx',X)
[RS,RC]=xlsread('ROUTE SHEET.xlsx',X)
[r,c]=size(RS)
for j=1:(r-1)
Weight=RS(j,2)
X1=num2str(RS(j,2))
Y=num2str(RS(j+1,2))
Range=strcat('A',X1,':','B',Y)
Origin_st_data=xlsread('Routing_data.xlsx',X,Range)
141
START_CITY=RC(j,1)
DESTI_CITY=RC(j+1,1)
if Weight<175
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('LightGreen'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
elseif Weight>175 & Weight<350
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('Yellow'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
elseif Weight>350 & Weight<700
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('Orange'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
elseif Weight>700
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('Crimson'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
142
% Google map
plot_google_map('maptype', 'roadmap');
end
set(handles.ST_CT,'string',START_CITY)
set(handles.DT_CT,'string',DESTI_CITY)
set(handles.WT,'string',Weight)
end
end
hold off
Published with MATLAB® R2015a
143
APPENDIX – 8
Scheduling of Individual Routes
function varargout = untitled1(varargin)
% UNTITLED1 MATLAB code for untitled1.fig
% UNTITLED1, by itself, creates a new UNTITLED1 or raises the existing
% singleton*.
%
% H = UNTITLED1 returns the handle to a new UNTITLED1 or the handle to
% the existing singleton*.
%
% UNTITLED1('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in UNTITLED1.M with the given input arguments.
%
% UNTITLED1('Property','Value',...) creates a new UNTITLED1 or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before untitled1_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to untitled1_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help untitled1
% Last Modified by GUIDE v2.5 22-Sep-2016 12:50:15
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @untitled1_OpeningFcn, ...
144
'gui_OutputFcn', @untitled1_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before untitled1 is made visible.
function untitled1_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% varargin command line arguments to untitled1 (see VARARGIN)
% Choose default command line output for untitled1
handles.output = hObject;
%create an axes that spans the whole gui
ah = axes('unit', 'normalized', 'position', [0 0 1 1]);
% import the background image and show it on the axes
bg = imread('images.jpg'); imagesc(bg);
% prevent plotting over the background and turn the axis off
set(ah,'handlevisibility','off','visible','off')
% making sure the background is behind all the other uicontrols
uistack(ah, 'bottom');
145
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes untitled1 wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = untitled1_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
% --- Executes on selection change in popupmenu1.
function popupmenu1_Callback(hObject, eventdata, handles)
% hObject handle to popupmenu1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
cla(handles.axes1,'reset');
[ALL,ALL1]=xlsread('C_K_T.xlsx')
%switch case has been used for the Each routes with different Route kilometer, route cost and route time
switch get(handles.popupmenu1,'Value')
case 1
X=xlsread('Routing_data.xlsx','Ahm_1')
[TA,TA1]=xlsread('Station_sheet.xlsx','Ahm_1')
KMS=ALL(1,1)
CST=ALL(1,3)
TYM=ALL1(2,3)
case 2
X=xlsread('Routing_data.xlsx','Ahm_2')
[TA,TA1]=xlsread('Station_sheet.xlsx','Ahm_2')
146
KMS=ALL(2,1)
CST=ALL(2,3)
TYM=ALL1(3,3)
case 3
X=xlsread('Routing_data.xlsx','Ahm_3')
[TA,TA1]=xlsread('Station_sheet.xlsx','Ahm_3')
KMS=ALL(3,1)
CST=ALL(3,3)
TYM=ALL1(4,3)
case 4
X=xlsread('Routing_data.xlsx','Meh_1')
[TA,TA1]=xlsread('Station_sheet.xlsx','Meh_1')
KMS=ALL(4,1)
CST=ALL(4,3)
TYM=ALL1(5,3)
case 5
X=xlsread('Routing_data.xlsx','Meh_2')
[TA,TA1]=xlsread('Station_sheet.xlsx','Meh_2')
KMS=ALL(5,1)
CST=ALL(5,3)
TYM=ALL1(6,3)
case 6
X=xlsread('Routing_data.xlsx','Raj_1')
[TA,TA1]=xlsread('Station_sheet.xlsx','Raj_1')
KMS=ALL(6,1)
CST=ALL(6,3)
TYM=ALL1(7,3)
case 7
X=xlsread('Routing_data.xlsx','Raj_2')
[TA,TA1]=xlsread('Station_sheet.xlsx','Raj_2')
KMS=ALL(7,1)
CST=ALL(7,3)
TYM=ALL1(8,3)
case 8
147
X=xlsread('Routing_data.xlsx','Raj_3')
[TA,TA1]=xlsread('Station_sheet.xlsx','Raj_3')
KMS=ALL(8,1)
CST=ALL(8,3)
TYM=ALL1(9,3)
case 9
X=xlsread('Routing_data.xlsx','Raj_4')
[TA,TA1]=xlsread('Station_sheet.xlsx','Raj_4')
KMS=ALL(9,1)
CST=ALL(9,3)
TYM=ALL1(10,3)
case 10
X=xlsread('Routing_data.xlsx','Vad_1')
[TA,TA1]=xlsread('Station_sheet.xlsx','Vad_1')
KMS=ALL(10,1)
CST=ALL(10,3)
TYM=ALL1(11,3)
case 11
X=xlsread('Routing_data.xlsx','Vad_2')
[TA,TA1]=xlsread('Station_sheet.xlsx','Vad_2')
KMS=ALL(11,1)
CST=ALL(11,3)
TYM=ALL1(12,3)
case 12
X=xlsread('Routing_data.xlsx','Sur_1')
[TA,TA1]=xlsread('Station_sheet.xlsx','Sur_1')
KMS=ALL(12,1)
CST=ALL(12,3)
TYM=ALL1(13,3)
case 13
X=xlsread('Routing_data.xlsx','Sur_2')
[TA,TA1]=xlsread('Station_sheet.xlsx','Sur_2')
KMS=ALL(13,1)
CST=ALL(13,3)
TYM=ALL1(14,3)
end
% axes handles for the ploting the figure in a GUI
148
axes(handles.axes1)
plot(X(:, 1), X(:, 2),'r','Marker','.', 'LineWidth', 3.5);
line(X(1, 1), X(1, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
line(X(end, 1), X(end, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
xlim([69.50,74.30]);
% Google map%
plot_google_map('maptype', 'roadmap');
set(handles.TABLE, 'Data',TA1);
set(handles.TIME1,'String',TYM)
set(handles.COST1,'String',CST)
set(handles.KMS1,'String',KMS)
% Hints: contents = cellstr(get(hObject,'String')) returns popupmenu1 contents as cell array
% contents{get(hObject,'Value')} returns selected item from popupmenu1
% --- Executes during object creation, after setting all properties.
function popupmenu1_CreateFcn(hObject, eventdata, handles)
% hObject handle to popupmenu1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: popupmenu controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
Published with MATLAB® R2015a
149
APPENDIX – 9
Graphical Representation of Milk-Run Routing
System
function varargout = XPERIMENT(varargin)
% XPERIMENT MATLAB code for XPERIMENT.fig
% XPERIMENT, by itself, creates a new XPERIMENT or raises the existing
% singleton*.
%
% H = XPERIMENT returns the handle to a new XPERIMENT or the handle to
% the existing singleton*.
%
% XPERIMENT('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in XPERIMENT.M with the given input arguments.
%
% XPERIMENT('Property','Value',...) creates a new XPERIMENT or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before XPERIMENT_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to XPERIMENT_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help XPERIMENT
% Last Modified by GUIDE v2.5 23-Sep-2016 15:19:33
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
150
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @XPERIMENT_OpeningFcn, ...
'gui_OutputFcn', @XPERIMENT_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before XPERIMENT is made visible.
function XPERIMENT_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% varargin command line arguments to XPERIMENT (see VARARGIN)
% Choose default command line output for XPERIMENT
handles.output = hObject;
%create an axes that spans the whole gui
ah = axes('unit', 'normalized', 'position', [0 0 1 1]);
% import the background image and show it on the axes
bg = imread('images.jpg'); imagesc(bg);
% prevent plotting over the background and turn the axis off
set(ah,'handlevisibility','off','visible','off')
% making sure the background is behind all the other uicontrols
151
uistack(ah, 'bottom');
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes XPERIMENT wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = XPERIMENT_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
function ST_GUI_Callback(hObject, eventdata, handles)
% hObject handle to ST_GUI (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
input=get(hObject,'string')
% Hints: get(hObject,'String') returns contents of ST_GUI as text
% str2double(get(hObject,'String')) returns contents of ST_GUI as a double
% --- Executes during object creation, after setting all properties.
function ST_GUI_CreateFcn(hObject, eventdata, handles)
% hObject handle to ST_GUI (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
152
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function DT_GUI_Callback(hObject, eventdata, handles)
% hObject handle to DT_GUI (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
input=get(hObject,'string')
% Hints: get(hObject,'String') returns contents of DT_GUI as text
% str2double(get(hObject,'String')) returns contents of DT_GUI as a double
% --- Executes during object creation, after setting all properties.
function DT_GUI_CreateFcn(hObject, eventdata, handles)
% hObject handle to DT_GUI (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function NOV_GUI_Callback(hObject, eventdata, handles)
% hObject handle to NOV_GUI (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
input=str2num(get(hObject,'string'))
% Hints: get(hObject,'String') returns contents of NOV_GUI as text
153
% str2double(get(hObject,'String')) returns contents of NOV_GUI as a double
% --- Executes during object creation, after setting all properties.
function NOV_GUI_CreateFcn(hObject, eventdata, handles)
% hObject handle to NOV_GUI (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
% --- Executes on button press in CAL.
function CAL_Callback(hObject, eventdata, handles)
% hObject handle to CAL (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
cla(handles.axes1,'reset');
st=get(handles.ST_GUI,'string');
dt=get(handles.DT_GUI,'string');
Vehicle=[get(handles.NOV_GUI,'string')-48];
major={'Ahmedabad','Mehsana','Vadodara','Surat','Rajkot'}
major01=xlsread('city_name.xlsx','All')
major02=xlsread('city_name.xlsx','All_1')
major03=xlsread('city_name.xlsx','All_2')
[Major_Name,Major_kms]=xlsread('Major kms.xlsx')
[ans,ans01,ans02]=city_name_st(st)
st_cl=ans01
154
st_rw=str2num(ans02)
st_name=ans
[ans,ans01,ans02]=city_name_dt(dt)
dt_cl=ans01
dt_rw=str2num(ans02)
dt_name=ans
% Defigning Starting route Data ...................................................%
st01=st_name(1:3)
sheetnoS=st_name(5)
[x,y]=xlsread('city_name.xlsx',st01)
st_row=y(:,st_rw)
st_route=st_row(st_cl:length(st_row))
% Defigning the Destination route data..................................................%
dt01=dt_name(1:3)
sheetnoD=dt_name(5)
[x1,y1]=xlsread('city_name.xlsx',dt01)
dt_row=y1(:,dt_rw)
dt_route=dt_row(1:dt_cl)
if strcmpi(dt01,'ahm')==1
MAJOR_dt=major(1)
elseif strcmpi(dt01,'meh')==1
MAJOR_dt=major(2)
elseif strcmpi(dt01,'vad')==1
MAJOR_dt=major(3)
elseif strcmpi(dt01,'sur')==1
MAJOR_dt=major(4)
elseif strcmpi(dt01,'raj')==1
MAJOR_dt=major(5)
end
% ............MAJOR DESTINATION MATCHING..................................................%
if strcmpi(st01,'ahm')==1
MAJOR_st=major(1)
155
elseif strcmpi(st01,'meh')==1
MAJOR_st=major(2)
elseif strcmpi(st01,'vad')==1
MAJOR_st=major(3)
elseif strcmpi(st01,'sur')==1
MAJOR_st=major(4)
elseif strcmpi(st01,'raj')==1
MAJOR_st=major(5)
end
% .... MAJOR CITY ROUTING DATA EXCEL SHEET.........................................................%
Mejor_city=strcat(st01,'_',dt01)
MJR_XL=xlsread('Regional.xlsx',Mejor_city)
route_sheet=xlsread('ROUTE SHEET.xlsx',st_name)
st_num_S=num2str(route_sheet(st_cl,2))
L0=length(route_sheet)
st_num_E=num2str(route_sheet(L0,2))
RANGE_S=num2str(strcat('A',st_num_S,':','B',st_num_E))
ST_XL=xlsread('Routing_data.xlsx',st_name,RANGE_S)
% Major cities for the Destination cities..............................%
route_sheet=xlsread('ROUTE SHEET.xlsx',dt_name)
dt_num_D1=num2str(route_sheet(dt_cl,2))
RANGE_D=num2str(strcat('A1',':','B',dt_num_D1))
DT_XL=xlsread('Routing_data.xlsx',dt_name,RANGE_D)
Origin_st_data=[ST_XL;MJR_XL;DT_XL]
% Axes handles for the ploting the figure in the GUI .................................%
axes(handles.axes1)
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'r','Marker','.', 'LineWidth', 3.5);
line(Origin_st_data(1, 1), Origin_st_data(1, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
line(Origin_st_data(end, 1), Origin_st_data(end, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
156
xlim([69.50,74.30]);
% Ploting the data in the Google map %
plot_google_map('maptype', 'roadmap');
guidata(hObject,handles)
%comparing the major starting cities with the available names %
[Major_Kms,Major_Name]=xlsread('Major kms.xlsx')
if strcmpi(MAJOR_st,Major_Name(1))==1
Q=1
elseif strcmpi(MAJOR_st,Major_Name(2))==1
Q=2
elseif strcmpi(MAJOR_st,Major_Name(3))==1
Q=3
elseif strcmpi(MAJOR_st,Major_Name(4))==1
Q=4
elseif strcmpi(MAJOR_st,Major_Name(5))==1
Q=5
end
if strcmpi(MAJOR_dt,Major_Name(1))==1
O=1
elseif strcmpi(MAJOR_dt,Major_Name(2))==1
O=2
elseif strcmpi(MAJOR_dt,Major_Name(3))==1
O=3
elseif strcmpi(MAJOR_dt,Major_Name(4))==1
O=4
elseif strcmpi(MAJOR_dt,Major_Name(5))==1
O=5
end
M_KMS=Major_Kms(Q,O)
St_range_cost=xlsread('All Routes kms.xlsx',st_name)
st_KMS=St_range_cost(st_cl,3)
Dt_range_cost=xlsread('All Routes kms.xlsx',dt_name)
dt_KMS=Dt_range_cost(dt_cl,2)
157
% Defining the total Kilo meters
Total_KMS=st_KMS+dt_KMS+M_KMS
% Defining the Vehical cost
Vehicle_cost=Vehicle*330
% Calculating the Travelling cost
Travelling_cost=Total_KMS*8
T_K=num2str(Total_KMS)
SUB_TIME=Total_KMS/50
TOTAL_HOUR=fix(SUB_TIME)
TOTAL_HOUR1=num2str(TOTAL_HOUR)
TOTAL_MIN=num2str(round((SUB_TIME*60)-(TOTAL_HOUR*60),0))
Total_cost=Vehicle_cost+Travelling_cost
Veh=num2str(Vehicle)
T_C=num2str(Total_cost)
%seting the handles in the GUI for representation
set(handles.ANSR_GUI,'string',Total_cost)
set(handles.TIME1_GUI,'string',TOTAL_HOUR1)
set(handles.TIME2_GUI,'string',TOTAL_MIN)
set(handles.KMS_GUI,'string',Total_KMS)
Published with MATLAB® R2015a
158
APPENDIX – 10
Construction of Express Routing
% Loading of the express route
Data006=xlsread('E01.xlsx','All')
Data007=xlsread('E01.xlsx','All_1')
% plot route data
plot(Data006(:, 1), Data006(:, 2),'color',rgb('Crimson'), 'LineWidth', 2);
hold on
% plot route data
plot(Data007(:, 1), Data007(:, 2),'color',rgb('Crimson'), 'LineWidth', 2);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Ploting of the Google map on figure
plot_google_map('maptype', 'roadmap');
%Plotting coloures .................................................%
Red='r'
Magenta='m'
Cyan='c'
Green='g'
C01=rgb('Green')
C02=rgb('OrangeRed')
C03=rgb('Salmon')
C04=rgb('DarkRed')
%......................... ROUTE SHEET ...............................%
ahm01=xlsread('ROUTE SHEET.xlsx','Ahm_1')
ahm02=xlsread('ROUTE SHEET.xlsx','Ahm_2')
ahm03=xlsread('ROUTE SHEET.xlsx','Ahm_3')
159
meh01=xlsread('ROUTE SHEET.xlsx','Meh_1')
meh02=xlsread('ROUTE SHEET.xlsx','Meh_2')
raj01=xlsread('ROUTE SHEET.xlsx','Raj_1')
raj02=xlsread('ROUTE SHEET.xlsx','Raj_2')
raj03=xlsread('ROUTE SHEET.xlsx','Raj_3')
raj04=xlsread('ROUTE SHEET.xlsx','Raj_4')
sur01=xlsread('ROUTE SHEET.xlsx','Sur_1')
sur02=xlsread('ROUTE SHEET.xlsx','Sur_2')
vad01=xlsread('ROUTE SHEET.xlsx','Vad_1')
vad02=xlsread('ROUTE SHEET.xlsx','Vad_2')
% ......................... ACTUAL ROUTING DATA............... %
Ahm011=xlsread('Routing_data.xlsx','Ahm_1')
Ahm021=xlsread('Routing_data.xlsx','Ahm_2')
Ahm031=xlsread('Routing_data.xlsx','Ahm_3')
Meh011=xlsread('Routing_data.xlsx','Meh_1')
Meh021=xlsread('Routing_data.xlsx','Meh_2')
Raj011=xlsread('Routing_data.xlsx','Raj_1')
Raj021=xlsread('Routing_data.xlsx','Raj_2')
Raj031=xlsread('Routing_data.xlsx','Raj_3')
Raj041=xlsread('Routing_data.xlsx','Raj_4')
Sur011=xlsread('Routing_data.xlsx','Sur_1')
Sur021=xlsread('Routing_data.xlsx','Sur_2')
Vad011=xlsread('Routing_data.xlsx','Vad_1')
Vad021=xlsread('Routing_data.xlsx','Vad_2')
% ................... Actual coding for the configeration of the route........................................%
Xpres={'Ahm011','Ahm021','Ahm031','Meh011','Meh021','Raj011','Raj021','Raj031','Raj041','Sur011','Sur021','V
ad011','Vad021'}
for k=1:length(Xpres)
hold on
O=Xpres(k)
O1=char(O)
w01=O1(1:3)
w02=O1(5)
X=strcat(w01,'_',w02)
Universal_data=xlsread('Routing_data.xlsx',X)
160
plot(Universal_data(:, 1), Universal_data(:, 2),'color',rgb('Crimson'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
end
hold on
for i=1:length(Xpres)
hold on
O=Xpres(i)
O1=char(O)
w01=O1(1:3)
w02=O1(5)
X=strcat(w01,'_',w02)
Universal_data=xlsread('Routing_data.xlsx',X)
RS=xlsread('ROUTE SHEET.xlsx',X)
[r,c]=size(RS)
for j=1:(r-1)
Weight=RS(j,3)
X1=num2str(RS(j,2))
Y=num2str(RS(j+1,2))
Range=strcat('A',X1,':','B',Y)
Origin_st_data=xlsread('Routing_data.xlsx',X,Range)
if Weight<175
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('LightGreen'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
elseif Weight>175 & Weight<350
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('Yellow'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
161
% Google map
plot_google_map('maptype', 'roadmap');
elseif Weight>350 & Weight<700
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('Orange'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
elseif Weight>700
plot(Origin_st_data(:, 1), Origin_st_data(:, 2),'color',rgb('Crimson'),'Marker','.', 'LineWidth', 3.5);
xlim([69.50,74.30]);
ylim([20.4,24.6]);
% Google map
plot_google_map('maptype', 'roadmap');
end
end
end
hold off
Published with MATLAB® R2015a
162
APPENDIX – 11
Development of Dynamic Milk-Run Material
Supply System
function varargout = Dynamic(varargin)
% DYNAMIC MATLAB code for Dynamic.fig
% DYNAMIC, by itself, creates a new DYNAMIC or raises the existing
% singleton*.
%
% H = DYNAMIC returns the handle to a new DYNAMIC or the handle to
% the existing singleton*.
%
% DYNAMIC('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in DYNAMIC.M with the given input arguments.
%
% DYNAMIC('Property','Value',...) creates a new DYNAMIC or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before Dynamic_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to Dynamic_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help Dynamic
% Last Modified by GUIDE v2.5 26-Oct-2016 21:03:59
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @Dynamic_OpeningFcn, ...
'gui_OutputFcn', @Dynamic_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
163
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before Dynamic is made visible.
function Dynamic_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% varargin command line arguments to Dynamic (see VARARGIN)
% Choose default command line output for Dynamic
handles.output = hObject;
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes Dynamic wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = Dynamic_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
function goz_Callback(hObject, eventdata, handles)
% hObject handle to goz (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of goz as text
% str2double(get(hObject,'String')) returns contents of goz as a double
% --- Executes during object creation, after setting all properties.
function goz_CreateFcn(hObject, eventdata, handles)
% hObject handle to goz (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
164
end
function vis_Callback(hObject, eventdata, handles)
% hObject handle to vis (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of vis as text
% str2double(get(hObject,'String')) returns contents of vis as a double
% --- Executes during object creation, after setting all properties.
function vis_CreateFcn(hObject, eventdata, handles)
% hObject handle to vis (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function vad_Callback(hObject, eventdata, handles)
% hObject handle to vad (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of vad as text
% str2double(get(hObject,'String')) returns contents of vad as a double
% --- Executes during object creation, after setting all properties.
function vad_CreateFcn(hObject, eventdata, handles)
% hObject handle to vad (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function khe_Callback(hObject, eventdata, handles)
% hObject handle to khe (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
165
% Hints: get(hObject,'String') returns contents of khe as text
% str2double(get(hObject,'String')) returns contents of khe as a double
% --- Executes during object creation, after setting all properties.
function khe_CreateFcn(hObject, eventdata, handles)
% hObject handle to khe (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function sat_Callback(hObject, eventdata, handles)
% hObject handle to sat (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of sat as text
% str2double(get(hObject,'String')) returns contents of sat as a double
% --- Executes during object creation, after setting all properties.
function sat_CreateFcn(hObject, eventdata, handles)
% hObject handle to sat (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function pal_Callback(hObject, eventdata, handles)
% hObject handle to pal (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of pal as text
% str2double(get(hObject,'String')) returns contents of pal as a double
% --- Executes during object creation, after setting all properties.
function pal_CreateFcn(hObject, eventdata, handles)
% hObject handle to pal (see GCBO)
166
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function sid_Callback(hObject, eventdata, handles)
% hObject handle to sid (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of sid as text
% str2double(get(hObject,'String')) returns contents of sid as a double
% --- Executes during object creation, after setting all properties.
function sid_CreateFcn(hObject, eventdata, handles)
% hObject handle to sid (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
function unj_Callback(hObject, eventdata, handles)
% hObject handle to unj (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hints: get(hObject,'String') returns contents of unj as text
% str2double(get(hObject,'String')) returns contents of unj as a double
% --- Executes during object creation, after setting all properties.
function unj_CreateFcn(hObject, eventdata, handles)
% hObject handle to unj (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
167
% --- Executes on button press in plotter.
function plotter_Callback(hObject, eventdata, handles)
% hObject handle to plotter (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
goz=str2double(get(handles.goz,'String'))
vis=str2double(get(handles.vis,'String'))
vad=str2double(get(handles.vad,'String'))
khe=str2double(get(handles.khe,'String'))
sat=str2double(get(handles.sat,'String'))
pal=str2double(get(handles.pal,'String'))
sid=str2double(get(handles.sid,'String'))
unj=str2double(get(handles.unj,'String'))
A=[goz,vis,vad,khe,sat,sat,pal,sid,unj]
A1=A(1)+A(2)
A2=A1+A(3)
A3=A2+A(4)
A4=A3+A(5)
A5=A4+A(6)
A6=A5+A(7)
A7=A6+A(8)
A8=A7+A(9)
if goz<200
X=xlsread('Routing_data.xlsx','Meh_22')
T_K=212
T_T='6 hr 45 min'
T_C=2026
elseif sat<200
X=xlsread('Routing_data.xlsx','Meh_23')
T_K=202
T_T='6 hr 15 min'
T_C=1946
else
X=xlsread('Routing_data.xlsx','Meh_21')
T_K=241
T_T='7 hr 25 min'
T_C=2258
end
axes(handles.plot)
plot(X(:, 1), X(:, 2), 'g', 'LineWidth', 2);
line(X(1, 1), X(1, 2), 'Marker', 'o', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
line(X(end, 1), X(end, 2), 'Marker', 's', ...
'Color', 'b', 'MarkerFaceColor', 'b', 'MarkerSize', 10);
xlim([70.50,74.30]); axis equal off
set(handles.KMs,'String',T_K)
set(handles.TIME,'String',T_T)
168
set(handles.COST,'String',T_C)
% Google map
plot_google_map('maptype', 'roadmap');
guidata(hObject,handles)
% --- Executes on button press in radiobutton1.
function radiobutton1_Callback(hObject, eventdata, handles)
% hObject handle to radiobutton1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
% Hint: get(hObject,'Value') returns toggle state of radiobutton1
Published with MATLAB® R2015a