Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucsd!usc!chaph.usc.edu!aludra.usc.edu From: ajayshah@aludra.usc.edu (Ajay Shah) Newsgroups: comp.lang.fortran Subject: Fortran (LONG, you may think it's religious.) Message-ID: <11053@chaph.usc.edu> Date: 27 Jul 90 05:38:22 GMT Sender: news@chaph.usc.edu Organization: University of Southern California, Los Angeles, CA Lines: 95 Nntp-Posting-Host: aludra.usc.edu (LONG!) I saw a huge number of postings citing one or the other reason given which Fortran is the best computing solution around. I'll describe one experience here.. see what you think of it. I started life writing fortran since the first course in programming at school (IIT, Bombay, India) taught fortran-77. They had a great home-made compiler (gee, how I loved it) which did things like trap uninitialised variables and scream about wrong number or type of parameters, so it was a great place to start off programming. I fell in love with computers at first sight; and wrote something like 10k lines of fortran within those three months. You can say I know fortran intimately. I learned pascal that december (fortran was the fall semester), because everybody I knew who'd tried pascal had never come back, and got hooked on serious data structures. Later, of course, with turbo pascal, there was no turning back; it was not just the superiority of language but also the lovely environment. Last year, I joined the RAND corporation where my research group lives on large-scale maximum likelihood. On all three relevant fronts: size of datasets, dimensions of parameter vector and complexity of likelihood function, our work is cutting edge. Before I arrived, every single job was done with a monolithic fortran program. FACT 1: Just for kix, I wrote a maximum likelihood package one night in Turbo Pascal. It took a week to make it totally slick. My program is far more comfortable to use than the fortran programs used at RAND, and does more in terms of statistical computations supported. I used the Turbo Numerical Methods toolbox; it had all the basic routines I needed, I only had to write a few routines related to the normal distribution by hand where I hand-translated public- domain ratfor code. I might be brilliant, but writing this in a week was tremendous. I don't know of any experience where writing a full MLE system in fortran has not taken a few months atleast, this has to do (in a deep sense) with the clumsy data structures and abstraction supported by fortran. The fortran system is around 10k lines, the pascal is 3k lines. I don't think these numbers are easily shrugged off. A lot of people doing scientific programming live in a daze where mainstream computer science is for every other kind of programming in the world; *they* only need to write fortran programs without intelligence in data structures, etc. I think that attitude is a sad mistake. Personally, I've found tremendous gains in complexity control through "smart" data structures" in every single program i've written. FACT 2: In the work I've done at RAND ever since, while I've not been able to get my group off fortran, I've transformed the character of computing with fortran using Unix tools. I recently wrote a simulator where dynamic programming problems are solved. The traditional fortran programer would have written one monolithic program which did the simulations, with some lousy interface. Instead, I have a solution involving a 150 line cshell script, 2 awk programs, one 100 lines and the other 50 lines, one fortran program of 300 lines. The first awk program parses a very convenient input file and generates a cshell script whose output is converted by the 2nd awk program into a gnuplot script. My grouse with the "fortran-style-programmer" lies in the way he takes fortran to be the black-box solution to every computing problem. There is something so myopic there, it really gets me irritated talking with such a specimen. Instead of thinking in terms of a huge space of possibilities where fortran programs are one (pretty limited) option, there is the mentality of approaching everything as a fortran program. -- _______________________________________________________________________________ Ajay Shah, (213)747-9991, ajayshah@usc.edu The more things change, the more they stay insane. _______________________________________________________________________________ _______________________________________________________________________________ Ajay Shah, (213)747-9991, ajayshah@usc.edu The more things change, the more they stay insane. _______________________________________________________________________________