Posts

Sorting is computationally harder than playing chess

I will argue below that sorting of a big array, using only comparison, is inherently harder than solving the problem of choosing the best next move on a chess game. One could say that it is not fair to put in competition a big, however finite, problem like chess with an arbitrary big problem like sorting n elements. Fair enough; the interesting thing is that sorting becomes inherently harder than chess for an "n" that is way smaller than you would expect, like sorting 3000 elements. At least in theory... Sorting takes a minimum of n* log 2 (n) comparisons,  more exactly  log 2 (n!) This is about sorting "by comparison only" and can be proven in 2 step. You can skip to the "chess" part if you already know this. 1. Sorting can be done in  log 2 (n!) comparisons, that is just slightly less than n* log 2 (n). We are used to consider sorting an O (n* log 2 (n)) problem. Actually there are algorithms that can do the sorting with little less t...

Godel and psychological types

“There are two types of people in the world, those who divide everybody into types and those who do not”. I am part of the second type ;) Is the text above true or false?

Backup your photos for 20 years or more - ideas

Image
External hard drives Will you have your digital photos after 20 years from now? Will you regret to not have them? How can you safely store your digital photos in order to still have them in 20 years or more? I am talking, for example, about the pictures or movies that you take with your smartphone or with your digital camera. I know I will want to have them after years. Digital pictures tends to be even more fragile than paper pictures. Do you still have all the digital pictures that you have taken 10 years ago? What if your smartphone gets stolen, or your desktop hard drive fails? What if you delete the pictures by mistake when re-installing the operating system? Here are some ideas that I got when I evaluated the way to keep my pictures for 20 years or more. I am already using some of this methods for my pictures. I am open to other suggestions and comments. General considerations  No single solution for storing digital content is perfectly safe for 20 years or more ...

Why is my smartphone charging very slow on USB ?

Image
Better read: Data Consistency in Distributed System - CAP, PACELC Morality series - a heptalogy This blog is mainly focused on my Philosophical and theoretical ideas. From time to time I have practical posts that are too few to deserve a blog by themselves. I still hope my other work (like above) is even more valuable than such practical article as below. * * *   Sometimes the phone is connected to a charger, it reports "charging", however the battery level increases painfully slow, or it could even actually decrease. What is the solution? On short: Update 2020 : prefer original chargers. Even using QC 3.0 charger, some Samsung phones (like A51) will charge faster with original charger - when the display is ON. With display OFF, QC 2.0/3.0 chargers might still be as fast as original chargers. For phones, prefer the 1A ("phone") charger port to the 2A ("tablet") charging port. The 2A port is likely to charge slower than the 1A port (see below why)...

Debt gives value to money

What gives value to money? There was a time when money was pure gold. Later, money was a certificate that you own a quantity of gold in bank (banknotes). Now the money are just quality paper, without any deposit behind. How that it has any value? Some said that money is just a convention, and the fact that the state accepts that coin as the "legal tender" gives it value. However, we know many coins that lost theirs value despite the state effort to  sustain it. How that other coins survives? I claim that debt is the one that gives value to the today's (fiat) money.

DNA and the fabric of the Universe

Image
The genetic code seems to not be enough to describe the complexity of a human being . In fact, it seems too small to describe most of the life forms. We could assume that the genetic code has all the information very compressed, but still... I will approach the problem of describing life complexity based of information theory.

Genetic code (DNA) is not enough

Image
Photo: wikipedia.org Genetic code (DNA) could be seen as the best compression algorithm that we have ever seen . Just think about it: in only around 1 GBytes, DNA could store the information to create a human being, with all the general and specific characteristics and many non-educated behaviors. In 1 GBytes, the current technology could barely store a 1.5 hour movie at rather low quality, but human DNA is able to encode everything that is human in a lifetime.