![]() ![]() stdlib : an implementation of a standard library for Fortran as the language does not have one.FLAP : a command line argument parser.There are some very interesting libraries to help write decent, modern, compact programs. Dependencies can be pulled directly from Git remotes, it’s possible to work with tags and branches. This eliminates the need to maintain tedious Makefiles for linking complex programs. FPM is modeled after Rust’s cargo, and it is written in Fortran itself. ![]() The Fortran community built and maintains a tool called FPM, the Fortran Package Manager. On macOS, gcc comes with GFortran compiler. Starting a new Fortran application is very easy. While working on my German salary calculator, I had the chance to explore the ecosystem and use some cool language features. So, what does the Fortran ecosystem look like today? This sounded like a relatively applicable problem. I was recently diving into the formulas required to calculate German salary social contributions for employers, as in, the total cost of an employee for a given gross salary. It is definitely a command line application doing some sort of number crunching with a sprinkle of command line output. Those can be used to construct class-like structures with methods operating on an internal state of the type.įinding a reasonable problem for Fortran outside its scientific niche requires an open mind. Modern Fortran provides derived types, which can be compared to structures or records in other languages. It’s possible to use C interoperability to bolt sockets on, but that doesn’t feel like Fortran anymore.įortran provides logical values ( booleans), integers, reals, complex numbers, and characters ( a string). It lacks any networking capabilities, there are no operations on byte arrays, no sockets, no TCP, numbers overflow, so one has to be rather careful, and so on. However, Fortran isn’t a tool you’d apply in a modern microservice architecture. Parallel computing: Fortran coarrays are a relatively simple mechanism to distribute work across CPUs, pin work to selected CPUs, and synchronize the computation across CPUs.Multi-dimensional arrays: up to 15 dimensions out of the box with a short syntax to declare them.Array-oriented operations, for example, multiply every array element by two: * 2.Anywhere where there’s a need to process vast arrays of numbers, most likely in parallel-that’s where you’ll find Fortran code. Weather simulation, oceanographic simulations, aerospace, automotive, high-performance computing, finance. Fortran is the oldest, actively maintained programming language in use today.įortran has its niche in scientific computing. Fortran is still in active development, it has seen several iterations over the decades. The first version of Fortran, the first high-level programming language, appeared in 1957. The language has been on my to learn list for many, many years, but Fortran requires a particular type of problem. This is a short sentence describing my recent venture into Fortran. An exercise on its own rather than a conscious future career choice.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |