Category: Optimization

  • A Neural Network to solve Travelling Salesman Problems in Excel

    Artificial Intelligence in Microsoft Excel: watch a Neural Network solving a Travelling Salesman Problem

    869 words, ~4 minutes read

    Neural Network solving TSPs in Excel - IntroTerms like Artificial Intelligence, Machine Learning, Deep Learning and (Artificial) Neural Networks are all over the place nowadays.

    If you are reading Tech News, Data Science blogs or your LinkedIn feed, it will be little short of a miracle, if you don’t see one of those expressions at least once.

    This is just the revival of those techniques, though. Neural Networks, for one, have been around for many years. In the mid 1990s (!), I did some research and wrote my thesis about Artificial Neural Networks. We even had a blog post here on this topic 10 years ago: Where the rubber meets the road. For whatever reason, that article didn’t make many friends. I was always wondering why. Probably too academic and not visually appealing enough.

    Now, with the recent revival of Artificial Intelligence and Neural Networks, I decided to give it another shot. Today’s post provides an updated, improved version of a Neural Network solving Travelling Salesman Problems in Microsoft Excel.

    You always wanted to watch a Neural Network solving an optimization problem? If so, this article is for you. Either watch one of three videos provided in the post or download the Excel workbook and play around with it at your own speed. No add-in or third party software necessary. All you have to do is to enable macros.

    (more…)

  • Where the rubber meets the road

    A self organizing feature map for Travelling Salesman Problems implemented in Microsoft Excel

    Self organizing feature map for TSPs - click to enlargeIn the recent post we discussed the question whether Microsoft Excel is a viable platform for developing and testing models and algorithms for complex combinatorial optimization problems.

    The Travelling Salesman Problem (TSP) is probably one of the most popular challenges in combinatorial optimization and Operations Research. Why? I suppose because it is so easy to describe, but hard to solve.

    There are hundreds or even thousands of different algorithms (exact solutions or heuristics) for the basic TSP or its variants. One approach is a so called self organizing feature map also known as a Kohonen Map: an artificial neural network using unsupervised learning to solve combinatorial optimization problems.

    I selected this approach not only because I have done some studies on this topic back in the 1990s, but rather because both, the problem itself and the self organizing algorithm are very well fitting for an interesting visualization model that is fun to watch working.

    Today’s post describes such a self organizing feature map for Travelling Salesman Problems. I will not discuss the math in detail, but rather try to explain the approach itself, the algorithm’s mode of operation and the implementation with Microsoft Excel. As always, the result (i.e. the Microsoft Excel workbook) is provided for free download.

    (more…)

  • Optimization Models and Algorithms using Microsoft Excel and VBA

    Is Microsoft Excel (including VBA) a viable platform for the development of complex mathematical optimization models and algorithms?

    © Rainer Sturm / pixelio.de

    Whenever it comes to implement business calculation models, probably everyone immediately considers using Microsoft Excel. Excel is widely spread in corporate environments and most people are familiar with using it to a greater or lesser extent. The most exciting thing about Excel, however, is its apparently unlimited flexibility. Excel does the math, imports, stores and exports data, creates visualizations, provides a predefined tabular structure, includes a built-in programming language, etc.

    Sometimes this flexibility is boon and bane. The fact that it seems as if you could do anything with Microsoft Excel does not mean you should. I have seen people misusing Microsoft Excel as a word processor, a database, a project planning software or a graphical application. Most of those workbooks reminded me of the following quote by Abraham Maslow (The Psychology of Science, 1966):

    “If the only tool you have is a hammer,
    you tend to see every problem as a nail.”

    Having said this, it is definitely appropriate to always question in advance whether the tool you are intending to use is the right one for the task you are facing.

    Besides financial planning, simulation models, visualization and project management, optimization models and algorithms always played an important role in my professional life. Thus, the question whether Microsoft Excel is an appropriate option for developing optimization models and algorithms for complex combinatorial problems suggests itself. Today’s post discusses this question, including the pros and cons as well as the possible use cases.

    (more…)