Modern Fortran Explained (2023) now published

The new edition of Modern Fortran Explained: Incorporating Fortran 2023 was published on 7 December and is available on the OUP website ( Modern Fortran Explained - Paperback - Michael Metcalf, John Reid, Malcolm Cohen, Reinhold Bader - Oxford University Press (oup.com)) and some Amazon websites. The text has been completely revised and reordered. It contains two completely new chapters on the F2023 features. Further, the extended examples will be downloadable. This applies not only to the extisting OOP example, but also to three complete, new examples of coarray code. We are joined by Reinhold Bader as a fourth author.

Mike Metcalf

36 Likes

Great job @m_b_metcalf, looking forward to adding it to my reading list!

Man! You guys waste no time :slight_smile:

I’m really glad that it’s out. I have the Fortran 2008 edition and I’ve put off buying the 2018 version in the hopes that 2023 would come out soon.

EDIT: It’s on Amazon.

Mine arrived this morning, so excited, and well done to all 4 authors

Great! I’ve been a happy customer since learning Fortran as an undergrad via “Effective Fortran 77”. Just ordered a copy to ship over from the UK…

2 Likes

This is good news. Is it the same color (colour) as the previous edition?

I preordered it.

Ordered it, too. Seems to not be available in Germany yet, so I guess I have to wait until March. :frowning:

Sorry to hear that; I’m investigating. In the meantime, amazon.co.uk is claiming that it will deliver to Germany by 23 December.

Mike

My local (Dutch) bookshop claims to be able to deliver in 4 or 5 days. Odd, but I have not yet ordered it, so I do not know if their claim is correct.

Ordered last Friday (8 Dec) at a Dutch online shop (bol.com) and got it on Saturday by regular mail.

Good to hear that!

Purchased :rocket::rocket::rocket:

Hello, please how can I get a copy in China. Thank you.

Welcome to the forum. Is the book not available via one of the online vendors?

Yes, and in particular it should be possible to order direct from OUP with world-wide shipping: OUP site . China is listed in the list of countries to which deliveries can be made: China is in this list

Mike

I am glad to see Reinhold Bader joining the trio. It is almost as exciting as when Young joined Crosby, Stills, and Nash.

5 Likes

Some of the ages are quite close :slight_smile:

I got the book and read a couple of chapters. I am very satisfied with it.

One question:

In Figure 2.4, there is an allocatable vector of the type one:

type(one), allocatable :: alloc(:)

Where

type one
  integer :: comp
end type one

The authors talk about alloc % comp. But if alloc is a vector, can we refer to the comp like that? Even in the text? Should it be something like alloc(:) % comp?

1 Like

The book is correct. For example, the following code compiles and runs with gfortran, ifort, and g95

implicit none
integer, parameter :: n = 3
type one
  integer :: comp
end type one
type(one), allocatable :: alloc(:)
integer :: i
allocate (alloc(n))
do i=1,n
   alloc(i)%comp = i**2
end do
print*,alloc%comp
end

and gives output 1 4 9.

3 Likes