Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!elroy.jpl.nasa.gov!jato!vsnyder From: vsnyder@jato.jpl.nasa.gov (Van Snyder) Newsgroups: comp.lang.fortran Subject: Re: FORTRAN vs. "PC languages" Message-ID: <1991May29.205700.27104@jato.jpl.nasa.gov> Date: 29 May 91 20:57:00 GMT References: <31746@rouge.usl.edu> Reply-To: vsnyder@jato.Jpl.Nasa.Gov (Van Snyder) Distribution: usa Organization: Jet Propulsion Laboratory, Pasadena, CA Lines: 57 In article <31746@rouge.usl.edu> ldl6737@rouge.usl.edu (Lafleur L Dwynn) writes: >Most of us physicists, mathematicians, and engineers educated in the '60s and >'70s cut our programming teeth on mainframe computers using FORTRAN. Many have >since moved from mainframes to personal computers and have found that there are >other languages much more convenient for the PC platform, especially those which >come packaged in a friendly, efficient programming environment (e.g., QuickBASIC >or Turbo Pascal). Also, manufacturers of circuit boards that interface PCs to >laboratory instrumentation (e.g., the Hewlett-Packard HPIB interface card) tend >to write the interface software in these newer "PC languages", but not in >FORTRAN. Some schools of engineering are, in fact, replacing FORTRAN with >others as the language of choice. > >Now, I for one find it very difficult to program almost daily in two different >languages. Maybe that's a sign of age, but I suspect most scientists would >prefer to stick to just one language if they could. Putting aside the question >of the effort involved, why don't most of us leave FORTRAN for one of the newer >languages? In discussions with others, I seem to find two primary reasons for >sticking to FORTRAN: (1) there exists a large stockpile of numerical subroutines >and packages written over the decades, and (2) many of us do computation >involving expressions with lots of operations on and functions of complex >variables, a variable type not allowed in binary operations in such languages as >BASIC, Pascal, and C. > >If you are a big user of existing FORTRAN software packages, the first of these >reasons is sufficient for staying with FORTRAN and the question is decided. >However, the second reason is beginning to erode. The recent appearance of C++ >and other object oriented languages gives the programmer the use of complex >operations with the almost the same ease as in FORTRAN. In fact, I understand >the rather popular Turbo C++ includes a library defining essentially all the >complex operations and functions appearing in FORTRAN. > >I am posting this message to stimulate an exchange of opinions between FORTRAN >users about the advisability and experiences of switching to other languages. >What do you think? > > >L. Dwynn Lafleur >Professor of Physics >University of Southwestern Louisiana >lafleur@usl.edu When the Fortran 77 standard was promulgated, Fortran was the only standardized and widely available language that got arrays right. Pascal still doesn't allow open arrays. Modula-2 allows open arrays of one dimension. PL\I and Ada aren't widely available. Arrays in C are a bogus pointer manipulation that has a few quirks that make arrays not quite right. Fortran 90 improves on Fortran 77 arrays by making whole arrays and array sections first class objects. And now machine inquiry is standardized as well. There are lots of things in Fortran 90 that I would have done differently (mostly more regularly), but on the whole, nothing compares yet for numerical work. -- vsnyder@jato.Jpl.Nasa.Gov ames!elroy!jato!vsnyder vsnyder@jato.uucp