Tag: Fortran

Fortran CSV Module

The lowly CSV (comma-separated values) file never gets any respect. Sure, it isn’t really standardized, but it is a very useful text file format for columns of data, and is frequently encountered in science/engineering fields. Of course, there is no good

Posted in Programming Tagged with: , ,

Multidimensional Linear Interpolation (Part 2)

In an earlier post, I mentioned that we needed an object-oriented modern Fortran library for multidimensional linear interpolation. Well, here it is. I call it finterp, and it is available on GitHub. It can be used for 1D-6D interpolation/extrapolation of data on a regular

Posted in Algorithms Tagged with: , ,

Numerical Differentiation

I present the initial release of a new modern Fortran library for computing Jacobian matrices using numerical differentiation. It is called NumDiff and is available on GitHub. The Jacobian is the matrix of partial derivatives of a set of \(m\) functions

Posted in Algorithms Tagged with: , , , ,

GOTO Still Considered Harmful

For a number of years I have been familiar with the observation that the quality of programmers is a decreasing function of the density of go to statements in the programs they produce. — Edsger W. Dijkstra One of the classics

Posted in Programming Tagged with: ,

Fortran at 60

Today marks the 60th anniversary of the release of the original Fortran Programmer’s Reference Manual. Fortran was the world’s first high-level computer programming language, was developed beginning in 1953 at IBM by a team lead by John Backus. The first compiler was

Posted in Programming Tagged with:

Computing Pi

The digits of can be computed using the “Spigot algorithm” [1-2]. The interesting thing about this algorithm is that it doesn’t use any floating point computations, only integers. A Fortran version of the algorithm is given below (a translation of the Pascal program

Posted in Algorithms Tagged with: , ,

Backward Compatibility

“Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away.” — Antoine de Saint-Exupéry The Fortran standards committee generally refuses to break backward compatibility when Fortran is updated. This is a good

Posted in Programming Tagged with:

Syntax Highlighting

Decently syntax highlighted Fortran code on the internet is hard to come by. None of the major sites where people are likely to visit to learn about Fortran have it: The Google Groups hosting of comp.lang.fortran (I don’t really expect much from

Posted in Programming Tagged with:

Intel Fortran Compiler 17.0

Intel has announced the availability of version 17.0 of the Intel Fortran Compiler (part of Intel Parallel Studio XE 2017).  Slowly but surely, the compiler is approaching full support for the current Fortran 2008 standard. New Fortran 2008 features added in this release are: TYPE(intrinsic-type) Pointer initialization

Posted in Programming Tagged with: ,

JSON-Fortran 5.1

JSON-Fortran 5.1 is out. There are several new features in this release. I added a get_path() routine that can be used to return the path of a variable in a JSON structure. This can be used along with the traverse() routine

Posted in Programming Tagged with: , ,