Speak to a Friendly Routing Expert Now:
Speak to a Friendly Routing Expert Now:
+1-888-552-9045
ВEGIN FREE 7-DAY TEST DRIVE
FREE TRIAL

What is the Traveling Salesman Problem (TSP)?

Business team looking around and trying to find a solution to the traveling salesman problem
Featured image credit: yuoak/iStockphoto.com

The traveling salesman problem is the problem of figuring out the shortest route for field service reps to take, given a list of specific destinations.

Let’s understand the problem with an example.

A salesman wants to visit a few locations to sell goods. He knows the names of the areas and the distances between each one.

What is the shortest route the salesman should follow so that he only visits each location once before returning to the starting point?

The TSP is an extension of the Hamiltonian Circuit Problem. It is an old problem in computer science that has implications in complexity theory and the P versus NP problem.

The vehicle routing problem and traveling purchaser problem are both generalizations of TSP.

The Background of the Traveling Salesman Problem

The traveling salesman problem (TSP) was formulated in 1930. But it is one of the most studied combinatorial optimization problems even today.

In 1972, Richard Karp proved that the Hamiltonian cycle problem was NP-complete, a class of combinatorial optimization problems.

This means the TSP was NP-hard. And the complexity of calculating the best route will increase factorially when more destinations are added to the problem.

For example, there may be three possible routes in four cities. But there could be 360 possible routes in six cities.

This is because scientists do not only compute the most efficient path— but the one that works.

This computation uses the brute-force approach to solve the problem by figuring out every possibility and then picking the best one. In other words, look for every unique path the salesman could take.

Even though computational difficulties increase with each city added to the itinerary, computer scientists have calculated the optimal solution to this problem for thousands of cities since the early 90s.

For instance, many towns and cities in a US State could be a part of the delivery area of a large logistics provider.

Figuring out the shortest route between all the stops the vehicle needs to make on a day-to-day basis would save a lot of time and money.

Why is the Traveling Salesman Problem Hard?

In theory, the TSP can be solved by checking every round-trip route to find the shortest one.

However, as the number of cities grows, the corresponding number of round-trips outstrips the capabilities of the fastest computers.

There can be more than 300,000 round-trip permutations and combinations with ten cities.

With 15 cities, possible routes might be more than 87 billion.

In the early days of computers, computer scientists hoped that someone would develop an improved algorithm for solving the problem in a reasonable amount of time.

However, while scientists have progressed with specific scenarios, no efficient traveling salesman problem solver was available.

A one-size-fits-all algorithm might not even be possible.

Applications of the Traveling Salesman Problem

The TSP still finds applications in all verticals. Efficient solutions found through the TSP are used in astronomy, computer science, and even vehicle routing.

Astronomers use the concepts of TSP to determine the movement of a telescope for the shortest distance between different stars in a constellation.

Other uses for TSP include internet planning, agriculture, microchip production, and computer-generated art.

Route4Me

Want To See For Yourself How Route4Me Can Boost Your Profits?

Whether you want to slash the time it takes you to plan routes for your drivers, increase the number of stops they can make, or keep your customers satisfied knowing that your drivers show up on time… Route4Me helps you achieve that!

Start Free 7 Day Trial

Challenges Faced by Traveling Salesmen

Almost every salesperson wakes up in the morning with the thought of making the best use of their day.

They have many confirmed appointments with their customers and many more last-minute ones.

Salespeople do not always have a confirmed schedule. So, they often have to backtrack and take longer routes to reach customer addresses. This results in missed appointments and lost opportunities.

The modern-day salesman faces the additional problems of traffic congestion, last-minute customer requests, and specific delivery window timings. Add to it the route woes faced by yesteryear’s salesperson.

If you thought the TSP from the mathematical puzzle was difficult, consider this:

Perhaps you need to plan for a team of sales representatives rather than just one salesperson?

Now you need to split up the visits and assign them to your team!

What if sales guys had different appointment slots, and your target was to keep their routes the shortest, fastest, and most effective?

Consider this: If you have a total of 100 customer addresses and there are eight salespeople in your team, there could be more than a million possible route combinations.

A basic algorithm that weighs every possible combination and selects the best one will take you days, if not months.

Now, that’s a real-world challenge, and here comes route optimization.

What is route optimization, you ask?

Route optimization is all about finding the fastest, shortest, and most fuel-efficient route for a set of stops.

ALSO READ: What is Route Optimization?

How to Solve the Traveling Salesman Problem with A Route Planner

As your team grows, route planning will inevitably become too complex to manage using pen and paper or standard tools like Google Maps or Waze.

Without some heavy-duty tools, you can not manually factor in things like roadblocks and weather conditions. As a result, you will end up spending a lot of time planning routes.

Unforeseen situations such as traffic congestion make it challenging to show up on time.

Balanced workload distribution is difficult if you try to optimize schedules manually.

You also risk increasing your operational costs. Often in the form of wasted fuel and salaries due to longer driving time.

Furthermore, your customers will be annoyed if your sales reps show up late or your drivers fail to make on-time deliveries.

ALSO READ: Why On-Time Delivery Is Important for Your Business

A vehicle routing software is the perfect traveling salesman problem solution.

A reliable route planner powered by Dijkstra Algorithm will reduce driving time and fuel consumption by finding the most efficient route for your team in seconds.

It ensures on-time deliveries and appointments, cost savings, and driver safety. Also, a route optimizer reduces your field service reps’ drive time and impacts your bottom line. But there is more to it.

Learn the six reasons why you need delivery management software.

Conclusion about the Traveling Salesman Problem

There are many more TSP-like instances with people and vehicles grappling with inaccurate routes and delays.

Scientists have been trying to address problems like TSP for decades. The closest we’ve come- through imperfectly- are complex algorithms via easy-to-use route planner apps.

Route4Me

Want To See For Yourself How Route4Me Can Boost Your Profits?

Whether you want to slash the time it takes you to plan routes for your drivers, increase the number of stops they can make, or keep your customers satisfied knowing that your drivers show up on time… Route4Me helps you achieve that!

Start Free 7 Day Trial

Route4Me

About Route4Me

Route4Me has over 35,000 customers globally. Route4Me's Android and iPhone mobile apps have been downloaded over 2 million times since 2009. Extremely easy-to-use, Route4Me's apps create optimized routes, synchronize routes to mobile devices, enable communication with drivers and customers, offer turn-by-turn directions, delivery confirmation, and more. Behind the scenes, Route4Me's operational optimization platform combines high-performance algorithms with data science, machine learning, and big data to plan, optimize, and analyze routes of almost any size in real-time.