« December 2004 | Main | February 2005 »

Saturday, January 29, 2005

Tom Swift and His Wireless Message Now Online

The sixth episode in the Tom Swift canon, Tom Swift and His Wireless Message, is now available in the Tom Swift and His Pocket Library archive. I've made a preliminary editing pass over the text, and will post an updated edition with corrections to any typos and formatting errors I failed to spot after I've read the novel on my PalmOS PDA. If you see any howlers, feel free to point them out via the feedback button.

Posted at 00:17 Permalink

Friday, January 28, 2005

Reading List: The Probability Broach: The Graphic Novel

Smith, L. Neil and Scott Bieser. The Probability Broach: The Graphic Novel. Round Rock, TX: Big Head Press, 2004. ISBN 0-9743814-1-1.
What a tremendous idea! Here is L. Neil Smith's classic libertarian science fiction novel, Prometheus Award winning The Probability Broach, transformed into a comic book--er--graphic novel--with story by Smith and artwork by Scott Bieser. The artwork and use of colour are delightful--particularly how Win Bear's home world is rendered in drab collectivist grey and the North American Confederacy in vibrant hues. Lucy Kropotkin looks precisely as I'd imagined her. Be sure to look at all the detail and fine print in the large multi-panel spreads. After enjoying a couple of hours back in the Confederacy, why not order copies to give to all the kids in the family who've never thought about what it would be like to live in a world where free individuals entirely owned their own lives?

Posted at 21:54 Permalink

Thursday, January 27, 2005

Entropic Storm: Fourmilab sans eau

If you think having your Internet connection go down is irritating, try going for a couple of days without running water. On Tuesday, the 80 mm steel pipe which supplies water to Fourmilab burst, leaking water at the rate of 200 m³/day (folks, that is a lot of water), most of which was evacuated through the ground water collection system until the main valve was closed late Tuesday afternoon. The most probable location of the leak happened to be under a mountain of snow piled up after removal from the driveway, which mountain had to be moved Wednesday morning before prospecting for the leak could begin, using a sensitive ground conduction microphone to localise its subterranean source.

2005-01-27dig.jpg Wednesday afternoon was spent digging up the driveway, homing in on the position of the pipe, and verifying that we'd found the leak--there was nothing subtle about it--the steel pipe was completely cracked in two. Neither I nor the utilities guy from the commune had ever seen anything like this before--in my experience pipes tend to fail with a linear fissure along their length (or eaten away with electrolysis). This pipe looked like God's own sledgehammer had fractured it.

2005-01-27oldpipe.jpg Having located the leak (or, as my entropic storm-tossed brain persisted in deeming it, "the first leak"), Thursday morning was spent expanding the hole around the leak both downward below the one metre depth where the water pipe ran (to avoid freezing--did I mention that this fun-fest was conducted in temperatures of -10°C?) to make room for the splice sleeve, and along the run of the pipe to have enough room for the splice and to ensure we'd removed all of the failed section. The picture at the left shows the failed pipe after it had been fully excavated. The failure isn't obvious in this picture (click on the image for an enlargement), but it's about one quarter of the way from the right of the trench. The grey tube above the black water pipe is the conduit in which the telephone lines run into Fourmilab; above it is a solid metal ground conductor to protect the phone lines from lightning strikes.

2005-01-27break.jpg The failed section of the pipe was cut on either end with a diamond cut-off saw--as soon the first end was cut, the segment of pipe fell apart at the break. At the left are both pieces of the removed pipe, showing the break on the shorter end. Clearly, from the rust around most of the fracture, the failure occurred over an extended period, starting as a slow leak from a hairline fracture and only failing catastrophically a few days ago. 2005-01-27brokened.jpg At the right is the other end of the fracture. At the top of the pipe (which was the bottom while in place) is some ice which formed due to residual water and ground water seepage. Although the temperature was unusually low during this event, freezing had nothing to do with the pipe's breaking--it was just the usual entropic storm pile-on. The plumber who installed the splice said that he'd seen a number of similar failures. Apparently, steel pipes buried the 30-40 years ago when Fourmilab was built were relatively brittle, and slow ground motion (due, in all likelihood, to construction in the vicinity and its perturbation of groundwater flow) is sufficient to make them shatter. Today, a more ductile alloy is used which is less prone to shatter due to slow creep. That's nice to know, but those of us with long runs of the old, brittle pipes beneath hideously expensive to dig up stuff have plenty of new material to inspire Old Facefull nightmares.

2005-01-27newpipe.jpg Once the broken pipe was removed, remediation consisted of installing a replacement pipe, also steel, with a sliding sleeve joint which fit over the ends left when the failed section was cut out. The sleeve has joints with what appear to be brass compression gaskets, which are forced into a seal by extensive pounding on a large wrench with a substantial sledgehammer.

When visiting southern Africa, few sights are as common as women carrying large jugs of water on their heads from the river back to their villages. The miracle of pure water, distributed on demand to every household at the turn of a tap, is something which is difficult to fully appreciate until you've done without it for a few days.

Posted at 21:13 Permalink

Wednesday, January 26, 2005

Moon near Apogee, Earth near Perihelion Posted

Since I'm clearly not going to get better shots of the Sun and Moon at this apogee/perihelion apparition, I've gone ahead and integrated the photos from January 23rd into the Moon near Perigee, Earth near Aphelion document.

Posted at 23:23 Permalink

Tuesday, January 25, 2005

Well, that'll have to do...

meteo_2005-01-24.gif Yesterday's brief parting of the clouds which permitted photographing the Sun and Moon in the same sky with the Earth near perihelion and the Moon near apogee appears to be the best opportunity I'm going to get. According to the forecast, it's snow as far as the weatherman can predict, and you can't see either the Sun or Moon through falling snow.

Still, I ain't complaining--this is the closest coincidence of an apogean full Moon with perihelion until 2014, and given the usual weather this time of year, being able to shoot the Sun and Moon between the clouds at the same time is rare enough to make you believe that wishing for good weather really works.

Posted at 00:18 Permalink

Monday, January 24, 2005

Moon near Apogee, Earth near Perihelion

In July 2004 I posted Moon near Perigee, Earth near Aphelion, which compares two images taken within 24 hours showing the full Moon near perigee and the Sun from the Earth near aphelion. In that document I said that, weather permitting, I hoped to shoot the converse case: full Moon near apogee and Earth close to perihelion in December 2004. Well, the weather
Click image to view enlargement.
didn't co-operate, but I still held out hope for the end of January. This isn't quite as close to perihelion (which occurred on January 2nd at 00:37 UTC) but it'll do: on January 23rd the Earth is about 156,000 kilometres from perihelion, only 3% of the distance from perihelion to aphelion. The difference in apparent size of the Sun is barely perceptible.

Given that it has snowed for the last five days, the weather didn't look all that promising in the run-up to the January 23rd apogean near-full Moon. But then, right before sunset on Sunday the 23rd, the Sun emerged from between the clouds. I grabbed the tripod on which I'd already mounted the Nikon 500mm f/8 mirror lens with full-aperture Orion solar filter and D70 digital camera body to be ready for such opportunities, dashed outside, planted it in the snow, and took a bunch of shots at various shutter speeds. With the Sun only 4° above the horizon, the seeing was less than ideal, but two sunspot groups were clearly visible (and handy for focusing). Well, turbulent skies sure beat a kilometre-thick cloud deck from which snow is sifting down. We're amateur astronomers; we make the best of what we get!

After shooting the Sun, I turned to the Moon, which was rising in a pellucid sky in the East. While the Moon won't be full until 10:33 UTC on January 25th, it was already 97% full, and only three hours before perigee (18:55 UTC). I whipped off the solar filter, centred the Moon, and shot a sequence of exposures at various shutter speeds. In both the Sun and Moon photos, I used the D70's self-timer to trip the shutter to minimise vibration. I'd have preferred to use an ML-L3 infrared remote, but that gizmo appears to be fabricated from unobtanium bar stock--I've had one on back-order for more than six months--so the self-timer will have to serve in its absence.

Details . . . you want details. OK: the Sun was photographed at 15:48 UTC on 2005-01-23 at 1/80 second with the CCD sensitivity set to ISO 200. The Moon shot was taken at 15:55 through the same f/8 500mm mirror lens sans solar filter at 1/500 second. The images were cropped and contrast stretched, but not otherwise manipulated, then assembled into a GIF animation with Jasc Animation Shop. The sunspot near the centre of the solar disc is NOAA Active Region 0726; the one near the solar limb is Active Region 0725.

With the blink comparison between Sun and Moon, the difference in angular extent is obvious. Note how this image compares with the converse configuration almost seven months ago.

Posted at 01:17 Permalink

Sunday, January 23, 2005

Reading List: X-15 Photo Scrapbook

Landis, Tony R. and Dennis R. Jenkins. X-15 Photo Scrapbook. North Branch, MN: Specialty Press, 2003. ISBN 1-58007-074-4.
This companion to Hypersonic: The Story of the North American X-15 contains more than 400 photos, 50 in colour, which didn't make the cut for the main volume, as well as some which came to hand only after its publication. There's nothing really startling, but if you can't get enough of this beautiful flying machine, here's another hefty dose of well-captioned period photos, many never before published. The two page spread on pp. 58-59 is interesting. It's a North American Aviation presentation from 1962 on how the X-15 could be used for various advanced propulsion research programs, including ramjets, variable cycle turboramjets, scramjets, and liquid air cycle engines (LACE) burning LH2 and air liquefied on board. More than forty years later, these remain "advanced propulsion" concepts, with scant progress to show for the intervening decades. None of the X-15 propulsion research programs were ever flown.

Posted at 21:46 Permalink

Tuesday, January 18, 2005

Reading List: Mental Radio

Sinclair, Upton. Mental Radio. Charlottesville, VA: Hampton Roads, [1930, 1962] 2001. ISBN 1-57174-235-2.
Upton Sinclair, self-described (p. 8) "Socialist 'muckraker'" is best known for his novels such as The Jungle (which put a generation off eating sausage), Oil!, and The Moneychangers, and his social activism. His 1934 run for Governor of California was supported by young firebrand Robert A. Heinlein, whose 1938-1939 "lost first novel" For Us, The Living was in large part a polemic for Sinclair's "Social Credit" platform.

Here, however, the focus is on the human mind, in particular the remarkable experiments in telepathy and clairvoyance performed in the late 1920s with his wife, Mary Craig Sinclair. The experiments consisted of attempts to mentally transmit or perceive the content of previously drawn images. Some experiments were done with the "sender" and "receiver" separated by more than 40 kilometres, while others involved Sinclair drawing images in a one room with the door closed, while his wife attempted to receive them in a different room. Many of the results are simply astonishing, so much so that given the informal conditions of the testing, many sceptics (especially present-day CSICOPs who argue that any form of cheating or sensory information transfer, whether deliberate or subconscious, which cannot be definitively excluded must be assumed to have occurred), will immediately discard them as flawed. But the Sinclair experiments took place just as formal research in parapsychology was getting underway--J.B. Rhine's Parapsychology Laboratory at Duke University was not founded until 1935--five years after the publication of Mental Radio, with the support of William McDougall, chairman of the Duke psychology department who, in 1930, himself performed experiments with Mary Craig Sinclair and wrote the introduction to the present volume.

This book is a reprint of the 1962 edition, which includes a retrospective foreword by Upton Sinclair, the analysis of the Sinclair experiments by Walter Franklin Prince published in the Bulletin of the Boston Society for Psychic Research in 1932, and a preface by Albert Einstein.

Posted at 16:05 Permalink

Monday, January 17, 2005

Tom Swift and His Electric Runabout Now Online

I've added the fifth episode in the adventures of the plucky boy inventor, Tom Swift and His Electric Runabout, to the Tom Swift and His Pocket Library archive. As always, I've made a preliminary editing pass over the text, and will post an updated edition with corrections to any typos and formatting errors I failed to spot this time after I've read the novel on my PalmOS PDA. If you see any howlers, please feel free to point them out via the feedback button.

Posted at 01:01 Permalink

Sunday, January 16, 2005

A World, at Last

The images of Titan from Huygens are mind-boggling. I was there when Viking 1 landed on Mars (well, not on Mars, more's the pity, but in the Caltech auditorium where the first image came in line by line), and having seen the first Ranger and Surveyor images from the Moon, then, years later, the Soviet Venera images from Venus, one expected another tedious dead dry rock.


Here is a world where you look at the shoreline across the ocean (having no idea, so far, what liquid fills it, nor what solid upon which its waves break), and almost see where the cities would be at the mouths of the great rivers. After forty years of dessicated cratered deserts, blazing Hellscapes, and iceballs, here's a world with landscapes which invite you to found cities on the coast--time to re-read Clarke's Imperial Earth!

If you've seen only the processed, published images, you've missed the wonder of this world you'll see over the next few days. To explore it on your own, download the Zipped archive of images, extracted from the triplet raw images. Some of these images are blank, and most can be best viewed, before any custom image processing, by performing a histogram stretch or normalise, which will give you an idea what's in the image that less brutal processing can tease out.

Posted at 02:15 Permalink

Creating Multilingual Web Documents with Apache HTTPD

I host a French-language site on my Web server devoted to the history of the village where I live in Switzerland. We intend to make an English translation of this available for anglophone emigrants researching the origin of their ancestors, so I've been looking into present-day, less painful alternatives to the traditional approach of creating copies of everything (except the images, sound files, etc.) in different directories or with file names based on the language, then fixing bazillions of links in zillions of files accordingly.

It turns out there's a feature in the Apache HTTPD which, in conjunction with the "content negotiation" facility in HTTP 1.1, provides a reasonably painless solution to migrating a single-language site to a multilingual one in an incremental fashion without disrupting everything already in place.

In order to use this, your Apache server must support the mod_negotiation module, but as this is enabled by default, most installations already include it. The directory tree which includes the multilingual documents must be configured with the "MultiViews" option. This option is not implied by "All"--you must explicitly set it in your HTTPD configuration, or with an "Options MultiViews" statement in a .htaccess file in the directory with the multilingual pages or a parent directory above it. You can only specify this option if the "AllowOverride" directive in httpd.conf permits it. If you don't have control of your HTTP server's configuration, you'll have to take this information to the ogre who administers your server and beg on bended knee that s/he/it grant you this boon.

With the enabling .htaccess file in the document directory, we can now begin to transform the single language documents into a multilingual ensemble. Let's start with the main page, "index.html", which is displayed when a user enters the directory. Any page with a simple extension of ".html" bypasses language negotiation, so the first step is to rename this page as "index.html.html". Huh? Well, it's an idiom--a page so named is deemed the default for users whose language preference isn't satisfied by any language-specific page in the directory. You should choose the language of the majority of visitors to your site for this page. That way, a French-speaking user who's checking your predominantly French-language site site for updates from an Internet café in Pakistan where the language preference has been set to Urdu (ur-pk) will see your best guess as to the most probable language. The default page should contain links, right at the top or otherwise obvious when the page appears, to each of the translations available. Use flag icons and translations of the language name (for example, "Deutsch", not "German"; "עברית", not "Hebrew") for these links.

Next, create pages for each natural language translation of pages in the directory. For index.html, we might have:

index.html.de     German
Now, when a user tries to access the document index.html, which doesn't exist in the directory, the Apache server looks at the user's language preferences and returns the first available page which matches the highest priority language preference or, should none match, the default page, index.html.html.

If a user has set up their language preferences in the browser, the result is "indistinguishable from magic"--the proper language appears for each page viewed, and links within those pages have no need to be language-specific, since when an explicit lookup of the URL fails, the language preference is used to obtain the best page for the user. Thus, a page which links to "archives/postcards.html" will, if no postcards.html file exists in directory archives, choose the best language match or postcards.html.html as the default.

I've set up a toy directory to play with this. Visit this directory, and you should see your language of choice, with English, French, German, and Italian included, plus a "Multilingual Default" page for those with language preferences which include none of the available languages. Each page includes explicit links to those in the other languages.

There are, as always, some significant gotchas here. First of all, the visitor to your site may be using a browser which is clueless when it comes to content negotiation. When following a link to a directory in which multiple language versions of "index.html.*" files are present, they'll see only the directory listing and have to figure out clicking on their preferred language code. Worse, on explicit links to multilingual documents, it's the Dreaded 404 they'll see. It's up to you to weigh the benefits of nearly painless migration to a multilingual site against brickbats from users of antiquated browsers.

Next, you have to worry about excess specificity in language preference on the part of your users. It seems that some browsers downloaded by users in the U.S. come with a default language preference of "en-us", the dialect of English spoken by denizens of that polity. You'd expect that if a Web page specified its language as "en" and the user requested a more specific version of that language, the general version would be delivered. But you'd be wrong--language matching, at least as far as I can determine based on my experiments, is a pure string comparison, so you might well consider making symbolic links to your ".en" documents from ".en-us" and so on.

And finally, be sure your ".html.html" default page includes prominent, localised links to each of its language-specific peers, and that your language specific pages have a means to switch to the other available languages. One hopes that a browser downloaded by a user who requests a given language for its user interface will request documents in that language as its first choice, but you never know.

What pops out of a search engine is knowable only to the pigeons savants at Google and their painstakingly pecking peers at the competition, so to avoid inadvertent «faux amis» hits in search engines, don't forget to specify the principal language for each of your pages, ideally in the <html> tag, for example, <html lang="la"> for a document in Latin.

This is more or less a first draft of a tutorial on MultiViews I'll eventually publish on the main site. I'm posting it here to run it by the most critical readers and bleeding-edge early adopters (flattery, yes, but perfectly true) to invite corrections and brickbats before I encourage others to build multilingual sites this way.

Posted at 01:30 Permalink

Saturday, January 15, 2005

Reading List: I'm the Teacher, You're the Student

Allitt, Patrick. I'm the Teacher, You're the Student. Philadelphia: University of Pennsylvania Press, 2005. ISBN 0-8122-1887-6.
This delightfully written and enlightening book provides a look inside a present-day university classroom. The author, a professor of history at Emory University in Atlanta, presents a diary of a one semester course in U.S. history from 1877 to the present. Descriptions of summer programs at Oxford and experiences as a student of Spanish in Salamanca Spain (the description of the difficulty of learning a foreign language as an adult [pp. 65-69] is as good as any I've read) provide additional insight into the life of a professor. I wish I'd had a teacher explain the craft of expository writing as elegantly as Allitt in his "standard speech" (p. 82). The sorry state of undergraduate prose is sketched in stark detail, with amusing howlers like, "Many did not survive the harsh journey west, but still they trekked on." Although an introductory class, students were a mix of all four undergraduate years; one doesn't get a sense the graduating seniors thought or wrote any more clearly than the freshmen. Along the way, Allitt provides a refresher course in the historical period covered by the class. You might enjoy answering the factual questions from the final examination on pp. 215-218 before and after reading the book and comparing your scores (answers are on p. 237--respect the honour code and don't peek!). The darker side of the educational scene is discussed candidly: plagiarism in the age of the Internet; clueless, lazy, and deceitful students; and the endless spiral of grade inflation. What grade would you give to students who, after a semester in an introductory undergraduate course, "have no aptitude for history, no appreciation for the connection between events, no sense of how a historical situation changes over time, [who] don't want to do the necessary hard work, . . . skimp on the reading, and can't write to save their lives" (p. 219)--certainly an F? Well, actually, no: "Most of them will get B- and a few really hard cases will come in with Cs". And, refuting the notion that high mean grade point averages at elite schools simply reflect the quality of the student body and their work, about a quarter of Allitt's class are these intellectual bottom feeders he so vividly evokes.

Posted at 22:44 Permalink

Friday, January 14, 2005

Reading List: Tom Swift and His Motor-Cycle

Appleton, Victor. Tom Swift and His Motor-Cycle. Bedford, MA: Applewood Books, [1910] 1992. ISBN 1-55709-175-7.
This is where it all began--the first episode of the original Tom Swift series. Here we encounter Tom, his father Barton Swift, Mrs. Baggert, Ned Newton, Eradicate Sampson and his mule Boomerang, Wakefield "bless my hatband" Damon, Happy Harry, and the rest of the regulars for the first time. In this first outing, Appleton is still finding his voice: a good deal of the narration occurs as Tom's thinking or talking out loud, and there are way too many references to Tom as "our hero" for the cynical modern reader. But it's a rip-snorting, thoroughly enjoyable yarn, and the best point of departure to explore the world of Tom Swift and American boyhood in the golden years before the tragically misnamed Great War. I read the electronic edition of this novel published in the Tom Swift and His Pocket Library collection at this site on my PalmOS PDA. I've posted an updated electronic edition which corrects a few typographical and formatting errors I noted whilst reading the novel.

Posted at 23:56 Permalink

The Internet Slum: Is the Exodus Beginning?

When I published The Internet Slum in May 2004, I subtitled it, "Is Abandoning the Internet 'The Next Big Thing'?". A column in today's Los Angeles Times, "No More Internet for Them" indicates this trend is becoming visible to big media. Several home computer users, including a 50 year old early adopter, are described as pulling the plug on their Internet connections due to the frustration, disgust, and sense of violation I described in The Internet Slum. Spyware and adware may be "the last straw" for many fed-up users. The article closes with the early PC adopter and early abandoner of the Internet describing his now-disconnected PC, "It's great for anything you can do on your own. It seems to me an incredible typewriter--and that's it." And this is truly sad.

Posted at 13:34 Permalink

Tuesday, January 11, 2005

Comet Machholz Captured with CCD

A couple of days ago I configured my venerable SBIG ST-6 CCD camera to work with a spare laptop in the hope of being able to image the tails of Comet Machholz (C/2004 Q2) which had eluded me so far both visually and photographically. The greyscale sensor in the ST-6 is limited in size (only 375×241 pixels), but cooled to a temperature of -40°C by a Peltier junction, has extremely high quantum efficiency and low noise compared to general purpose digital cameras. The next few nights were either clouded out or sufficiently murky so the Milky Way wasn't even visible, but on the night of January 11th the temperature dropped to about 0°C and the sky became reasonably, if not perfectly, transparent, so I decided to give it a go.

I used the same Nikon 50 mm f/1.4 lens with the CCD camera that I used for the pictures of the comet passing the Pleiades on the night of c2004q2_2005-01-11.jpg January 7-8, but stopped down to f/2.8 for better sharpness. After aiming the camera at the comet and the usual tedious focusing procedure (aided by recalling that with the lens adaptor for the CCD this lens is focused close to infinity when its focusing scale points to the decimal point in the "1.7 metre" mark), I experimented with exposures between 7 and 20 seconds and decided that 12 seconds was a reasonable compromise between integration time and minimising star trails on with the unguided tripod mount I was using.

The picture above is a 12 second exposure--the full CCD frame is shown. The image has been contrast stretched, but not otherwise processed. With the present geometry of the Sun, Earth, and comet, the ion tail (which extends toward the upper left in the image) and the stubby dust tail (toward the lower left) appear about 90° apart. The ion tail is entrained by the solar wind and acts like a weathervane pointing away from the Sun, while the dust tail follows the comet along its orbit.

c2004q2_2005-01-11i.jpg The human eye generally finds it easier to spot subtle differences in shade in images of dark objects against a white background. Consequently, astronomers often show extended objects as inverted (negative) images. Here's an inverted and contrast stretched version of the captured image above. It shows that the coma extends well beyond the obvious white blob in the positive image and enhances the extent of the ion tail. In this comet, the ion tail is longer and more prominent than the dust tail; this isn't always the case: in Hale-Bopp (C/1995 O1), the two tails were of about equal length and intensity.

With the ambient temperature around freezing, the camera cooler had a less than usually challenging task keeping the sensor at its operating temperature, but the primate pushing the buttons found it a chilly experience indeed standing still in the cold-dark watching for each exposure to complete, download, and display. Also, I discovered that when the ends of your fingertips start to freeze, they no longer operate the touchpad on the laptop. A workaround is to lick them, move the cursor to where you want it, then scrape the ice off the end of the finger. Or, undoubtedly wiser, use a mouse.

Posted at 23:53 Permalink

Reading List: Facing Up

Weinberg, Steven. Facing Up. Cambridge, MA: Harvard University Press, 2001. ISBN 0-674-01120-1.
This is a collection of non-technical essays written between 1985 and 2000 by Nobel Prize winning physicist Steven Weinberg. Many discuss the "science wars"--the assault by postmodern academics on the claim that modern science is discovering objective truth (well, duh), but many other topics are explored, including string theory, Zionism, Alan Sokal's hoax at the expense of the unwitting (and witless) editors of Social Text, Thomas Kuhn's views on scientific revolutions, science and religion, and the comparative analysis of utopias. Weinberg applies a few basic principles to most things he discusses--I counted six separate defences of reductionism in modern science, most couched in precisely the same terms. You may find this book more enjoyable a chapter at a time over an extended period rather than in one big cover-to-cover gulp.

Posted at 00:58 Permalink

Sunday, January 9, 2005

Reading List: CSS Cookbook

Schmitt, Christopher. CSS Cookbook. Sebastopol, CA: O'Reilly, 2004. ISBN 0-596-00576-8.
It's taken a while, but Cascading Style Sheets have finally begun to live up to their promise of separating content from presentation on the Web, allowing a consistent design, specified in a single place and easily modified, to be applied to large collections of documents, and permitting content to be rendered in different ways depending on the media and audience: one style for online reading, another for printed output, an austere presentation for handheld devices, large type for readers with impaired vision, and a text-only format tailored for screen reader programs used by the blind. This book provides an overview of CSS solutions for common Web design problems, with sample code and screen shots illustrating what can be accomplished. It doesn't purport to be a comprehensive reference--you'll want to have Eric Meyer's Cascading Style Sheets: The Definitive Guide at hand as you develop your own CSS solutions, but Schmitt's book is valuable in showing how common problems can be solved in ways which aren't obvious from reading the specification or a reference book. Particularly useful for the real-world Web designer are Schmitt's discussion of which CSS features work and don't work in various popular browsers and suggestions of work-arounds to maximise the cross-platform portability of pages.

Many of the examples in this book are more or less obvious, and embody techniques which folks who've rolled their own Movable Type style sheets will be familiar, but every chapter has one or more gems which caused this designer of minimalist Web pages to slap his forehead and exclaim, "I didn't know you could do that!" Chapter 9, which presents a collection of brutal hacks for working around browser incompatibilities, many involving exploiting parsing bugs, may induce nausea in those who cherish standards compliance or fret over the consequences of millions of pages on the Web containing ticking time bombs which will cause them to fall flat on their faces when various browser bugs are fixed. One glimpses here the business model of the Web site designer who gets paid when the customer is happy with how the site looks in Exploder and views remediation of incompatibilities down the road as a source of recurring revenue. Still, if you develop and maintain Web sites at the HTML level, there are many ideas here which can lead to more effective Web pages, and encourage you to dig deeper into the details of CSS.

Posted at 01:29 Permalink

Saturday, January 8, 2005

Entropic Storm: Zap a Laptop

It's hardly a news flash that it gets cold in Switzerland in the winter, especially at Fourmilab's altitude of 806 metres above mean sea level. When it's cold outside, relative humidity inside plunges, and static electricity manifests itself everywhere in irritating fat blue sparks whenever finger approaches metal. Humidifiers mitigate the effect, but you can't use them everywhere, and they don't help when you've been outside and just walked into a warm room, fully charged.

For the most part, this is a minor annoyance, but after I migrated my development work to a Dell Inspiron 9100 laptop a few months ago, it's been a matter of some concern because on three separate occasions so far I've entered the computer room from outside, touched the metal frame of the work table on which the computer sits (as I always to do discharge any static electricity before touching the computer keyboard or mouse), and had the laptop immediately power down without any soft shutdown of the operating system whatsoever.

Apparently this computer is unusually vulnerable to EMP discharges in its vicinity, so much so that simply discharging static electricity to the metal frame which supports the particle board table on which it sits is enough to make it turn itself off.

The Dell mains adaptor has a three prong grounded plug, and I verified with an ohmmeter that when it's plugged in, the chassis of the laptop is grounded to mains safety ground. Since the metal frame of the table wasn't grounded but was simply serving as a charge sink, perhaps it was acting as an antenna to deliver the electromagnetic punch to the guts of the Dell.

In any case, these static zap induced power downs are extremely irritating and risky to work in progress, so to attempt to avoid them I cobbled up this grounding strap to create a low impedance ground between the frame of the work table (which I always touch before touching the computer keyboard or mouse) and the chassis of the computer, via the safety ground of the UPS into which the laptop's power brick is plugged.

The ground wire is a sturdy solid copper conductor, soldered to the lug, which is fastened with a self-tapping 3.5 mm screw and lockwasher to a hole I bored in the table. The other end of the ground strap is connected to the safety ground terminal of the mains plug, the other two pins of which are unconnected. Steel is sturdy stuff! It took the better part of an hour, off and on, to bore a 3 mm hole through the frame of the table, which is only about 1 mm thick. A drill press would have made quick work of the job, but I don't have one and wouldn't want to tear down the table anyway, so I used a handheld drill instead. Yes, I powered down the computer so its hard drive wouldn't be spinning while I bored the hole in the table.

Does it work? Well, I don't know yet. I'm not about to deliberately charge myself up and try an experimental zap. I'm sure the inevitable inadvertent shocking event will put the gizmo to the test in the near future, and I'll let you know whether it worked when that happens.

Posted at 17:13 Permalink

Comet Machholz Passes the Pleiades


The weather was murky with occasional drizzle most of today, so I wasn't optimistic about spotting the passage of Comet Machholz (C/2004 Q2) past the Pleiades tonight, but a couple of hours after sunset the falling temperature forced the ground fog to a lower altitude and the sky was exquisitely transparent. The comet was an easy object for the unaided eye, about two degrees to the southwest of the Pleiades, and with 15 power 50 mm binoculars the inner coma and nucleus were visible and the overall green colour of the coma obvious. (The colour is due to cyanogen (CN) and diatomic carbon (C2) in the coma, both of which fluoresce in the green when illuminated by sunlight.)

After the rather disappointing results of my first attempt to photograph this comet on the morning of the fifth, I decided that with a comet this dim and no clock drive, aperture was king, so I mounted a thirty-year-old Nikkor 50 mm f/1.4 lens on the Nikon D70 digital SLR and made time exposures at f/1.4 with CCD sensitivity set to the equivalent of ISO 1600. The off-axis performance of this vintage lens at full aperture is execrable, so I was careful to centre the Pleiades and comet in the frame. The image above is cropped from the original and reduced by 50%, which almost conceals the small star trails visible in the full scale image.

Both the dust and ion tails of this comet are extremely subtle and I have neither spotted them visually nor picked up the slightest hint of them in a photograph.

Posted at 00:18 Permalink

Friday, January 7, 2005

Reading List: State of Fear

Crichton, Michael. State of Fear. New York: HarperCollins, 2004. ISBN 0-06-621413-0.
Ever since I read his 2003 Commonwealth Club speech, I've admired Michael Crichton's outspoken defence of rationality against the junk science, elitist politics, and immoral anti-human policies of present-day Big Environmentalism. In State of Fear, he enlists his talent as a techno-thriller writer in the cause, debunking the bogus fear-mongering of the political/legal/media/academic complex which is increasingly turning the United States into a nation of safety-obsessed sheeple, easily manipulated by the elite which constructs the fact-free virtual reality they inhabit. To the extent this book causes people to look behind the green curtain of environmentalism, it will no doubt do a world of good. Scientific integrity is something which matters a great deal to Crichton--when's the last time you read a thriller which included dozens of citations of peer-reviewed scientific papers, charts based on public domain climate data, a list of data sources for independent investigation, a twenty page annotated bibliography, and an explicit statement of the author's point of view on the issues discussed in the novel?

The story is a compelling page-turner, but like other recent Crichton efforts, requires somewhat more suspension of disbelief than I'm comfortable with. I don't disagree with the scientific message--I applaud it--but I found myself less than satisfied with how the thing worked as a thriller. As in Prey (January 2003), the characters often seemed to do things which simply weren't the way real people would actually behave. It is plausible that James Bond like secret agent John Kenner would entrust a raid on an eco-terrorist camp to a millionaire's administrative assistant and a lawyer who'd never fired a gun, or that he'd include these two, along with an actor who played a U.S. president on television, sent to spy for the bad guys, on an expedition to avert a horrific terrorist strike? These naïve, well-intentioned, but clueless characters provide convenient foils for Crichton's scientific arguments and come to deliciously appropriate ends, at least in one case, but all the time you can't help but thinking they're just story devices who don't really belong there. The villains' grand schemes also make this engineer's reality detector go bzzzt! In each case, they're trying to do something on an unprecedented scale, involving unconfirmed theories and huge uncertainties in real-world data, and counting on it working the very first time, with no prior prototyping or reduced-scale tests. In the real world, heroics wouldn't be necessary--you could just sit back and wait for something to go wrong, as it always does in such circumstances.

Posted at 00:49 Permalink

Thursday, January 6, 2005

Comet Machholz Approaches the Pleiades

When I arrived back in Switzerland early on the morning of Tuesday, 4th January 2005, the temperature was -4°C and the sky was that perfect dead-of-winter clear which invites amateur astronomers to venture into the dark regardless of the mercury or risk of losing the odd extremity to frostbite.

After hauling everything inside, I immediately hauled myself and the binoculars outside and quickly spotted Comet Machholz (C/2004 Q2), which I hadn't seen since December 26th. After locating the comet with binoculars, I found it a relatively easy object for the unaided eye, but that's an amateur astronomer with 40+ years of experience seeking faint smudges in the sky speaking. While the comet was easy to spot without averted vision, you had to know where to look and what to expect--this is no Hale-Bopp.

Having spotted the comet, I tried to photograph it with the Nikon D70 and 28-200mm zoom lens I use for general photography with this camera. The dimness of the comet was a serious challenge--even with the CCD sensitivity set to the equivalent of ISO 1600 (at the expense of sensor noise), a 10 second exposure at the maximum aperture of f/3.5 and shortest focal length of 28mm (equivalent to a 42mm moderate wide angle on a 35mm camera), about the longest which doesn't generate obvious star trails due to the pesky rotation of the Earth, only subtly showed the fuzzy coma which identified the object as a comet.

This image is the pick of the litter. It approximates the visual appearance of the comet, and the field of view of the unaided eye. Actually, the comet is less obvious but, once spotted, appears more extended than the compact fuzz-ball shown here. The peak of the roof of the house at left and the house at the right are illuminated by Fourmilab's Christmas lights.

Since I took this picture, nights have reverted to the usual fog, clouds, and precipitation, so I haven't had a chance to try other imaging options. If the sky is clear for the passage by the Pleiades on January 7-8, I may try imaging it with the SBIG ST-6 cooled CCD camera I used for comets Hyakutake and Hale-Bopp.

Posted at 01:16 Permalink

Wednesday, January 5, 2005

Entropic Storm: Palm/Hansdpring Treo "Radio Reset" and HotSync BSOD mitigation

The traditional end-of-year entropic storm was somewhat later than usual arriving at Fourmilab, but seems to be building up to its customary gale force intensity.

For the last few years, I've used Handspring (now acquired by Palm) Treo PalmOS organisers integrated with mobile phones--packing this gizmo lets me send and receive voice calls, SMS text messages, browse the Web, read and answer E-mail, run Palm applications, and read books from my pocket library wherever I happen to be.

These devices are superbly designed from the user interface standpoint, but the hardware doesn't always meet the same standard. My original Treo 180 died a month or so after it went out of warranty due to an open circuit in the flex cable which connects the speaker in the flip cover to the main circuit board. The first Treo 270 I bought to replace it was dead on arrival--not even the charge LED illuminated when it was connected to the mains adaptor and plugged in. The replacement I received upon sending that one back was also apparently dead when received but at least the charge light worked and I discovered that a hard reset (not a problem, since I hadn't the opportunity to load any data onto it) sufficed to resuscitate it.

Everything's gone more or less OK since then, until yesterday when the Treo became "sticky"--switching between screens, which usually takes a fraction of a second, took up to a minute, and attempting to turn wireless mode off and back on resulted in a hang in the "Network Search..." mode before the search dialogue box displayed.

As it turns out, this is a known problem. and there's a Palm application to "fix" it, Radio Reset. Apparently, the GSM radio subsystem in the Treo can hang, and needst be "reset" in order to put things back on track. This reset is accomplished by the elegant expedient of completely discharging the battery until everything dies (which causes loss of all PDA data just like a hard reset), then recharging and powering back on, after which one hopes the radio will have recovered from its funk. All the Radio Reset application does is circumvent the automatic power-off in order to run down the battery, which takes about two hours if it's fully charged to begin with.

Now, allowing the battery to run down to the last gasping electron means you're going to lose all the memory on the Treo, but that's nothing to worry about if you use BackupBuddy, which will restore all your applications and settings to the status quo ante the last HotSync. Before running Radio Reset, I wanted to HotSync to make sure I'd backed up any changes since the last time, whereupon I discovered that HotSync had ceased to work--HotSync Manager was running and configured as usual, but the HotSync never connected and timed out. After the usual flailing around (killing and restarting HotSync Manager, rebooting Windows XP, re-installing Palm Desktop, etc., etc.), just when I was about to conclude the HotSync failure was related to the radio hang-up in some bizarre fashion, I happened to plug a backup HotSync cable (from the dead Treo 180) I was experimenting with into a four port USB hub instead of the direct USB connection I usually use, and when I pressed the HotSync button, hey presto, Windows XP "detected new hardware", went through the usual rigamarole installing the Palm USB driver, whereupon HotSync worked fine. Naturally, I then tried moving the USB cable back to the original USB port--no go--beats me; the hub port continued to work correctly.

With the PDA files backed up, I then went ahead and launched Radio Reset to run down the battery and went off to do other things while that thrilling process was underway. Once the PDA was well and truly black-screen dead, I put it into the cradle and allowed it to fully recharge, which took another couple of hours. Then, after going through the full resurrection reset process (calibrate the touch screen, choose the language, find the "Z" key on the keyboard, etc.), I turned on the GSM radio, which promptly found the Swisscom SWISS GSM network I use and connected, indicating GPRS service available.

Now it was simply a matter of restoring all the data on the PDA. Booting back into Windows XP (since I'd been running Linux in the interest of doing productive work while the battery discharged and recharged), and with the HotSync cable still plugged into the USB hub, I pressed the button, and HotSync began to restore all the data onto the handheld . . . for about a minute . . . after which Windows XP crashed with a Blue Screen of Death (BSOD) fingering the Palm USB driver as the culprit and requiring a full power down (the "three finger salute": CTRL-ALT-DEL, was ineffective, and judging from the fan on the Dell Inspiron 9100, the CPU was in a compute loop).

After rebooting, I tried the HotSync again--BSOD--reboot--and again: same thing. The crash didn't always happen at the same point in the HotSync, but it never got more than five minutes into the recovery before going blooie. I tried disabling BackupBuddy (which shouldn't be in the loop at this point in a HotSync recovery, but you never know), and the crash persisted.

At this point I moseyed over to Google in search of lore regarding HotSync BSODs, and eventually came across this flabbergasting PalmOne support document which reveals that HotSync Manager is incompatible with Intel CPUs which employ Hyper-Threading technology and with symmetric multi-processor systems in general! The only way to reliably run HotSync on such systems is to launch HotSync Manager, then pop up the Windows Task Manager (appropriately, with CTRL-ALT-DEL!), select the "Processes" tab, right click the HOTSYNC.EXE item and select "Set Affinity" whereupon a dialogue box appears which allows you to restrict the process to a subset of CPUs. Check just one CPU (I chose logical CPU 0), which will force HotSync Manager to run only on that CPU, after which the HotSync will run to completion, sans BSOD.

Setting the Processor Affinity ("CPU dedication" to EXEC-8 old-timers) does not persist across multiple program executions--it affects only the running process. If you kill and restart HotSync Manager or reboot, you'll need to reset the Processor Affinity every time. Note that this is terribly inconvenient if you've configured HotSync Manager to run only when Palm Desktop is running, since each time you launch the desktop application, you need to reset the processor affinity for HOTSYNC.EXE. I am unaware of any way to set the processor affinity for an executable file so it always runs on a given CPU, or to specify affinity on the command line, which would permit invoking HotSync Manager with a shortcut with such a specification.

As somebody who's been writing multi-threaded programs for multiprocessor systems for more than thirty years, I gotta tell you that screwing up something as simple-minded as a USB kernel driver so it doesn't work on multiple CPU systems is something of an accomplishment. Further, here is Palm, pioneer and erstwhile leader in the handheld computing market, shipping a product to all of their customers which crashes the operating system with the largest global market share, when performing a routine operation on top-end Intel microprocessor (Pentium 4 with Hyper-Threading) systems. And rather than rushing out a patch for this horrific problem, they bury the information in a support library document, offering only the lamest, user-hostile, and inconvenient of work-arounds.

If you have a Palm and have been HotSyncing it to a Windows XP system with Hyper-Threading or multiple CPUs without crashes, you've been lucky so far. Many routine HotSyncs complete quickly enough to dodge the bullet, but a full backup or restore is almost certain to provoke the problem. (I'd suffered this crash a couple of times before, but since it didn't repeat, I assumed it was "just one of those things").

And HotSync still only works with the cable plugged into the USB hub.

Posted at 00:34 Permalink

Sunday, January 2, 2005

Reading List: La grammaire est une chanson douce

Orsenna, Erik. La grammaire est une chanson douce. Paris: Poche, 2001. ISBN 2-253-14910-1.
Ten year old Jeanne and her insufferable fourteen year old brother survive a shipwreck and find themselves on an enchanted island where words come alive and grammar escapes the rationalistic prison of Madame Jargonos and her Cartesian colleagues in the black helicopters (nice touch, that) to emerge as the intuitive music of thought and expression. As Jeanne recovers her ability to speak, we discover the joy of forging phrases from the raw material of living words with the tools of grammar. The result of Jeanne's day in the factory on page 129 is a pure delight. The author is a member of l'Académie française.

Posted at 22:37 Permalink

Saturday, January 1, 2005

Reading List: The Rise of the Indian Rope Trick

Lamont, Peter. The Rise of the Indian Rope Trick. New York: Thunder's Mouth Press, 2004. ISBN 1-56025-661-3.
Charmed by a mysterious swami, the end of a rope rises up of its own accord high into the air. A small boy climbs the rope and, upon reaching the top, vanishes. The Indian rope trick: ancient enigma of the subcontinent or 1890 invention by a Chicago newspaper embroiled in a circulation war? Peter Lamont, magician and researcher at the University of Edinburgh, traces the origin and growth of this pervasive legend. Along the way we encounter a cast of characters including Marco Polo; a Chief of the U.S. Secret Service; Madame Blavatsky; Charles Dickens; Colonel Stodare, an Englishman who impersonated a Frenchman performing Indian magic; William H. Seward, Lincoln's Secretary of State; Professor Belzibub; General Earl Haig and his aptly named aide-de-camp, Sergeant Secrett; John Nevil Maskelyne, conjurer, debunker of spiritualism, and inventor of the pay toilet; and a host of others. The author's style is occasionally too clever for its own good, but this is a popular book about the Indian rope trick, not a quantum field theory text after all, so what the heck. I read the U.K. edition.

Posted at 15:33 Permalink