Introduction/Motivation for a Fortran Lecture and History of FORTRAN

Hi everyone,

I’m currently designing a structure for the Fortran lecture I will give end of February.
I think I should start with some general information about Fortran and its history.
But of course, this should be as interesting and motivating as possible.

Therefore, I’m asking for tips in general.
But I also have a specific question:
Since I’m relatively new to Fortran compared to its long history, it would be very kind if some of our much more experienced community members could check if this is correct:

  • 1950s developed by IBM
  • 1957 1st FORTRAN compiler (had only arithmetic if)
  • 1958 FORTRAN II introduces functions/subroutines
  • 1962 FORTRAN IV logical data type and if
  • 1966 FORTRAN 66 became first industry standard (American Standard Fortran)
  • 1978 FORTRAN 77 character strings
  • 1992 Fortran 90 with many innovations (14 years of catching up): Free Form, array arithmetic, modules, dynamic arrays, pointers etc.
  • 2004 Fortran 2003 introduces object orientation
  • 2010 Fortran 2008 Coarrays, submodules
  • 2018 Fortran 2018 improved interoperability with C and parallel features

As you can see, I don’t want to go into too much detail. I intend to show how a programming language was developed over a period from punch cards to today’s modern features.

To make this history session more exciting, I want to add code snippets of some versions and breakthroughs achieved with Fortran/FORTRAN to this timeline.
Could you please provide me with some guidance?

5 Likes

Concerning the first two dates

  • In December 1953, Backus wrote a letter to his superior Cuthbert Hurd proposing the FORTRAN project for the IBM 704. The project starts in 1954.
  • The FORTRAN compiler is deployed in April 1957 on the IBM 704s.

A good book : Abstracting Away the Machine: The History of the FORTRAN Programming Language (2019) by Mark Jones Lorenzo. It contains chapters about the early FORTRAN instructions set. I will look into it when I am back home, and tell you if there are some code snippets.

3 Likes

Yes, there are code snippets, especially in Chapter 12 (for the IBM 704), Chapter 19 “The Need for Some Standards”, Chapter 22, 23, 24.

Some papers with code snippets, especially the first one:

And Programmer's Primer for FORTRAN Automatic Coding System for the IBM 704 | 102665486 | Computer History Museum

For modern standards, there are John Reid’s papers like:
Reid, John. « The New Features of Fortran 2003 », https://wg5-fortran.org/N1601-N1650/N1648.pdf

4 Likes

You could mention that Fortran 90 introduced derived types and argument intents.

Fortran 95 allowed for user-defined procedures to be designated pure or elemental and a TR of Fortran 95 expanded where allocatable arrays could be used (for example as components of a derived type).

1 Like

Prior to F77, most users relied on hardware manufacturers to define the extended FORTRAN language, leading to calls for a general standard to improve portability. All manufacturers provided user demanded extensions to the F66 standard. DEC extensions provided a reference for most other vendors but many took different paths, eg ENCODE / DECODE

Fortran 77 was the first generally accepted Fortran Standard.
Significant new features in F77 included:
Characters
IF THEN - ELSE - END IF
Standardised I/O
Generic intrinsic functions

But F77 did not include:
the INCLUDE statement,
identifiers longer than 6 characters,
support for dynamic memory allocation ( automatic or allocatable arrays ) or
IMPLICIT NONE,
All of which were keenly requested prior to F77’s final release in 1978.

It is difficult to remember the challenges that no dynamic memory features provided, but this did lead to the then required “F77 wrapper” coding approach.

F90/F95 was a watershed that allowed changes, enabling more modern Fortran coding approaches, but these came with a “bloated” declaration approach.

The INCLUDE statement and IMPLICIT NONE were in MIL-STD-1753, together with some other useful features that the US Department of Defense wanted as additions to F77 . Many F77 compilers implemented them.

@Carltoffel ,

I would strongly suggest bringing up the history of Fortran only toward the very end of your class as “fun facts” to close out the training.

Starting out your introduction with modern Fortran forcefully as a scalable parallel programming, array-oriented language with focus on scientific and technical computing with strong support for object-oriented and functional programming and portable and modular and structured code design with strong-typing can really captivate your audience.

You can kick off with an example like in this thread: it’s a parallel program using coarrays and as stated in the thread, it packs a lot. Then teach each of the aspects from the latest standard - it’s great that you can now employ something like Intel oneAPI to illustrate all of Fortran 2018 facilities.

Honestly the history no longer matters as much as a game of trivia you might play with your students at the end.

Fortran is entirely modern, as a programming language it can allow modern coding paradigms that most scientists and engineers at any level still fail to grasp fully in any of the other languages they have dabbled with, regardless of their claims. But when they see it in action in Fortran, it can truly be an A ha moment even if they don’t admit as such.

The history of FORTRAN is mostly irrelevant relative to how much can be accomplished with modern Fortran now towards computational science and all the possibilities with it gazing into the future.

It is common for books and training materials and courses to bring up the history and legacy of Fortran right up front or soon thereafter. I advise doing away with that approach.

9 Likes

I think you might be partly right, @FortranFan

I will not start with the history right off, but I intend to give a short overview in the first lesson because the long history is essential for Fortran. Without this history, things like “implicit none/save” sound like a bad idea for a modern language.
What I want to show with the history is that Fortran started as a calculator with benefits (kind of) which evolved into a feature rich programming language. I don’t want to go into too much detail, the whole history part should not take more than 3–5 minutes.
Based on your feedback, I will move the history part behind the comparison.
The content of the first lesson:

  1. What is Fortran (overview, paradigm/typing, application area)
  2. Comparison with other languages the students previously learned (including strengths, weaknesses, example code)
  3. Short History
  4. Introduction to scientific applications (simulations, numerical/data analysis)
  5. Installing compiler and fpm
  6. Hello World!

I plan to make the theoretical part as short as possible. Btw, from the second lesson on, all lessons will be much more practical: l will present the students one or two slides like “this is an if, this is your task, have fun!”.

1 Like

Teaching how you should do it now is the most important and I agree the history should be brief, but it is very pertinent to anyone that is dealing with older code. It explains why there are a lot of deprecated features combined with the fact that Fortran is famously backward compatible. There are several guides on the equivalences between older methods and modern stratagems. Including those (such as on the Fortran Wiki for starters) may be very important depending on the audience and whether they will be dealing with older code. The history is interesting of itself, but often you have to deal with that history directly. It is very much “living history”. I think what needs covered varies based on whether the audience is new to Fortran and working with new code; are currently programming in Fortran but want to modernize their approach; or are new but at least initially working with legacy code.

2 Likes

Thanks again for all your comments. You all helped me a lot to finish this chapter.
I think I don’t have enough time for preparing a more detailed history lesson, and I’m afraid it wouldn’t be as interesting for the students as it is for me. I will come back to the idea later. For now, it will be a brief timeline and nothing more.

1 Like

For a brief history you might like to consult “The Seven Ages of Fortran” at View of The seven ages of Fortran (unlp.edu.ar)

Mike Metcalf

3 Likes