question about using same unit number to open different files on a dual processor computer.

Martin Siegert siegert at
Wed Jun 12 19:52:18 PDT 2002


On Wed, Jun 12, 2002 at 04:34:14PM -0500, gli at wrote:
> Hi, everybody,
> i use MPICH to make a parallel program on one dual-processor computer.
> so there should be two processes on this computer i can use. id=0,1
> i want to open different files for different id processes but using the 
> same unit number, is it possible?
> if yes, how i can do it?
> thanks very much!!

Since you are refering to "unit numbers" I am guessing that your program
is written in Fortran. In that case something like

if (id == 0) then

should do the trick.
I hope this helps.


Martin Siegert
Academic Computing Services                        phone: (604) 291-4691
Simon Fraser University                            fax:   (604) 291-4242
Burnaby, British Columbia                          email: siegert at
Canada  V5A 1S6

More information about the Beowulf mailing list