August 20, 2007
As you are probably aware, I have not posted anything in this blog for over a year. What you might not be aware of is that after my long blogging hiatus I went back to my old blog in blogspot: http://franciscogutierrez.blogspot.com and I am going to continue blogging there from now on.
Why the change? Well, first reason is, I noticed that even at the height of its popularity, this blog never came up higher than my inactive blogspot blog whenever anybody looked me up in google. This is of course because blogspot is a google site, so they naturally rank it higher. The second reason is that I cannot put ads in this blog! Granted I am not going to be making much money anyway, but in principle I am bothered by that fact. If I can build a large audience, I don’t want to go through the inconvenience of moving URLs later, I’d rather do it now.
So that’s it, this is my last post in this blog, I just wanted to direct anybody interested in reading my ramblings to the new location. See you around!
July 12, 2006
Israel is kicking ass and taking names. After Hezbollah kidnapped two of their soldiers they have invaded Lebanon. They are properly treating this as an act of war, and responding accordingly. Israel Defense Forces Chief of Staff Dan Halutz said “If the soldiers are not returned we will turn Lebanon’s clock back 20 years.” It was about time! Appeasement never works, and trying to appease the Palestinians by giving them Gaza was the wrong approach. Maybe they knew it all along and they did it to show the world what would happen in order to get support from other countries. I doubt they will get support, but at least now they won’t get interference in the exercise of their right to self defense.
Why doesn’t appeasement work? Because once somebody initiates violence against you, there is no more room for negotiation. Negotiation assumes that both parties are willing to listen to each other, that they will use reason as their means to coming to an agreement, and that they will respect whatever they end up agreeing upon. The party initiating violence has decided that reason is not an effective way to get what he wants, has decided to stop listening, and has no intention on reaching any agreement or keeping its word. The initiator of violence thinks that he is stronger than the other party, and that he will get what he wants by superior force. What is the proper response in that situation?
The proper response is to use overwhelming force against the initial agressor. He has to understand that he is not stronger, and that by choosing to initiate force he has chosen to end up in a worse situation than what he would have, had he negotiated. This is not about payback or about getting even. This is about breaking their will, and showing them that the use of force will only lead to their destruction. Therefore, the response does not have to be proportional to the initial aggression, as some critics have suggested. If they attack a military post, it is legitimate to retaliate by nuking two of their cities as the United States did to Japan. That showed them that initiating violence was not a wise course, they stopped doing that, and now they are our best friends.
By negotiating with terrorists and giving them Gaza, Israel had given the impression that it was weak. This meant that the strategy had worked, suicide bombers had broken the will of Israel and now it was ripe for the taking. They decided to start taking, and they found out they were wrong. Israelis have shown that they can be nice when their neighbors are nice to them. Now it is time to show that they can be 1000 times more violent than those who initiate violence against them. The name of the game is not appeasement, the game to play now is deterrance.
June 16, 2006
Unified Theory of Learning Systems; or why markets, neural nets, evolution, and Page Rank are all the same thing
I was recently thinking about the commonalities between all systems that can learn. Neural networks learn by updating the strength of the connections between neurons. Groups of people and societies in general learn by leveraging the power of markets. Species learn through natural selection and evolution. The Page Rank algorithm that Google uses to analyze the links between all pages on the web learns by updating the weight of each page based on the pages that link to it. What do all these systems have in common? I will try to answer that question in this post.
I first saw the connection between neural networks and markets when I was thinking about prediction markets. In a neural network, every time a connection is used to produce a "positive" result the strength of the connection is increased, and every time it is used to produce a "negative" result the strength of the connection is decreased. Positive and negative depend on the purpose of the neural network. If the neural network is the brain of a mouse, finding cheese would be considered a positive result but getting an electric shock would be a negative result. If the neural network is supposed to identify a handwritten number 6, then correct identification would be considered positive, and incorrect identification would be a negative. In any case, the positive signal could be considered a payment to the neural system, and the updating of the weights is how the neural net distributes the payment among those connections that were responsible for the results. Those connections that are right, i.e. that were activated when the payoff was positive, get paid more by having their strength increased. In contrast those connections that were wrong lose part of their fortune by having their strength diminished. We can start seeing an analogy to a market here, a connection is a bet in a particular direction, and those connections that get it right have more to bet in the next round, but those connections who get it wrong have less to bet.
Now let's look at a market. When an individual buys a security in a market he is betting that the security is going to go up in price. If he is right he makes money and the purchasing power of his account increases, if he is wrong, he loses money and his purchasing power decreases. Next time he makes a decision to buy or sell, the amount that he can buy or sell is going to be limited to how much he has in his account. After several rounds those who usually guess right will have pretty big accounts, and those who usually guess wrong will have very small accounts. So their guesses will be weighted differently, and the price resulting from aggregating those guesses will become more accurate. Once the market reaches a steady state the purchasing power of individuals will be proportional to how good they are at guessing the right price, and the aggregate price will be the most accurate. So the purchasing power of each individual is the weight of their vote, the strength of their connection to the final aggregated price.
From the previous paragraphs we can see how neural nets and markets are alike. We can think of markets as weighted voting systems, where the size of the account of each individual is their weight, and the system updates the weights of individuals according to the accuracy of their votes in predicting an outcome. We can think of neural networks as markets where connections bid for a particular correlation between the activity of two neurons, and those who bid correctly get rich, but those who bid incorrectly lose their shirts.
We can now start to see some of the commonalities:
1) Both of these learning systems have a predicted signal and an actual signal, their objective is to make the predicted sinal equal to the actual signal. In the case of a market the predicted signal is the market price of a security and the actual signal is the true price of the security, the price that makes supply equal demand and that makes markets clear. In the case of a neural net the predicted and actual signals are more obvious since neural nets are designed for pattern recognition where the pattern is the actual signal, and the predicted signal is what the neural net guesses when it is learning.
2) Both of these systems are composed of several distinct units that vote/bet for an outcome, or for a part of the process in an outcome. In the neural net each connection between two neurons is a vote for the state of one neuron being relevant to the state of the other neuron in predicting an outcome. In a market each individual buying or selling a security is voting on whether that security is overpriced or underpriced.
3) Both of these systems give different weights to different voters. Connections are weighted in a neural net, different market participants have different levels of wealth, where the wealth represents buying power, and since each transaction is a vote, the vote is weighted by the wealth of the person doing the transaction.
4) Both of these systems learn by updating the weights of the voters. In a market those who vote wrong lose some of their wealth, in a neural net those connections who contribute to wrong results lose part of their strenght.
5) Once these systems learn, their weights stop being updated. This is achieved by a dynamic equilibrium where the sum total of positive updates is equal and opposite to the sum total of negative updates. Once a neural net learns what it needs to learn, the weights remain stable, they lose as much as they gain in every training round. Once the market participants have attained a level of wealth that represents all their knowledge on a particular security, they are as likely to guess right as they are to guess wrong, so their gain as frequently as they lose and their wealth remains static.
Now that we have these basis, it is easy to see how they extend to other learning systems. Consider evolution, each gene is a vote for a particular physical characteristic for an organism, and on how likely is the organism that possesses that characteristic to survive in its environment. Those genes that vote correctly get reproduced more often than those who vote incorrectly, and their percentages in the population increase. This means that they have a higher weight on the percentage of the next generation. The wealth/weight of each gene is represented in the percent probability that they have of being passed to the next generation in contrast to competing genes. The fitness in genetic algorithm parlance. Once the optimal phenotype is reached the percentages reach a steady state, where half of the organisms are helped by the characteristic, and the other half are hindered. This shows that evolution is very similar to markets and neural nets, since it conforms to the same five broadly outlined principles above.
What about the Page Rank algorithm? This algorithm is applied to a directed graph to find out which nodes are the most popular. At first glance you would want to count how many incoming links each node has to measure its popularity. That is a good first approximation, but not all links are equal, the links of more popular nodes are worth more than the links of unpopular nodes. So you start by counting the links and assigning a popularity to each node, then you count the links again but weight the links according to the popularity of the incoming node. This updates the popularity of each node, so you do this again, until you reach a steady state and the popularity measure of the nodes doesn't change. Again, we can see that each node is voting by linking to other nodes, and its vote is weighted by its popularity. Its popularity is updated according to how many popular nodes point to it. The algorithm of updating can be thought of as a flux of popularity through the system, from the least popular to the most popular. Each node in between has some popularity coming in and some going out. The steady state is reached when the popularity coming in equals the popularity going out. Although the training signal here is less obvious than in other learning systems, it is still something separate from the predicted signal, it is the actual popularity of each node according to the graph topology. As we can see Page Rank also shares the same five basic characteristics of learning systems that markets, neural nets, and evolving systems all have.
I think we can apply the same sort of analysis to anything that learns. That is a conjecture that I am not going to prove because it would require me to either enumerate all learning systems, or prove that a system that doesn't share those characteristics cannot learn. That proof might be doable, but that would be too much work for a Friday night post. My purpose is only to advance the hypothesis that all learning systems are instances of the same algorithm and to provide some examples as evidence to that conjecture.
To the science and engineering inclined, this can serve as motivation to specify the learning algorithm exactly by observing many instances of systems that learn. To the mathematically inclined, this could serve as motivation to find a rigorous argument of why this is true. To the scientifically inclined with a skeptic bent, this can serve as inspiration to try to disprove it probably by finding an example of a learning system that doesn't fit the model. As for me, this was just a way to record an insight I found interesting.
As I finish writing this I realized that the expectations maximization algorithm, and the fuzzy clustering algorithm also fit this description, but I leave these as an exercise to the reader because I am tired of typing, and I want this post to be short enough for people to actually read.
June 10, 2006
I was at the prediction market summit in Chicago this Wednesday, and I got to hear some of the people who are at the cutting edge of research in prediction markets. A prediction market is a market that is used to aggregate the information of all its participants, and to estimate or predict things more accurately than any individual or group in that market. The hollywood stock exchange is a perfect example of a prediction market. In this market people buy and sell stocks on movies which are valued based on the total revenue that a movie produces during its opening weekend, so after the movie opens the stock holders in that particular movie cash out. So while trading in a movie, the market participants are guessing what they think that movie will gross. It turns out that the hollywood stock exchange is a very accurate predictor of the revenue a movie will bring in. The same is true with other prediction markets on sports, election results, news buzz, etc.
We all know that markets produce efficiency by leveraging the self interest of those participating in them. We learned in economics 101 that everybody trading in a market ends up the same or better off after the trade, and that is why capitalist countries are rich to the extent that their markets are free, and why socialist countries are poor to the extent that their economies are planned (for an experiment confirming this, look up East vs. West Germany in your history books). One thing we might not learn in economics 101 is that markets are also the most efficient ways to discover, aggregate, and propagate information that is hidden in the mind of its participants, and that is the point that research in prediction markets tries to emphasize. With millions of people buying and selling, a market somehow figures out the exact price at which supply equals demand, so a standard market can be thought of as a prediciton market for the equilibrium price. Thus, prediction markets harness this property of markets to learn other things that may have nothing to do with prices. They are excellent tools to exploit the collective intellect of an organization, for example to forecast the sales of a company by creating an internal market for all its employees.
In a previous post (Let the invisible hand grab your long tail) I was saying that a business that wants to serve the long tail of its market would be well served by leveraging the power of markets. My example of a long tail business that leverages the invisible hand of a market was eBay. I argued that since markets provide incentives for participants in a long tail business to serve each other's needs, it made it cheap for the business to serve its customers. It turns out that prediciton markets are yet another way in which the invisible hand should be allowed to touch your long tail.
May 24, 2006
In a pure democracy each individual has one vote, but pure democracy is not a good form of government. Pure democracy killed Socrates in Athens, pure democracy is you and two drunken bums in a street corner deciding by a majority vote on the allocation of the contents in your wallet, pure democracy is the dictatorship of the proletariat also known as communism, pure democracy is a majority of whites deciding that blacks should be slaves, and pure democracy is a majority of christians deciding that heretics should be burned.
Thanks to the wisdom of the founding fathers, the United States is far from a pure democracy despite what George Bush may say, what we actually have is a constitutional republic where the government is very limited in the things that it can do. We only use democracy to decide on the things that the government is not forbidden from doing. So a christian majority could not impose a national religion, and a KKK majority could not just vote to have slavery restored. In those cases and many like them there is no democracy, and that is very good.
Where things went wrong, is that while the government is forbidden from imposing a religion or from instituting slavery, it is not forbidden from "redistributing" wealth through taxation. This results in the situation where two bums and yourself are voting to allocate the ownership of the contents of your wallet. Those who don't have any money and don't care to work to get it will always vote to simply take it from those who work and "redistribute" it to themselves. In any other context that is considered stealing.
The solution I propose to this problem is to have the vote of a person be weighted by the total amount of taxes that person pays. That way, those who don't pay any taxes would not have the power to steal from those who do. People who really care about voting would overpay their taxes in order to have their vote count for more. If taxes became too high, those who pay the most of them would have the power to lower them. Interest groups could raise money to pay more taxes so they could vote more in an issue that they cared about. Lobbyists would stop bribing politicians and start paying more taxes instead, in order to buy influence. The final result would be that most taxes would be collected from voluntary donations, and very few if any would have to be mandatory.
This would still be a democracy, but without the unfair "redistribution" of wealth from those who work to those who vote. This is what I call a tax-weighted democracy. A corporation works similarly, each stockholder votes proportionally to how many stocks of the corporation they bought. A tax-weighted democracy would be more like a membership, people vote according to how much they pay in dues.
The only modification that I would make to the tax-weighted democracy would be weighting the vote of veterans higher than those of other people. Serving in the military and risking one's life to defend our country is a very steep form of tax payment which is not adequately compensated by the salary received, so this would be consistent with a tax-weighted democracy.
May 10, 2006
I have never done a triathlon, and I am not too good of a swimmer, but nevertheless I am signed up to do a sprint triathlon this summer. I entered an indoor triathlon last year, but we were in the swimming pool, stationary bikes, and treadmills, going by a fixed amount of time instead of fixed distance. In contrast, in a "real" triathlon you actually have to swim in open water, bike on the road, etc. The sprint triathlon I am doing has an 800 meter swim, followed by a 17 mile bike ride, and a 5K foot race.
I signed up to put pressure on myself and get me to exercise consistently. It took seeing the imminent arrival of the triathlon date and having visions of me drowning in the Boulder reservoir to get me to act. However I am happy to report that I have been training every morning at 6 am for a month already. This coming from a guy who has trouble getting up at 10 in a normal day.
I think this is a very effective way to motivate oneself. Most of the time we try to motivate ourselves with a carrot (if I exercise I will be healthy, etc.) but sometimes we need a little stick (if I don't exercise I will look very stupid being rescued in a boat from the reservoir) to push us over the edge. Now that I have started training, I found out that I can actually swim those 800 meters with no problem, so I am not afraid of the triathlon any more. My real challenge is to turn my exercising every morning into a habit. I read somewhere that 3 weeks create a habit, but it doesn't feel very natural quite yet.
March 28, 2006
What should we do about the illegal immigration problem?
On the one hand, the borders need to be secured. Currenly, thousands of people cross the borders illegally without being checked by customs or homeland security. This is the perfect way for terrorists to come in and smuggle nuclear and biological weapons.
On the other hand, history has shown that when there is supply on one side, and demand on the other side, the market always finds a way. Whenever governments attempt to stop an economic activity through legislation a black market emerges. That is exactly what we have today, a black market for immigrant smuggling. If we ignore economic reality and attempt to close the borders to all willing labor, the black market will continue. Alcohol prohibition didn’t work, the drug war was a total failure, making prostitution illegal has never worked, and trying to control the labor market is not going to work either. As long as there is demand for labor, and people willing to supply it, the workers will find a way to come, and the employers will find a way to hire them.
So I think the best way to solve the problem is to dismantle the black market by giving people who want to work here a legal avenue to do so. We currently have about 800,000 people crossing illegally every year. If 1,000 terrorists wanted to hide themselves among those crossing it would be relatively easy since these 800,000 are never interviewed by a border agent when they enter the country. However, if we allow those 800,000 people to come in through the front door we would be able to check their backgrounds, and we would effectively slam shut that potential revolving door for terrorists.
The same is true for the 12 million illegal immigrants currently here. If 10,000 terrorists wanted to hide among the illegal population they would find it relatively easy. However, if we were to offer work permits to illegal immigrants, the great majority would step forward and register, leaving only terrorists and criminals operating in the shadows.
Would we still have a black market for people who didn’t meet the standards? Not likely. The current black market is driven by a legitimate and powerful market force, the need of employers to find labor, and the need of workers to find jobs. If we legalize that, the engine that drives the black market will get redirected to legal activities. Since there is no market need for terrorist activity in the US, there is no economic engine to power a black market for smuggling terrorists or for keeping them here.
Would we be flooded by people becoming citizens and taking over the country? Not likely. A proposal to legalize labor does not necessarily entail an easy path to citizenship. Also, not everybody who comes here to work wants to stay here. A large percentage of illegal workers come here with the intention of making a few extra dollars so they can go back and start a business, buy a house, buy a car, etc. A lot of them stay here because if they go back it will be hard to get back in. We could (and should) still have stringent requirements for citizenship, but not for work permits.
March 22, 2006
I was listening to the Feynman’s lectures on my way from work today, and he said something that got me laughing so hard that I had to stop the CD for a while. He was talking about the evidence we have to conclude that gravity works all the way from our scale to the scale of galaxy clusters. He was showing a picture of a galaxy cluster to his students, and he said “If you cannot see gravity acting here, you have no soul”. I’ve always heard of “having soul” as something related to the appreciation of certain types of music and art, so I figured I must not have any. But if the appreciation of physical laws qualifies me, then I am a soul man!
March 9, 2006
When I started drinking beer in college they all tasted the same to me. At the time (blasphemy!) I actually thought that Coors Light was a good beer! As my exposure to beers increased I discovered Guiness, and stout was my favorite beer style for a while. Later, I found that I liked porter style the best; in particular, I really like Java Porter which is brewed by Mountain Sun in Boulder. Then I discovered Arrogant Bastard Ale by the Stone Brewery, and I found that I liked all of the beers from Stone Brewery as much as I liked Java Porter. However, I just found a beer that is superior by leaps and bounds to any other beer I have ever tasted, the beer is Bigfoot Ale by Sierra Nevada. It is thicker than a stout, and it has the caramel-like flavor of a stout, but it also has a very strong bitter flavor like a porter, but it is stronger than typical porters. I don’t know the lingo of beer drinkers, so I can’t quite describe the flavor like a pro, all I know is that it is my new favorite beer! The only problem is that it is a seasonal beer, so they don’t have it in stock all the time. If you go to the liquor store right now you might still find it, otherwise, you’ll have to wait for the next winter.
March 6, 2006
I spent this weekend in a law conference organized by Front Range Objectivism. The speakers were first rate, we had both academics and practitioners, and the topics complemented each other from the very abstract to the very applied. Tara Smith talked about the different doctrines on interpreting the constitution held by legal scholars today. Some of these doctrines are clearly non-objective, and even though originalism claims the high ground on objectivity, Tara Smith showed why this is not the case. Eric Daniels talked about unenumerated rights, the history of the 9th and the 14th amendment, and how the cases decided by the supreme court have radically changed the view of rights by today’s courts. It was shocking to discover that modern courts treat the 9th amendment as meaningless, and think of rights as a laundry list, whereas the original intent was to think of government powers as a laundry list. Dana Berliner talked about the case of Kelo vs. New London (which she litigated working for the Institute for Justice), what this meant for property rights, and what we can expect in the near future. Amy Peikoff talked about the history of our idea of privacy as a right, and made an interesting case for subsuming all the protections which currently fall under privacy under more fundamental rights, such as life, liberty and property.
I came away of this conference with a much better understanding of how constitutional law works. Also, I was very encouraged to find out that even though the supreme court went the wrong way on Kelo vs. New London, the awareness of the issue and shift in public opinion that came from the high profile case has done more to damage eminent domain than a supreme court ruling in favor would have done. Polls found out that 98% of people from all political persuations believe that the use of eminent domain for private undertakings is wrong. So any politician who wants a chance at getting elected or reelected is going to have to address this. As we speak, many states (including Colorado) have initiatives to make this illegal at the state level. The Institute for Justice has created the Castle Coalition site to report on eminent domain abuses, and watch the progress of the movement against it. One thing I sugested to Dana was to put up a list of the companies that benefit from eminent domain on this site, so I can avoid doing business with them whenever possible, and also, so I can short their stock.