32 vec,xx,yy,zz,loc_n_num,tstart)
36 character*70 :: file_name, file_xyz
38 integer*4 :: count,proc,nv, ncol
41 real*8,
dimension(nv,ncol) :: vec
43 real*8,
dimension(nv/6) :: xx,yy,zz
44 integer*4,
dimension(nv/6) :: loc_n_num
46 character*70 :: out_file, xyz_file
47 integer*4 :: i,lname, lnamexyz
49 lname = len_trim(file_name)
50 lnamexyz = len_trim(file_xyz)
52 out_file = file_name(1:lname) //
'000000_000000.out'
53 xyz_file = file_xyz(1:lname) //
'000000.out'
55 if (proc .lt. 10)
then
56 write(out_file(lname+6:lname+6),
'(i1)') proc
57 if(tstart .eq. 0.d0)
write(xyz_file(lname+6:lname+6),
'(i1)') proc
58 else if (proc .lt. 100)
then
59 write(out_file(lname+5:lname+6),
'(i2)') proc
60 if(tstart .eq. 0.d0)
write(xyz_file(lname+5:lname+6),
'(i2)') proc
61 else if (proc .lt. 1000)
then
62 write(out_file(lname+4:lname+6),
'(i3)') proc
63 if(tstart .eq. 0.d0)
write(xyz_file(lname+4:lname+6),
'(i3)') proc
64 else if (proc .lt. 10000)
then
65 write(out_file(lname+3:lname+6),
'(i4)') proc
66 if(tstart .eq. 0.d0)
write(xyz_file(lname+3:lname+6),
'(i4)') proc
67 else if (proc .lt. 100000)
then
68 write(out_file(lname+2:lname+6),
'(i5)') proc
69 if(tstart .eq. 0.d0)
write(xyz_file(lname+2:lname+6),
'(i5)') proc
71 write(out_file(lname+1:lname+6),
'(i6)') proc
72 if(tstart .eq. 0.d0)
write(xyz_file(lname+1:lname+6),
'(i6)') proc
75 if (count .lt. 10)
then
76 write(out_file(lname+13:lname+13),
'(i1)') count
77 else if (count .lt. 100)
then
78 write(out_file(lname+12:lname+13),
'(i2)') count
79 else if (count .lt. 1000)
then
80 write(out_file(lname+11:lname+13),
'(i3)') count
81 else if (count .lt. 10000)
then
82 write(out_file(lname+10:lname+13),
'(i4)') count
83 else if (count .lt. 100000)
then
84 write(out_file(lname+9:lname+13),
'(i5)') count
86 write(out_file(lname+8:lname+13),
'(i6)') count
89 open(20+proc, file=out_file)
91 write(20+proc,*) vec(i,:)
98 open(20+proc, file=xyz_file)
100 write(20+proc,*) loc_n_num(i), xx(i), yy(i), zz(i)