Interesting probability theory descriptions of games like minesweeper

minesweeperWhat are some interesting probability theory descriptions of games like minesweeper?

The Minesweeper game was (surprisingly) often used as a toy model for studying randomized algorithms and algorithms working in random environments.

A nice introduction to both algorithmic and probabilistic aspects of the Minesweeper can be found in this B. Sc. thesis “Algorithmic Approaches to Playing Minesweeper” by David J. Becerra from Harvard.

Some advanced studies exploring different algorithms and their relation to probabilistic models of the Minesweeper can be seen in the paper “Optimistic Heuristics for MineSweeper” by O. Buffet, Ch.-Sh. Lee, W. Lin, O. Teytaud,

or in the paper by M. Sebag and O. Teytaud “Combining Myopic Optimization and Tree Search: Application to MineSweeper”.

As for games like minesweeper in general, some of them were found to be connected with percolation theory (which is one of the most fashionable branches of probability at the moment), as well as with Markov decision processes, and computational complexity studies.

A good example of research in this direction is a paper “The Minesweeper game: Percolation and Complexity” written by Elchanan Mossel from Microsoft Research.

pc-gamersWhat does all of this beautiful mathematics says to a passionate gamer? Namely, what would be a good algorithm for solving the puzzle, and is the solution computationally hard?

In fact, the minesweeper is one of the classical board puzzles based on algebras of binary variables. Algorithmic solutions to these problems are typically sought with the use of integer linear programming. Unlike simple linear programming, integer programming problems are typically NP-hard. This is true even for binary integer programming where variables can only be 0 or 1 rather than arbitrary integers.

This transforms into the fact that, in its general formulation, the minesweeper is indeed algorithmically NP-complete. However, there is an argument that, if the minesweeper board is already known to be consistent, solving it is only guaranteed to be co-NP-complete, and might be (or not be) NP-complete.

And here is the raining defending Minesweeper world rekord holder Kamil Muranski performs his skillful play. Not sure if his brain is using integer linear programming or not 🙂


Good introduction to general relativity theory for mathematicians

einstein1_7What is a good introduction to general relativity for a mathematician?

A direct and specific Quora question. Definitely demands a direct and specific answer 🙂

If you are a fan of vintage classics, you can go with Hermann Weyl “Space, time, matter”.

It’s an old book, but still very readable as an introduction for mathematicians. And the author is Hermann Weyl, out of all people. And I personally like him even more since he also graduated from the University of Göttingen.

And then, of course, you have the all-time classics L.D. Landau & E.M. Lifshitz “The Classical Theory of Fields” ( Volume 2 of A Course of Theoretical Physics ).

Yes, these are the guys from the Landau-Lifshitz equation. Landau was a Nobel Prize winner (and a student at Göttingen 🙂 ), and both Landau and Evgeny Lifshitz were academicians of the Russian Academy of Sciences and honorary members of many other national scientific societies around the globe.

Their book is rough, tough and mathematical, but provides a great introduction and explains so many important aspects of the theory, while most of modern introductory books just do hand waving and popular lingo speaking for hundreds of pages.

And, as a note of caution: if you aim to understand the general relativity and do not want to read pseudo-scientific fantasy, avoid books by Stephen Hawking.

P.S.  The guy from the picture above is famous not only for his creation of the relativity theory, but also for some of the work that he did at the German Federal Institute of Physical and Technical Affairs, also known as PTB and as the place where I’m happily doing my own  research affairs for the past three years. The world feels so small right now 🙂

What careers are avaliable that require an extensive knowledge of mathematical logic?

Russian_Sherlock_Holmes_1Besides Computer Engineering / Computer Science, of course. Naturally, this is a Quora question once again.

As a good example, any profession that involves data analysis, processing or modeling, requires a solid knowledge of mathematical logic. By solid knowledge I mean finishing at least one semester course on formal logic at a university.

The reason for this is that data is represented to us as numbers, and studying numbers is governed by mathematics. Numbers belong to mathematics, they were born within mathematics. And any type of work in maths requires decent understanding of formal logic.

Therefore, not only careers in Computer Science, but also careers in data science, machine learning, quantitative finance, economics or meteorology all demand having a good knowledge of logic.

Additionally, formal logic is instrumental in any profession that requires Sherlock Holmes-level deduction and argumentation on the basis of facts. This includes lawyers and criminal investigators. They do have courses on formal logic in some of the better institutes.

Just having a good common sense can’t fully replace a course in formal logic. Since the times of the Russell or Zermelo paradoxes, it was understood that the so-called naive logic (based on unformalized common sense and the naive set theory) is self-contradictory. Good understanding of basics of formal logic prevents you from running into paradoxes in your debates.



How can a Computer Science student achieve the same level of knowledge of Statistics as that of a Statistics graduate?

This is one of those questions that I am getting asked on a regular basis. When I saw this in my Inbox mailed to me by Quora, I knew it’s time to step up and speak out 🙂

In fact, that’s a very easy question that has a straightforward answer. Of course, the answer has to be generic, because there is no way to give a specific answer addressed to an abstract “Computer Science student”.


In order to achieve the same level of knowledge in statistics as a statistics graduate, you have to put in the same total effort to learn statistics as a statistician does. There’s no shortcut.

The same principle is valid the other way around. If a mathematics and statistics graduate like myself would like to learn to code as good or better than CS students, I could only achieve this by spending a lot of time improving my coding skills.

However, in case if you are already familiar with machine learning, then you have already made substantial efforts in the area and you are definitely not a beginner.

If you continue learning and reading about those areas of statistics that are relevant to your work, you will keep getting better and there will be no limit to your improvement.




Slides and photos from the Barcelona Conference on Asymptotic Statistics 2008

The Barcelona Conference on Asymptotic Statistics (BAS2008).

Mikhail Langovoy Barcelona 2008

Mikhail Langovoy among the participants of the Barcelona Conference on Asymptotic Statistics 2008

I was a fresh Ph.D. and greatly enjoyed having a travel grant from the Centre de Recerca Matemàtica. Great memories from both the city of Barcelona and the Bellaterra Campus where we stayed with a number of prominent statisticians.

This is the conference abstract that won me a place among the participants and the travel grant. And these are my talk slides.

I plan to upload further photos and materials related to this Conference to the Media section of my website.

Presentations and Media updates

Just started populating the media section of my website with slides of my presentations, publishable project materials, photos and videos of my lectures and talks. I will be uploading new materials as soon as I would be able to obtain relevant permissions.

As I still regularly use blackboards for my talks and lectures, parts of some presentations did not make into slides or other digital media. I also gave a number of talks that were blackboard-only, very old school of me.

Bear in mind that I also enjoy cracking a joke or two during most of the presentations. Of course, these jokes and stories are all witty, appropriate and on topic 🙂 , but they do not make it into the slides. Therefore, slides can appear a little dry and they can never fully capture a presentation or a lecture.

A video + the slides combination works much better, but only some of the talks were professionally recorded on camera, and not all of these videos could be posted on the web (not because of age restrictions, of course 🙂 ; most of the videos are copyrighted or contain discussions of sensitive data).

Therefore, the best way to enjoy these slides is still to attend one of my talks in person. Now I can sleep well, knowing that the newest technology is still unable to outperform me in some of my professional activities 🙂

Meanwhile, slides, pictures and videos will be getting uploaded to the Media area.

Learning and being open vs being a yes-man

There is a very important topic of being open to new ideas and being able to learn new tools related to your profession, and it amazes me that this subject causes quite a bit of misunderstanding. So I felt that it might be a good idea to express my thoughts on the matter and to clarify some misconceptions.

I work on extracting knowledge or business value from data and information. This is a truly interdisciplinary area where we use machine learning, statistics, mathematics, computer science, together with software development and business analytics. Essentially, on a daily basis.

Of course, when so many tools are involved and so many skills are required, there is noone who knows everything in this profession. Therefore, it is essential that you learn something new or perfect some of your skills on a daily basis. I followed this advice since my student days and now, after 20 years, there are still endless opportunities to learn something useful and it is extremely easy to find an area where to improve yourself.

A crucial ingredient to success of this approach is the ability to evaluate your skills adequately. You hinder your progress or even stop it completely if you get overconfident and generic in your self-evaluation. On the other hand, you are also wasting your time and efforts if you are undervaluing some specific skills that you’ve already developed. Adequacy is the key.

Now let’s give a very common example. In my interactions with dozens of departments, I probably had close to a 100 situations of this type 🙂

Imagine you’ve done a Ph.D. on hypothesis testing or published papers on classification in machine learning. And then there comes a colleague of yours who just saw a Wikipedia article on A/B testing or read some blog entry about that new hot classifier that was recently proposed in a poster at the local college conference on AI.

Your colleague is all excited, says that’s the coolest thing since sliced bread and demands that you write a seminal joint paper with him or, at least, abandon all of your current work and reorganize the company analytics to have his new favorite method at the core of the business 🙂

A typical twist in this type of stories comes from the fact that you’ve probably either already tried this method and found a better one, or you know that the method simply doesn’t work for your task. After all, sometimes this can be a mathematically provable statement. And you tell this to your colleague, as politely and constructively as possible, of course.

Now, there’s a probability that the colleague still gets upset and claims that you’re a know-it-all, and that you aren’t willing to learn new things and that you aren’t open to new opportunities.

Do not get into the trap of feeling guilty and switching to the obviously ineffective method. These remarks aren’t coming from your colleague’s brain, they come from his ego that is temporarily hurt. If you both waste your time working on something bogus, this will do no good for both of you and for the employer.

At the end, you might feel even more guilty for not stopping the madness earlier, you can damage your reputation as a domain expert, and your colleague might still blame you for the fact that his bad idea didn’t work out as he expected. A fairly unattractive perspective if you ask me 🙂

Willingness to abandon your good results and to discard your knowledge just because someone else got excited about a new buzz word, is not to be confused with openness to new ideas and willingness to learn and improve.

A proper name for the former is being a “yes-man” and a pushover. You wouldn’t learn or improve by working on a bogus method, indeed.

As for you colleague, if he is really open to new ideas, eager to learn something new, and strives for perfection, a moment like this is exactly the right time for him to prove it and to learn something from you. Something useful.