On this page I plan to write about a couple of things I find interesting or entertaining.
The pictures below were taken by me and my wife.
1. The Turing Machine and Busy Beavers
The Turing machine is an abstract model of a computer introduced 1936 by the British mathematician Alan Turing. It provides a theoretical framework for defining the notion of computability and for measuring the complexity of algorithms and thus plays an important role in theoretical computer science.
The machine has a memory-tape, consisting of memory-fields strung together infinitely in both directions, and a read&write-head on the tape, that is able to move to adjacent fields. Usually, the fields can only contain the numbers 1 or 0.
A program for the Turing machine consists of finitely many states (command lines) each having a number or a name. Depending on the current number on the field under the head, a state tells the head whether to write 0 or 1 on this field and whether to move left or right afterwards. Furthermore, each state has to name a following state which has to be executed next. A program always starts with the “start”-state S and then works step by step through the states of the program until it reaches the “hold”-state H and stops. Note that a program doesn’t necessarily have to reach H and can hang-up. The initial configuration of the tape is considered to be the input of the program. When the program reaches H, the configuration of the tape functions as the output.
Example of a program:
|state||if read||write||head||goto state||if read||write||head||goto state|
Now, what has this all got to do with beavers?!…”The Busy Beaver” is the name of a challenge related to the Turing machine. Given a certain number of states, the goal is to find a program that starts with a zero-tape, writes as many 1′s on the tape as possible and finally does stop. I am always wondering if the Busy Beaver is funny, crazy or both. But it surely is challenging and impressive. The number of 1′s that can be created by very short programs is much larger than one would expect and the process of creation seems to be completely chaotic (at least to me).
Use the web-based machine from above and try it a little for yourself—for example with the 5 states S,1,2,3,4. In fact, you can get 4.098 ones with a 5-state program and allegedly more than 1018.267 with a 6-state program. If you want to know how, you can look here—but you shouldn’t try to run the 6-state program on the web-based machine because it would take ages. While running the 5-state program with 47.176.870 steps, my browser asked me several times if I want to continue and the 6-state program is supposed to take at least 1036.000 times as many steps.
2. Finding Financial Information
One way to look at investing is to grasp it as a perpetual process of gathering, filtering and interpreting information and reacting on what you find. Organising this process is quite a challenge and requires ongoing adaptation itself, as the amount of different and relevant information is vast and the world nowadays is changing quickly.
Particularly, for small savers and investors it is exceedingly difficult to stay informed, since those can neither afford the personal services of accountants and analysts nor the professional data and news services of companies like Thomson Reuters and Bloomberg.
Personally, I spent a lot of time searching the Internet for reliable and easy accessible sources of information that are free of charge. In fact, I keep searching and every suggestion you email me is welcome. The first things I came across were free financial news sites like www.reuters.com and www.bloomberg.com (those two I like best at the moment), which are pretty useful to begin with. On these websites you get a lot of news and also quotes and other data. After signing in you can create an online portfolio, that helps you to monitor your assets. However, if these sites were perfect, Bloomberg and Reuters would probably have a hard time selling their fee-based services. The main flaw lies in the lack of customization and the inefficiency with that you obtain the data. Theoretically, the amount of free information available on these sites is enormous—but there is no easy way to collect it in a processible format.
What other options are there?!…With regard to the problem of monitoring the state of your portfolio, finance.yahoo.com does great charitable work. Yahoo Finance provides a free API (application programming interface) and thus helps people to collect financial data automatically. You can use Excel, for example. Because of the API it is quite easy to implement a short VBA program that loads Yahoo data into Excel, where you can process it further. In my experience not all data provided by Yahoo is useful and reliable, but prices (though slightly delayed) are. Furthermore, the amount of available exchanges, securities, indizes, currencies and commodities is very nice. The only real downside is that the API is not officially supported by Yahoo. So, the future stability and existence of this service is rather uncertain.
Compared with online portfolios, downloading prices into a spreadsheet has a lot of advantages—above all monitoring becomes fully customizable. For example, you can derive any statistic you want, collect and graphically display historical data, calculate and surveil your individual fees and taxes, measure the diversity of your assets, consider currency effects etc.—and all of this in a very efficient way. Moreover, you don’t have to share details about your financial situation with some website provider.
So, for tracking news and stats of single assets as well as monitoring your portfolio there are viable and free solutions available in the World Wide Web. But, obtaining more complex market data is much more difficult. For example, various stock prices tend to correlate and, in the worst case, overvaluation and subsequent crashing of a significant number of them might drag down the whole sector or even the whole stock market. Therefore it is desirable to have a good judgement on the market valuation of whole classes of stocks, instead of considering only single values. Unfortunately, calculating price-earnings ratios for stock baskets by yourself is not feasible, since P/E ratios and market capitalization are usually only available for single stocks and not in a processible format. The only valuable and free source of this kind of information I found was www.standardandpoors.com, who provide useful spreadsheet data related to their S&P500.
The ultimate answer to all data problems of small investors therefore might be Webscraping, a software technology for extracting data from the World Wide Web. Webscraping software doesn’t need APIs or any kind of data interfaces and simply communicates with websites like a human user. It gets “taught” what data to extract and then proceeds by itself, delivering the data in a processible format. There are a couple of Webscraping solutions around the Internet—freeware as well as commercial—but so far I haven’t found the time to test one of them. I think that Webscraping is really interesting and might be a very powerful tool, applicable not only in finance. However, a lot of providers probably won’t appreciate intense harvesting of their websites and will eventually fight back—legally as well as technically. In fact, I somewhere read that Webscraping already did cause litigation between companies.
Finally, a small list of links that I found useful in this context but won’t discuss: