@Raymond_Yu - we do our best to help with all questions posted here. Nobody is assigned to support full-time, we all have other work, but we take problem reports very seriously, especially when they are possible MFiX bugs.
I spent some time on Friday trying to reproduce this error, without success. Nobody else has ever reported this problem, so it’s something very unique to your system.
The error is saying that the PVD file was opened in read-only mode, and the program attempted to write to it. However, examining the source code, there’s no place where the PVD file is opened read-only - in fact, the access mode is not specified at all.
Perusing the GFortran docs, I found this:
https://gcc.gnu.org/onlinedocs/gfortran/Files-opened-without-an-explicit-ACTION_003d-specifier.html
The Fortran standard says that if an OPEN statement is
executed without an explicit ACTION= specifier, the
default value is processor dependent. GNU Fortran
behaves as follows:
Attempt to open the file with ACTION='READWRITE'
If that fails, try to open with ACTION='READ'
If that fails, try to open with ACTION='WRITE'
If that fails, generate an error
So what may be happening is that the initial READWRITE open attempt is failing, and it’s falling back to READ. However I have no idea why this would be happening. Something with the filesystem? Can you try it on a different machine?
I think the next step in debugging would be to change the OPEN statements to use explicit READWRITE, that way if this fails, instead of falling back to read-only mode it will generate an error right away, which might give us more info (if there is a decent error message). Since we are not able to reproduce the error, you will have to do this. I’ll work up a patch and post it here today.