GithubHelp home page GithubHelp logo

Comments (3)

pclausen avatar pclausen commented on July 17, 2024 3

Learning Fortran

I think that very few people since the 1990’s have learned Fortran because they felt curious or fascinated by this very old language. Instead, Fortran is a very common tool to solve numerical problems. Many robust and tested solutions are written in Fortran and many are still in production today and in many years to come.
I think there are two ways to Fortran; the scientific or as a software developer.
Many scientific communities have been using Fortran for many decades for solving numerical problems. Therefore, people as myself with a scientific or engineering background, typically learn Fortran in masters or PhD programs. Another way to Fortran is to be hired in an organization (like mine, Dassault Systèmes www.3ds.com) where many numerical algorithms are in Fortran and they continue to be developed in Fortran.

How was your experience learning Fortran?

I learned a bit of Fortran during my mechanical engineering studies as part of a finite element course where the main part of the program was prepared in Fortran and our assignment was to add critical parts, eg. the finite element formulation. But mainly as I started working full time on structural optimization full time in 2005.

What was helpful while learning Fortran?

Fortran was one of my first software languages after learning Basic and Pascal in my youth and Matlab in my studies. Fortran (FORmula TRANslator) is really good for writing numerical routines and not having object orientation kind of helped me, because I feel object oriented programs confuses me (any many other non-software folks, e.g scientists) more in the beginning than they helped.

What did you struggle with?

Anything else than numerics is a pain in Fortran. File io, graphics, structuring code is often much better in almost any other languages. Therefore, many codes have C/C++ or Python wrappers around Fortran to avoid parts of this pain.

How did you tackle problems?

I did not tackle these problems - other people in my organisation mainly did.

In what ways did Fortran differ from other languages you knew at the time?

Fortran is procedural like Pascal and Basic so that part felt easy at the time. Fortran is fairly easy to learn, because it is fairly limited and most Fortran programmers are generally conservative and not using too many new language features, even though Fortran has developed over the 60 years it has been in use.

What was hard to learn?

The Fortran90 modules takes some getting used to. Also very old Fortran77 code can be difficult to read and will have memory saving constructs like equivalence, implicit variables and too many goto’s. If the code is still being actively maintained and modified I think removing these constructs is often worth the hassle but it is a risk and YMMW.

What did you have to unlearn?

Nothing really. One index may be an issue of you come from Java, C/C++ or python.

What syntax did you have to remap?

Fortran syntax is fairly limited compared to other languages

What concepts carried over nicely?

The best thing in Fortran90 is array operations, an essential component of numerics.
A(:,:) = B(:,:) + C(:,:)
Which is similar in Python and Matlab.

from fortran.

booniepepper avatar booniepepper commented on July 17, 2024

Learning Fortran

For what it's worth, I learned Fortran out of curiosity. I haven't met anyone else that has done that, though. I'll second that the big developer community I've seen is related to scientific computing. I've also seen some specific applications in data science (ML, AI, Business Intelligence) where Fortran is a better choice than C when implementing certain low level calculations.

What did you have to unlearn

Variables being scoped to a call stack instance of a function. (i.e. general recursion)

from fortran.

ErikSchierboom avatar ErikSchierboom commented on July 17, 2024

We're closing this issue as it was part of our research for the v3 version of Exercism which has just been released.

Thanks everyone for chipping in! It has been greatly appreciated.

from fortran.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.