Content area
Full text
It's one of the most heavily hyped buzz words in computerdom these days. And it's one of the goofiest-sounding acronyms around. But OOP--object-oriented programming--has made Peter Lepage a believer anyway.
A longtime veteran of computer simulations, the Cornell University physicist has abandoned the lingua franca of scientific computing, Fortran, in favor of using OOP techniques for every program he writes--the most recent being a large-scale simulation of quarks bound together by the forces of quantum chromodynamics. Now, he says, he and his colleagues are finding that the grungy, tedious process of writing their simulation code has turned into something that's almost--fun. "It's a hard thing to quantify," he says, but OOP "allows me to write programs that are much more sophisticated than before, that are easier to debug, and that are infinitely more adaptable."
Lepage is part of a vanguard of researchers who are beginning to explore a different and--they think--better way of instructing their computers how to compute. Conventional languages such as Fortran or C may be fine for short programs, they say. But the rapidly increasing power and sophistication of today's scientific programs is beginning to make those languages look like vacuum tubes in the age of silicon: They can do the job in principle, but they can't really cope with the complexity. "We still have this mental model of an individual scientist or graduate student writing a few hundred lines of code," says astronomer William Press of the Harvard-Smithsonian Observatory, co-author of a popular handbook of numerical algorithms for scientific computing. "Yet a big simulation in hydrodynamics or quantum chromodynamics can easily run to tens of thousands of lines. The sheer effort of programming is becoming insurmountable."
OOP seems to offer a way out. It isn't just a language for programming, notes Press. It's a philosophy of programming that's been incorporated into many different languages, including such current favorites as Smalltalk and C++. It starts from the notion that computer code ought to be carved up into "objects" that behave like the real-world objects they represent. And from there it goes on to promise big benefits in the form of computer code that's far easier to understand, far easier to write, far easier to debug, and far easier to reuse for new...





