Live data from Hacker News

Fortran Package Manager

github.com

21–30 of 73 posts

Re: Fortran Package Manager

#21

Earlier quoted context omitted.

Yes. Fortran is used extensively in climate modelling (even newer models).

Really that’s interesting, just curious fortran over other languages

The intuition is similar to "why C over other languages?": speed. Many programmers treat C as the fastest/lowest-level cross-platform language, but Fortran sometimes has a slight edge (especially with specialised compilers, e.g. I remember Intel's producing very fast binaries).

Although it's general-purpose, Fortran skews heavily towards numerical calculations, which is probably why it's not used much outside science and engineering (e.g. most Web stuff is 'string processing' rather than numerical).

Fortran was used to write highly optimised numerical libraries like BLAS, which are so widely used and performance-critical that it pretty much cemented Fortran's use; although (a) such libraries can be used by other languages, and (b) they've become so optimised over the decades that they're essentially pure machine-code these days ;)

Re: Fortran Package Manager

#22
post #20

For folks who have never used Fortran, how is the day to day life compared to Python or Java?

It depends on what you are doing. If it is numerical work with matrix operations, then Fortran is fast and pretty intuitive. Some of the annoyances come from dealing with legacy code and mixing it with modern standards.

Re: Fortran Package Manager

#23

Earlier quoted context omitted.

Yes. Fortran is used extensively in climate modelling (even newer models).

Really that’s interesting, just curious fortran over other languages

In many numerical math, you do not need fancy data structures. Just loops over huge arrays of floating point numbers, performing a simple operation inside the loop. Said operation may have a small bit of complexity inside, thus it cannot be "vectorized" readily. Implementing this kind of algorithms is either cumbersome or extremely slow in Python, but in Fortran or C it is straightforward and fast.

Re: Fortran Package Manager

#24
here are some articles by some of the contributors:

Fortran Package Manager's First Birthday (2020-12?): https://github.com/everythingfunctional/fortran-forum-fpm-fi...

  It was very quickly that many interested in using fpm also expressed some interest in helping with its development. There was one problem. Most people were not familiar with Haskell, making that a significant barrier to their being able to contribute. But everybody had significant experience (or at least interest) in Fortran. It was thus that we decided we would rewrite fpm in Fortran, enabling a larger portion of its intended users to also be contributors. With the initial prototype usable for developing libraries, and many already converting their existing libraries to be fpm compatible, it didn’t seem quite so daunting a task as it otherwise would have.
Resurrecting Fortran (2021-03): https://ondrejcertik.com/blog/2021/03/resurrecting-fortran/

First year of Fortran-Lang (2020-12): https://medium.com/modern-fortran/first-year-of-fortran-lang...

Re: Fortran Package Manager

#26
post #22
post #20

For folks who have never used Fortran, how is the day to day life compared to Python or Java?

It depends on what you are doing. If it is numerical work with matrix operations, then Fortran is fast and pretty intuitive. Some of the annoyances come from dealing with legacy code and mixing it with modern standards.

Also Compared to Python Fortran is an old school compiled language - you have to get used to working with a compline/link cycle without the interactivity that Python has.

This isn't any better or worse but does require a shift in mind set.

Though I believe some people are trying to build a Fortan Repl

Re: Fortran Package Manager

#27

Just curious is Fotran Still being used in Newer Projects

Yes, a nuclear modelling software called MCNP is widely used and written entirely in fortran. Some of its source code can date back to the dawn of computing in the 1940s!

Edit to say I missed your newer project specification; MCNP is still under very active development and frequent updates, if that counts.

Re: Fortran Package Manager

#28
post #9

Earlier quoted context omitted.

> in FORTRAN, GOD is REAL .. but not COMPLEX nor LOGICAL

> > in FORTRAN, GOD is REAL > but not COMPLEX Theology concurs: https://en.m.wikipedia.org/wiki/Divine_simplicity

OT but what bulls*ht that first paragraph is ahaha, talk about an intellectual circle-jerk.

Re: Fortran Package Manager

#29
post #22

Earlier quoted context omitted.

It depends on what you are doing. If it is numerical work with matrix operations, then Fortran is fast and pretty intuitive. Some of the annoyances come from dealing with legacy code and mixing it with modern standards.

Also Compared to Python Fortran is an old school compiled language - you have to get used to working with a compline/link cycle without the interactivity that Python has. This isn't any better or worse but does require a shift in mind set. Though I believe some people are trying to build a Fortan Repl

That's true, I keep forgetting about https://lfortran.org/ Unfortunately in my experience the people I know who almost exclusively code in fortran are not really interested in jupyter notebooks.

Re: Fortran Package Manager

#30

Just curious is Fotran Still being used in Newer Projects

Weather forecasting in most countries are based on numerical models written in Fortran.

Despite what you may have heard, the language has evolved over the decades and has most of the features one would expect from a modern language.

Post reply on HN