HOWTO: Batch Download a Book in PDF Pages from NetLibrary

NetLibrary is an online book resources that universities or other individuals pay to supply them with virtual copies of books. These books are available online, and can be searched, downloaded, and saved. The catch is that NetLibrary’s interface limits you to viewing (in horribly slow Acrobat reader) one page at a time. Given how unresponsive Acrobat makes many computers, this can make printing out a long book take hours.

Therefore, I took the effort to figure out how to batch download a book from NetLibrary, saving me valuable time.

My solution uses a combination of Firefox and Perl, but other solutions are of course available.

After I loaded up the first true page of the book in the NetLibrary interface, I gave the frame with the PDF its own Window used Firefox’s Tools | Page Info | Media properties dialog box to determine the URL of the embedded PDF file. It turns out it’s a call to a program named nlReader.dll, but it takes a book identification number and page number as arguments:

http://0-www.netlibrary.com.library.unl.edu/nlreader/nlReader.dll?BookID=BOOKIDGOESHERE&FileName=FILENAMEGOESHERE

Obviously, the library.unl.edu part requires my university proxy. For normal pages, the filename was in the format of Page_1.pdf, Page_2.pdf, etc. So I wrote a perlscript to create hyperlinks to pages 1 to 499, saved the output to HTML, used the DownloadThemAll! Firefox extention to get them, and…

Then Acrobat crashed trying to print out those hundreds of PDFs. Boo! Fortunately, Perl came to my rescue… I used ppm to install the module Perl::Reuse, then wrote a script to append all those pdfs into one. The final product is about 500 pages ans 70 megs, but quite easy to store, print out, etc.

Thanks, NetLibrary!

Working Memory and Orientation

Three articles this week on working memory.

Three articles today: “Am Embedded-Processes Model of Working Memory” by Nelson Cowan, “Working Memory: The Multiple-Component Model” by Alan D. Baddeley and Robert H. Logie, and “Modeling Working Memory in a Unified Architecture: The ACT-R Perspective” by Marsha C. Lovett, Lynne M. Reder, and Christian Lebiere.

The ACT-R paper (Lovett, et al) is not very relevent to what I am doing. It continues the attempt to apply literal information processing theory to human thinking, in the tradition of George Willer and nowadays of John Robert Anderson. ACT-R, like the other theories, is perhaps better for building a computer that works in ways analogous to the brain rather than understanding the brain itself.

The Baddeley piece was assigned to set the stage for the episode buffer, which he covered in his Nature Reviews Neuroscience article I read a bit ago. So: an OK article, but recognized by everyone (including Baddeley) as out of date.

What was really exciting was Nelson’s Cowan “embedded” working memory model, which is actually a dual processing model. Excitingly, it appears to date from the same time as Boyd’s final presentation, and even includes orientation! An excerpt:

THe focus of attention is controlled conjointly by voluntary processes (a central executive system) and involuntary processes) the attentional orienting system.)

All of this is exciting to read this morning, especially as this afternoon I present the OODA loop as a “Dual-Processing Theory of Learning” to some colleagues today. Talk about neat!

Review of "A Farewell to Alms" by Gregory Clark

Greg Clark‘s book could easily be called “In Inquiry into the Nature, Causes, and Effects of the Industrial Revolution.” But that’s a boring title, unfit for the world-altering subject matter. So instead the book’s titled A Farewell to Alms, which sounds like the title of an adventure story — which of course, it is.


A Brief Economic History of the World

A Farewell to Alms focuses on three questions: What caused the Industrial Revolution? What were the Industrial Revolution’s positive outcomes? And what were the bad effects of the Industrial Revolution? Answers to these questions follow below.

1. What caused the Industrial Revolution

Clark’s analysis is generally limited to the past 800 years, though on occasion he reaches back as far as the roman Empire. Thus, causes that preceded the Christian era are not addressed. Books such as Before the Dawn or potentially Guns, Germs, and Steel better serve to lay the deep-foundations for why some places have more advanced civilization than others.

Thus, A Farewell to Alms focuses on comparing Europe, China, and Japan. In the centuries preceding the Industrial Revolution both the European states and the Chinese empire experienced territorial growth, through the use of navies to settle distant colonies or the settling of agricultural lands by Han under the late Ming and the Qing. Technologies improvements allowed Japan to outpace Europe during this time, in spite of being confined to a few islands.

Period England Japan China
ca. 1300 5.9 million 6 million 72 million
ca. 1750 6.2 million 31 million 270 million

Table 13.1, pg 267

Clark argues that by about the time of the American Revolution, an Industrial Revolution was inevitable in all three cultures. Europe, China, and Japan were all undergoing population growth limited by starvation. This meant that there was constant downward selection, meaning that even if here was no variation in thrift, prudence, and other virtuous traits at the beginning, these traits would be selected over time. (Clark does not go into the genetics, but these traits are highly heritable).


Higher European birthrates, according to Clark, just made this process faster in the West than the East.

Using literacy rates and interest rates, Farewell argues that China and Japan were on the same path towards industry, but were a few centuries behind.

2. What good came of the industrial Revolution

The first casualty of the Industrial Revolution was the landed class. Agriculture rent as a portion of gross domestic product has plummeted throughout the west. While this started before the Industrial Revolution, and in deed may be a cause of it, return on capital and return on skills also fell in this period.

There has never been time to be a propertyless worker with minimum marketable skills than right now, at least in the industrialized world.

Similarly, Industrialization led to massive building subsidies in much of the world. India benefited, for instance, from Western technology, capital, infrastructure, telecommunications, and management in spite of having a workforce much less efficient than Europe’s. Similarly, most of the benefits of the industrial production of England at the start of the revolution went to industrialized countries — such as the Netherlands and the United States — and the customers of the factories, rather than the Industrial Magnates.

Over the long run, economic growth has been a major force for lessening inequalities in the industrialized world since the Industrial Revolution.

3. What were the bad effects of the Industrial Revolution?

Some countries have been harmed by the Industrial Revolution. Clark emphasizes here the misery of some states in sub-Saharan Africa. For them, the major consequence of the Industrial Revolution is that modern medicine low allows people to be kept alive at a lower level of subsistence than was fomerly the case. Drugs, in other words, substitute for calories.

A Farewell to Alms is written at a level appropriate for an introductory, graduate-level seminar outside of economics. The book is denser than most, similar to The Blank Slate in its density of coverage. still, it’s not an economic ext, and the “technical appendix” doesn’t go much beyond algebra.

Also at tdaxp: Why no Industrial Counter-Revolution?