Wednesday, 28 March 2007

Happy Birthday Gmail

Gmail turns 3 this year. When announced on April 1st, 2004 people thought it was an "April Fools" joke. However at the time the one Gigabyte for email storage it offered was four times that of Microsoft's Hotmail.

Yahoo now is offering unlimited storage (up from 1Gb) and it would appear that Microsoft has upped the Hotmail storage to 2Gb.

What sets Gmail/Google apart is their ease of integration and the ever increasing products (Gmail, blog, desktop search, notebook, analytics, etc) in the Google software family.

Tuesday, 27 March 2007

Visual Studio turns 10 years old

It's hard to believe that Developer Studio turned ten years old on March 19th. While I'm not big time Developer Studio Power User I do use it each and every day to write server side software and have so since 1999. Here's why I like Developer Studio.
  1. MSDN -- w/o a doubt the best online C++ help
  2. Intellisense
  3. Debugger

What I don't like.
  1. Resource Hog
    1. Leaving the IDE running long term (multiple days) consumes memory and becomes sluggish
  2. Sometime Intellisense freaks out and takes minutes to rebuild its database

I still use ddd and Emacs when programming in the unix world and quite honestly I could easily go back to the world of emacs-man-ddd instead of using an integrated IDE like Developer Studio but as long as my employer insists on running the data center on Win32... so be it.

Monday, 26 March 2007

The discipline of writing software

I've been using C/C++ static analysis tools for almost 20 years now. By 'static analysis' I mean lint. Lint on VAX/VMS; Lint on UNIX; Lint on Win32. By far the best static analysis tool I have ever used is PC-Lint/Flexelint by gimpel.

If you think that your compiler w/ warnings turned to the maximum value will catch your mistakes, you are wrong and are wasting your employer's revenues with your ignorance.

Compilers convert text files into machine instructions. The warnings they generate are merely secondary/tertiary artifacts of this process.

Most recently I presented a three year case study to my employer that clearly shows how the use of PC-Lint reduced software defects from 80%->60%->20% during that three year period.

Not only does lint catch your defects, but by repeatedly seeing the same errors it causes the astute programmer to rethink how he implements software.

Open Source Google Desktop Gadgets

Sometimes it's good to share. With that in mind, three of our most popular gadgets have been open sourced under Apache License 2.0 and are now hosted at code.google.com:

Moon Phase


Ticker for Trekkers


Wikipedia Search


If you've never visited code.google.com project hosting, you're in for a pleasant surprise. It's a completely free project-hosting solution that features source control, issue tracking, and a simple, clean interface.

So go ahead, jump on board, and start working on that feature you've always wanted. Please contact a project owner to be included in a project.

Even if you don't intend to contribute, please report issues and offer feedback.

We encourage gadget developers to take advantage of the talented Google Desktop development community by open sourcing their own gadgets on code.google.com. More information about project hosting is available at http://code.google.com/hosting.

More gadgets will be open sourced, so stay tuned. But most importantly, have fun!

Sunday, 25 March 2007

Algorithmic-Trading blog created

In order to spare professional traders and software engineers working on algorithmic-trading from my mindless brain droppings about science and software in general I have created an algorithmic-trading blog. I hope this enhances the reading experience for all involved.

Friday, 23 March 2007

Researchers develop intelligent, driverless car

If you thought intelligent cars capable of negotiating a city centre with no driver behind the wheel were just the dream of Hollywood film writers you could be wrong. Researchers at the University of Essex think their work developing an autonomous model car could pave the way for intelligent driverless cars.

One question... "At whom will I point my 'driving finger' when a driverless car cuts me off at an intersection?

Full Article Here

Thursday, 22 March 2007

GOD is REAL unless declared INTEGER

John Backus, team leader for IBM in the 1950s, and credited for 'inventing' FORTRAN has passed away. Backus assembled a small group of IBM employees to "develop an easier way to program IBM's new 701 machine". What resulted was, in 1954, a paper titled, "Preliminary Report, Specifications for the IBM Mathematical FORmula TRANslating System, FORTRAN." Backus stayed with IBM for nearly 40 years before retiring in 1991.


Having learned FORTRAN 77 as my first 'real' language, on a CDC Cyber 205, I still have a fondness for it. I recall many a night, as an undergrad, punching cards containing what today seems like trivial lines of code, but at the time was a very complex problem. Waiting for the card reader to swallow the stack of waxed color coded cards containing FOR loops and SUBROUTINE brings back a flood of emotions and memories. Will the program compile? Will the card reader jam? When will I get my output? The undergraduate lab was in the basement of the Weber building on the campus of Colorado State University and as such there was a unique smell that came from being below ground level in an old building. A set of electrical conduits clearly visible because it was easier to run the power cables outside the walls created an industrial effect.


Side Note: Most creative use of the waxed punch cards? A civil engineering professor I worked for used the small rectangular chaff as surface analysis visual aids when filming hydrodynamics in river and flood plain studies. He'd have me duplicate a card that had every possible hole punched. I would go through boxes of minty fresh cards reducing them to Swiss cheese. We would then sprinkle the chaff on the surface and film the swirls and eddies.

Wednesday, 21 March 2007

Importance of Quality Control

When I read the following headlines, I just have to sit back, scratch my head and ask, "What the heck is going on?" Where's the quality control?

Elementary state achievement tests contain errors, board says -- Northwest Herald, Illinois

Many of the errors � ranging from wrong directions on how to complete the exams to multiple-choice questions without a correct answer as an option � were caught before the March 13 testing window opened. School administrators were sent instructions on how to address the mistakes. For example, in seventh-grade reading booklets, students are directed to answer a question on the wrong page. A sixth-grade math question calls for answers in centimeters, but all multiple choice answers are in inches. Other mistakes are in the instructional manual and a Braille test.


Tests of Suspect Pet Food Kills 7 -- CBS

As many as seven animals died in tests of suspect dog and cat food by the manufacturer after complaints the products were poisoning pets around the country, the government said Monday.

I have to ask the obvious, if seven animals die while testing the pet food, why would you release the product?

Tuesday, 20 March 2007

Algorithmic-Trading for Dummies

Will all the algorithmic-trading gurus; the so called boy wonders of Wall Street please get their act together?!

The problem is interface consistency. Sure, there is the FIX Protocol 'standard' that most algorithmic engines use. However, even FIX is stretched to its limit when dealing with algos.

So here's my suggestion to all of you who write algo engine interfaces... attend the FIX Protocol's Algorithmic Trading Working Group and figure this all out!

The diversity in describing an algo (FIX fields, values, etc) are costing all of us time and money. Time to read and understand these so called specifications and money to constantly keep changing our Order Management Systems (OMS) to keep up with your so called great ideas (like calling an order a 'day' order when it really is a 'good until cancel').

Is it really that hard to specify the fundamentals of trading:
  1. price
  2. time
  3. volume
  4. aggressiveness
  5. strategy

Furthermore, quite honestly, algos are money loosing ventures except for folks like me... We have to keep changing software to interface your silly algo engines so we keep getting a paycheck! However, CFOs are none to happy when passed in the hall and thanked by the likes of me for paying me in ever increasing amounts to invest in money losing ventures like algorithmic trading.

I now return you to your regularly scheduled production outage...

Monday, 19 March 2007

Why we write Software

We write software for one of two reasons: to increase revenue or to decrease costs. When you distill down the essence of software development in the dot-com world it comes down to those two choices.

Sorry if this bursts your bubble, but that's it.

Oh sure, writing software is a great vocation, I highly recommend it.

However, understand that all those years spent learning, debugging, testing and patching, still comes does not resolve the question of why we do what we do?

For the 99 percent of us (myself included) who are *not* the top one percent of the programming elite (Stroustrup, Sutter, Gosling, Lamport, etc)... we write corporate software because some 'suit' thinks this idea will generate revenue, or some pointy-haired Dilbertian boss wants to reduce software overhead (cost).

It's somewhat different in the dot-gov and dot-org world, but not much. If this sounds harsh feel free to post a rebuttal.

Friday, 16 March 2007

Our love affair with lists

What is it about humans and our affinity for lists?

Most of us learn sequentially (concrete-sequentially if I use the Gregorc nomenclature to be exact) so here's why I believe we humans like lists (in the form of a list of course):

Growing up I listened to Casey Kasem's Top 40, prior to that was Dick Clark's countdown. My first recollection of a list was all the things I my parents had for me to do before I could go outside and play.

If I search in the dictionary for the word list, I'm confronted with another list of the possible definitions for list (kind of self referential don't you think?).

Here's some others lists:
Which reminds me I have to end this and finish some things on my "Honey Do" list my wife posted on the refrigerator...

Top 10 reason why humans like lists:
  1. Linear
  2. Eye Catching
  3. Digestible
  4. Succinct
  5. Organizational ('todo' list)
  6. Convincing (list of offenses in court)
  7. Comprehensive (this list isn't)
  8. Practical
  9. Transferable (work list)
  10. Trackable (shopping list)

Thursday, 15 March 2007

IT isn't fun anymore!

To some, information technology (IT) was never fun; IT was and is the realm of Dilbertian nerds and pointy-haired bosses. However, for some of us, IT was fun and still is! However, if you're of the "IT isn't fun anymore" ilk then read the article "How to Stop the Dilbertization of IT" by Deborah Perelman

Wednesday, 14 March 2007

Living under a lucky star

I have, on many occasions, been accused of living under a lucky star. Not wanting to buy into the whole 'luck' paradigm... I may have to agree as I once again find myself in a 'lucky' situation being one of the few programmers in my organization that understand how to effectively use and program for multicore processors. Fortuitous I have to admit in light of the article below.

Where Are the Programmers?
EE Times (03/12/07) Merritt, Rick

At a time when the amount of students pursuing computer science degrees is declining, researchers are struggling with the parallel programming that will run on the next generation of multicore processors.

Tuesday, 13 March 2007

Ronald Reagan Responsible for Google Putting a Research Lab in Poland?

While Al Gore may be the self proclaimed creator of the Internet, Ronald Reagan is why Google is putting a research lab in Poland.

Question this statement? Please read on...

Why Google Put a Research Lab in Poland
Christian Science Monitor (03/13/07) Woodard, Colin

Western companies are beginning to notice the value of moving operations to Eastern Europe, where the schools are producing many computer scientists that will work for one-third of the pay of those in Western Europe. The curriculum in many former Soviet-bloc countries is heavily grounded in math, given the former Soviet Union's emphasis on industrial and military production. IBM, Google, and Motorola have all recently opened research labs in Krakow, Poland. "Investment in universities and research in important areas will attract students to these areas, says Google's Kannan Pasupathy. "It's a nice circle which ultimately benefits everybody."

Recall that it was an incident involving Toshiba and the Soviet Union that forced the Reagan administration to use the Combat Command [COCOM] to enforced an international embargo of sensitive technology exports to the Soviet Union.

My colleagues in Krakow, who remember the embargo, tell me:

The universities may be an important factor but one thing that the author of the article is missing is that in fact probably the most important contributor to the high level of skills of Eastern-Bloc computer specialists was in fact the President Ronald Reagan who in the early eighties imposed sanctions, prohibiting the Western Bloc companies to export/share their electronic and computer technology and knowledge. We ended up with software but no manuals, operating systems with no documentations - a situation which forced the entire generation of passionate people [who] got into programming in the late 70s up to late 80s to debug, hack, investigate, figure out, study undocumented code.

And there you have why Ronald Reagan is responsible for Google putting a research lab in Poland.

Monday, 12 March 2007

The SEC strikes back on Pump-and-Dump

As I described in Where have you gone Aleksey Kamardin the Pump-and-Dump trading fraud appears on the rise. Well the long arm of the SEC has gotten just a bit longer in an attempt to halt this overseas attach on our trading systems.

The Securities and Exchange Commission announced March 7 it has won an emergency court order to freeze assets in a Latvian-based bank's trading account that was being used in a high-tech market manipulation scheme.

More on this can be found at Security Watch.

Saturday, 10 March 2007

F-22 Raptor DST bug?

Perhaps not a DST bug, but a time processing bug non the less...

According to the Official Air Force website the F-22 Rapture was delayed in deployment to Kadena.

While en route to Kadena Air Base, Japan, Feb. 10, a software issue affecting the F-22 Raptor's navigation system was discovered.

The Air Force website did not go into more details than that, however CNN Analyst Don Sheppard did,

It is stealthy. It's fast and you want it all to go right on your first deployment to the Pacific and it didn't. At the international date line, whoops, all systems dumped and when I say all systems, I mean all systems, their navigation, part of their communications, their fuel systems... they could have been in real trouble.... they tried to reset their systems, couldn't get them reset. This could have been real serious. It certainly could have been real serious if the weather had been bad. It turned out OK. It was fixed in 48 hours. It was a computer glitch in the millions of lines of code, somebody made an error in a couple lines of the code and everything goes.

Gee, what could cause a software program to crash while crossing the international dateline? Perhaps a time of day processing function?

Let me see if I can reproduce such a bug...


#include "time.h"
#include "assert.h"

static time_t last_update = 0;
const time_t now = ::time(0);
double dif = ::difftime( now, last_update );

assert(dif >= 0.0);

// refresh 'status' every minute
if ( 59 < diff) {
last_update = now;
// do more useful things...
}

This code assumes that at some point in time while crossing the IDL the F-22 received a clock resync (perhaps from a ground station in Japan?). The code above would cause the system to abort, while crossing the IDL from west to east. I'll leave the reverse case as an exercise to the reader.

As we all prepare for the DST bug to hit our email servers, blackberries, and other systems... be thankful we are not flying in an F-22 Raptor.

Thursday, 8 March 2007

Algos Prohibited From Dark Book Access

Many predicted it, some applaud it, others loathe the decision, but let's face it the battle lines are being drawn between dark books and buy side algos. The latest to throw down the gauntlet is Pipeline Trading Systems. Prior to that ITG-POSIT put the kibosh on algos (later they reconsidered).

Who will win this battle has yet to be determined.

What are the driving forces?

"It's the bandwidth, Stupid!", to paraphrase from a past election.

It takes a significant amount of work to implement, deploy and maintain a dark book (or an open book for that matter). True, it takes a significant amount of work to implement an algorithmic trading platform. However, algos don't face the same rules and regulations (e.g. RegNMS) as do their sell side brethren.

Let's frame this in an old world example...

Imagine a few thousand customers streaming into and out of a 'brick and mortar' store all just 'looking' but not buying. It costs the store owner money to maintain the large sales staff and floor space to handle the customer flow on the hope that someone will actually purchase some goods. If the overwhelming percent of people in the store are just looking, it's a time and money drain driving up costs and driving down revenue.

It's the same with dark books. All those algos add overhead w/o generating revenue (trades).

It takes a serious investment in hardware (servers, routers, databases), and software to support all the buy side algos that are just looking.

Wednesday, 7 March 2007

Happy Humpday

Happy Humpday! I said this to a colleague today and she looked at me with a puzzled look on her face. She is from Russia and I'm quite sure she had not heard this term for the day of the week we call Wednesday. This started the small group of us in the office talking about the many different ways to refer to the day of the week we call Wednesday, and since some in the group are not native English speakers we started to compare notes on how to say 'Wednesday' in other languages, and to the etymology of Wednesday.

In German it is Mittwoch (mid week); In French -- mercredi; Italian -- mercoled� (Mercury Day); Danish -- onsdag (Odin's Day); Russian -- sreda (?????); Polish -- sroda (or middle).

According to the
Online Etymology Dictionary we in the English speaking world call this day Wednesday because of the viking (Old Norse) word O�insdagr (Odin's Day). And there you have it, we call this day Wednesday because of the Vikings.

Tuesday, 6 March 2007

Large Hadron Collider (LHC)

The Large Hadron Collider (LHC) in Geneva Switzerland is slated to start up later this year. According to documents on the LHC website the stored energy per beam is 362 MJ (million joules) at peak (collision) energy. The beams of protons will circulate in opposite directions and collide in a controlled enclosure where physicists will analyze the sub-atomic particles created. The round trip will take just about 100 microseconds (.0001 seconds).

So let's do some quick, back of the cocktail napkin calculations based on a worst case scenario. Imagine that a single proton beam gets out of control and is 'aborted'. This means that 362 million joules are directed into a 'dump' in one machine revolution (.0001 seconds). To convert from power (joules) to energy (watts) we do a simple conversion energy = power per unit time or: 362,000,000 Joules / .0001 second or 3,620,000,000,000 Watts (3.62 trillion watts)! That is (according to Wikipedia) the average energy used by the United States in 2001!

In other words it is slightly less than the energy needed to power 3000 Delorians in Back to the Future (1.21 Gigawatts!).

Does anyone see the problem with this?

The New Sidebar and Gadgets



With the dramatically increasing amount of content out there, you need better ways to find relevant information, whether searching your computer or reading the latest headlines in sidebar. How could we improve the way you stay up-to-date with sidebar and gadgets? How could we make it even easier to search files and find that lost book report, web page, or recipe? After many months, we are pleased to release the Google Desktop 5 Beta application, featuring a new sidebar and redesigned Gadgets.

The sidebar has a completely new look and feel. It samples the color of your wallpaper and fades in the sampled color so that it fits seamlessly onto your desktop. Some of our gadgets have been redesigned so that they are easy to tell apart, easy to read, and easy on the eyes. More differentiated gadgets allow for faster scanning of information through the sidebar. And we've created a new dialog for adding gadgets so it's easier and faster than ever to find the right gadgets for you.

In addition, we have improved two other key features of Google Desktop:
  • Desktop Search - Ever searched your computer and seen a row of results that looked almost identical - so you had to open file after file until you found the right one? Now there is a better way: preview search results from within Google Desktop. Don't wait for an entire application to load, just click "Preview" and find the information you want right away. Finding the right file has never been easier!

  • Security - We take your security extremely seriously and have added new features to help make your search experience safer. Whether you�re clicking on links from documents, IMs and email or browsing the web, if we have information that the site you're visiting might be trying to steal your personal information or install malicious software on your computer, we'll give you a warning first so you can decide if you want to use the site.
You can never save enough time looking for information. Find out more about Google Desktop.

Monday, 5 March 2007

Love of Learning

The English Archaeologist, John Lubbock once wrote:

If we succeed in giving the love of learning, the learning itself is sure to follow.

I first stumbled onto this quote whilst studying for an Education degree at Colorado State University. This was after I had received my Physics degree from the same institution. I never forgot the quote, but couldn't remember the author. Thank god for Google!

Anyway, back to the point of this blog entry... the love of learning. It seemed to me then as it does now that we spend so much time cramming facts and figures down our gullets that we don't take the time to really appreciate, nor do we really learn to love learning. Sure, we study for twelve plus years as children, then hopefully off to university for more, but along the way do we ever love learning? Or, instead, are we merely caught up in the maelstrom and maladies of the fact cramming masses? Do we take time to really learn how to learn? to think? to reason? How do our educators encourage us to love learning?

One more John Lubbock quote that reminds me of studying in Colorado and the lyrics to a John Denver song:
Earth and sky, woods and fields, lakes and rivers, the mountain and the sea, are excellent schoolmasters, and teach some of us more than we can ever learn from books.

Saturday, 3 March 2007

My Inner European is Swedish?

You Should Learn Swedish

Fantastisk! You're laid back about learning a language - and about life in general.
Peaceful, beautiful Sweden is ideal for you... And you won't even have to speak perfect Swedish to get around!

Friday, 2 March 2007

Algorithmic Trading Problems

My main concern, four years ago, when algorithmic trading became popular was that it is a feed-forward system. The algorithms respond, in near real-time, to changes in electronic signals (bid, offer, trades) hoping to move the market in a direction favorable to the algorithm's goal(s). The problems with feed-forward systems specifically and controller theory in general are well documented and one of the primary problems is the inability of these systems to respond to novel situations like what was experienced this week in the markets.

I have worked in the financial markets the past seven years, and before that spent nearly ten years in the high energy physics research environment of Fermilab. I was more than a bit concerned when I started seeing algorithmic trading specifications, typically using the FIX protocol, show up on my desk about two years ago. My concerns center around the general lack of training most programmers receive regarding loop control and controller theory.

Therefore, this week when the markets started to fluctuate, in novel ways, I was not surprised when technical snafus at NYSE, Dow Jones and Arca started the electronic trading version of a microphone placed too close to a speaker. I have to wonder, but will probably never know, what role algorithmic trading engines contributed to the inflated tick volumes observed this week?