Archive for the ‘Miscellaneous’ Category

Inefficient Market Hypothesis

Saturday, December 27th, 2008

The financial markets are touted as being efficient by most leading economists.  A large faction of economists tend to disagree and claim that the markets are only mostly efficient because humans are not fully rational agents.

An efficient market is one where all available information is accounted for in the price of an assett or good.  If there is a deal to be found, then it has already been found by someone else.   For instance, car dealership XYZ misprints a coupon and offers a $50k BMW for $25k to the first buyer.  An efficient market hypothesis formulates that someone else will arrive as quickly as possible to snatch up the good deal.

An inefficient market is one where prices do not take into account all available information, or one in which the participating agents don’t make the most logical decisions.  As in the above example the dealership offers a brand new BMW for 50% off… a great deal!  But suppose they make the offer on Saturday in a 100% Orthodox community.  Orthodox Jews can not handle money on the Sabbath and thus the BMW goes unpurchased until Sunday leaving the random out of town straggler to stumble upon the deal of a lifetime.

Aside from quirks like the above, the markets are usually efficient.  If there is a deal to be had, it will be had. But I’d like to formulate my own hypothesis on inefficiency which stems from my understanding of the human psyche.

Markets are inefficient because human decisions are influenced by the following: overestimated future extraction of the good of an asset, greater fear of loss than hope at an equal sized gain, pride of ownership.

1.)  Humans are extremely biased creatures.  We have to be.  In order to survive it’s necessary to make decisions without all of the data.  This means bias.  When it comes to a purchase or investment humans continue the pattern.  Many of our purchase or investment decisions are made by comparing a list of highly complex options.  Once the decision has been made (just go for it) the mind then plays the trick of soothing the resulting anxiety (did I make the right decision?) by hyping up the enjoyment that the purchase or investment will bring in the future.  As the future has not arrived yet it’s perfectly understandable to assume that product X or investment Y will bring us more fun or wealth than we ever imagined.  This is not rational and leads to inefficiencies in the market.

2.) Humans fear loss far more than they hope for an equal sized gain.  If you were to take a survey of 1,000 people and ask them to value what their right arm was worth, take the average amount and triple it you’d still find that almost all of those surveyed would still rather keep their right arm than exchange it for the money.  In another example we can take marriage.  A young man dating a beautiful young woman often balks at the idea of marriage until he loses the potential bride, simply because the fear of the loss of other potentially better brides is greater than the hope of living a long and happy life with a beautiful and smart woman[1].  We hate risk, irrationally so, and it causes inefficiencies in the markets.

3.)  Humans love to be owners.  And once we own something, our mere ownership causes the item to become more valuable.  Our pride in ownership is purely an emotional state which is the result of our inborn need to nurture.  We are built to love, nurture and cultivate.  It’s how God (or Evolution if you insist) designed us.  Give us a baby, we feed it, a dog and we pet it, a plant and we water it, a car and we change the oil, a house and we fix it, some stock in a company and we watch it “grow”.  It is this irrational attachment to our friends, children and even things that has allowed us to continue from generation to generation, but it also causes inefficiencies in the market place.

What does this all add up to?  It adds up to two consequences:

Inefficiencies cause bubbles and bursts…mass movements towards and away from investments and goods fueled by irrationality. The bad thing about inefficient markets is that you may get caught in the burst unprepared.  But the great thing is that inefficient markets provide opportunities for gain.

The main lesson is don’t be afraid about an economic crisis… it’s irrational… and besides it’s likely that another bubble is forming somewhere.  If you’re quick you can probably catch it on the upswing!

  1. I also wonder, from an economic perspective a good woman is worth far more than her weight in gold, quite literally, why then would a man prefer to live the single uncommitted life? []

When computers control all essential societal functionsw

Monday, November 3rd, 2008

It is apparent to a researcher in Machine learning and Artificial intelligence that soon enough machines will be controlling many of the essential resources of our society.  The webs that will be woven by the interdependent parts of our cities and countries  will be held together by increasingly powerful and complex networks of computers.

Since computers can store far more information in their immediate memory and can play out 1,000’s of scenarios per second they are the clear choice for such jobs as: air traffic control, airplane scheduler, train engineer, traffic and road designer, stop light designer, telephone switch operator, and any number of jobs that require such comlex decision making.

I don’t think machines will ever “take over” like they do in the matrix, but the question will soon arise, what happens if we unplug one machine?  What about 20?  Furthermore, what if the machines make apparently sub-optimal decisions… how will we be able to tell if they really were sub-optimal?

I think the most likely worst-case-scenario will begin to be not that the machines take over the world and force us into slavery, but rather that our dependence on them becomes so great that we are afraid to do anything without their consent… even if it means doing something that is right, but crosses logical boundaries.

Problem with ‘Table Full’ for MyISAM DB?

Monday, November 3rd, 2008

If you need to expand your MyISAM table size for your MySQL DB becuase you simply have too much data then this is a nice quick tutorial on accomplishing your goal.

http://jeremy.zawodny.com/blog/archives/000796.html

Basically do the following

mysql> alter table your_table max_rows = 200000000000 avg_row_length = 50;

And that will increase it to its maximum size.

				

Adaptive UI

Thursday, October 9th, 2008

Designing a website, or a User Interface for a program is hard work.  One has to study people and their often hard to predict and difficult to quantity decision making processes.

For instance, google.com shows a clear knowledge that user’s get distracted by anything other than the task at hand if presented with multiple options.  Thus their site has one main focus… a search bar.  They, are are after all, a search company.

google.jpg yahoo-screenshot-2.jpg

But what if User Interface designers, and website designers started to pay attention to the actual math behind user interactions?  Like living organisms, what if the website or user interface adapted to the user?  For instance, if the website knew that people browsing on cloudy days liked a more cheerful design why wouldn’t it brighten up the background?

Or perhaps in Yahoo’s case why not reorder the sidebar links in order of most clicked on?  What about Yahoo’s search bar?  Might that feature become larger and more prominent?

Why aren’t websites and Program designers doing this already?  They may be, but the sheer volume and dynamism of large user bases makes it a very difficult and ever changing job.

I suggest that website and User Interface designers move to a design framework which includes the ability for the site or program to collect user statistics, and then reorganize itself according to some preset rules.  Flex, Flash, php, python and a host of other programming languages could all support these features really easily.  And if you can’t think of a better optimization algorithm, simply allow the user interactions with the site to be a sort of genetic algorithm.

A good analogy for Operations Research

Thursday, September 25th, 2008

The other day I was trying to explain the concept of constrained optimization to an artist.  As I was fumbling around a bit, my friend (who was also a Math nerd) said:

Constrained optimization is like fishing… you have a limited amount of bait, you don’t know what the fish want, how many fish are out there, or what type/proportion they are but the goal is to catch as many as possible in a few hours.

While it’s not a perfect analogy… it’s pretty good.  What’s your favorite analogy for constrained optimization?

Fun with Heliostats Part II

Saturday, September 20th, 2008

This week expanded my first heliostat by adding another 8 sq. ft of mirrors (bringing the total to 24 sq. ft) and have also added a second heliostat.  The second sun collector uses 12 1 sq. ft mirrors (mirror tile from Home Depot or Lowes, $10).

Circular heliostat

I tried to take temperature readings of the second colletor, but ended up frying my thermometer.  Regardless the temperature on the brick gets well over 150 degrees and is unbearably hot (can’t but my hand on it for more than about 1 second).

Overall, the heliostat project is a success and I have determined that the second more circular collector will make a good space heater for the office.  The plan is to put the bricks inside the office window and the mirrors outside.  As the day progresses the brick will heat up and heat up my office.  By the time the sun goes down I’ll be done with work and wont need any more heat.

Circular heliostat closeup

As for the water heater collector, there will be too many drags on heating efficiency and transfer too and from the house.  I’ve decided that it will likely be better to build a flat panel with small pipes to collect the heat and to move the panel much closer to the house.

Water Heater heliostat

Water Heater closeup

Overall, this project has been fun and has really shown me that for a really low cost (<$40 for the second circular collector) one can build a solar powered heater.

In the future I’d like to test what the effect of concentrating the sun on a real PV panel would be.  I’d like to set up two panels  relatively close to each other and test how much more efficient one can make the panel by concentration.  I exepect that a factor of 1.5-2X power will be acheived by focusing 2X the solar area. Perhaps with a third row of mirrors to the circular collector it might be possible to push the efficieny up to 2.5-3X. If this turns out to be the case it will enable the average person to go Solar, bringing down the cost of solar by about half.

Ode to Linux (and Open Source)

Tuesday, September 16th, 2008

The trusty ol’ T43 got sick this weekend with the “Windows Anti-Virus 2008″ virus.  Try as I might, I could not get it off of Windows XP.  I tried everything and every software to no avail.  Luckily I didn’t decide to the buy the “anti-virus” software they were pitching to solve the “virsuses” they had detected on my computer (this particular virus is actually mal-ware which tries to convince you that you have viruses and to buy their software to fix it).

I read tales of woe of those who “bought” the software only to have their accounts drained.

But as I was giving up and cursing windows for making such an insecure Operating System (really? Windows, you couldn’t have prevented such an attack?), I remebered that ntaylor0909 had just given me a copy of Ubuntu Server 8.04….

So I wiped ‘er clean and am now up on Ubuntu Linux.

I have to say so far I’m quite impressed.  It’s free… it works… all the programs for it are free… and they work too… and I hear that it’s even quite secure.

Thank you Linux!

R code for visualizing a reflective surface in 2d

Wednesday, December 19th, 2007

Given that you have some reflective shape expressed in mathematical form the following code written in R will help you to visualize the effect of bouncing light (or potentially audio or any other object) off the surface of the object. It only calculates one bounce however and does not account for multiple reflections…perhaps sometime in the future. This script produces plots like the following:

A circular reflector.

A histogram of the y-intercepts of the reflected rays for a circular dish.

(more…)

Unix Completes me too

Wednesday, November 21st, 2007

Though this woman doesn’t quite match up with my preconceived notion of what a “Unix user” should look like I quite agree with her sentiment :-)

Not your typical unix user.

(more…)

Website Grader

Friday, November 2nd, 2007

I was reading Guy Kawasaki’s blog “How to change the world” and came across a link to the following site which helps to optimize your webpage for search engines.

After running Scroggles and greentheo through the service I’ve found that there is still work to do! Must continue building and optimizing Scroggles!