On July 22, 1962, everything was ready for NASA to launch the first probe of the Mariner program. Its objective was to carry out the first non-lunar overflight in history with a visit to planet Venus. The launch occurred without incidents, but the rocket began to respond erratically to the commands sent by the guidance systems, and the safety officer had no choice but to order its self-destruction 294.5 seconds later. What happened? Someone wrote a mathematical symbol incorrectly in a transcription, and it ended up as a software bug.
Let's start this article with a small piece of bad news: The launch of the James Webb Space Telescope has been delayed again. A review board analyzed the current situation of the telescope, and it will need at least three more years of work... as well as an injection of 800 million dollars in its budget. What does this confirm to us? Going to space is difficult, and it is expensive. Both factors force experts to be conservative, otherwise a simple error could cause even greater losses. NASA learned this the hard way on several occasions. One of the first was Mariner 1:
The $150 million mistake
The original representative of the Mariner program had a cost of $18.5 million in 1962, which adjusted for inflation places it above $150 million. On the morning of July 22, Mariner 1 took off heading to Venus to carry out the first non-lunar flyby in history, and to obtain data on its atmosphere and temperature. The performance of the Atlas-Agena rocket was correct... but the same could not be said about its behavior. To maintain the trajectory, Mariner 1 used two systems: one that measured its speed with Doppler shift measurements from a ground installation, and another tracking system that measured distance and angle relative to an antenna installed in the launch area. The first system experienced a failure, and although the second had the technical capacity to contain the problem, the nature of the error made the flight too erratic. Why?
The missing vinculum
The written code to interpret both distance and angle had an error: a horizontal bar was missing on the top of a symbol, a vinculum as it were. The role of the bar was to take the average value of the first derivative that marks velocity (the dot under the line). By "smoothing" the velocity value, any fluctuation should be eliminated, but with the absence of that vinculum, the onboard computer of the rocket began to receive erroneous information, and with each compensation attempt it became a flying carnival. The origin of the error is evident: there were no advanced programming environments or automatic error detection. The conversion of handwritten or typewritten code to punched cards was slow, tedious, and costly. Fortunately, NASA found the error, applied the necessary corrections, and Mariner 2 achieved what its brother could not a month later.