23 double precision,
dimension(:),
allocatable :: facebuf
41 double precision,
dimension(:),
allocatable ::
drootbuf 42 double precision,
dimension(:),
allocatable ::
dprocbuf 46 integer,
dimension(:),
allocatable::
idispls 58 double precision,
dimension(:,:),
allocatable::
dpar_pos 59 double precision,
dimension(:,:),
allocatable::
dpar_vel 60 double precision,
dimension(:),
allocatable::
dpar_den 61 double precision,
dimension(:),
allocatable::
dpar_rad 81 use discretelement
, only: des_pos_new
82 use discretelement
, only: iglobal_id
84 use discretelement
, only: s_time
85 use discretelement
, only: dimn
86 use discretelement
, only: do_nsearch
87 use discretelement
, only: ighost_cnt
88 use discretelement
, only: max_pip, pip
89 use functions, only: is_ghost, is_nonexistent, is_normal, is_entering_ghost, is_exiting_ghost
105 character (255) filename
106 integer lcurpar,lpacketsize,lface,lparcnt,lbuf,lindx,ltordimn
107 integer lneighcnt,lneighindx
109 double precision xpos,ypos
110 integer li,lj,lparcount
113 write(filename,
'("dbg_desmpi",I4.4,".dat")')
mype 114 open(44,file=filename,convert=
'big_endian')
118 "------------------------------------------------------" 119 write(44,*)
"Flag Information" 121 write(44,*)
"details for face =" , lface
122 write(44,*)
"Exchflag, cyclfac, neighproc" ,
iexchflag(lface)
125 "------------------------------------------------------" 127 ltordimn = merge(1,3,
no_k)
128 lpacketsize = 2*dimn + ltordimn+ 5
131 lparcnt =
dsendbuf(1+mod(lface,2))%facebuf(1)
132 if (lparcnt .gt. 0)
then 134 "------------------------------------------------------" 135 write(44,*)
"ghost send buffer for face", lface
136 write(44,*)
"Number of particles in sendbuf",lparcnt
137 write(44,*)
"particle number global_id ijk prvijk ",&
138 "radius material new_pos new_vel omega_new" 140 "-----------------------------------------------------" 141 do lcurpar = 1,lparcnt
143 write(44,*) lcurpar,(
dsendbuf(1+mod(lface,2))%facebuf(lindx
148 ltordimn = merge(1,3,
no_k)
149 lpacketsize = 2*dimn + ltordimn+ 5
152 lparcnt =
drecvbuf(1+mod(lface,2))%facebuf(1)
153 if (lparcnt .gt. 0)
then 155 "------------------------------------------------------" 156 write(44,*)
"ghost recv buffer for face", lface
157 write(44,*)
"Number of particles in recvbuf",lparcnt
158 write(44,*)
"particle number global_id ijk prvijk ",&
159 "radius material new_pos new_vel omega_new" 161 "-----------------------------------------------------" 162 do lcurpar = 1,lparcnt
164 write(44,*) lcurpar,(
drecvbuf(1+mod(lface,2))%facebuf(lindx
170 "---------------------------------------------------------" 171 write(44,*)
"Particle info" 172 write(44,*)
"max_pip,pip =" , max_pip,pip
173 write(44,*)
"ghost position ",&
176 "---------------------------------------------------------" 179 if (lparcount.gt.pip)
exit 180 if (is_nonexistent(lcurpar))cycle
181 lparcount=lparcount + 1
182 xpos = des_pos_new(lcurpar,1)
183 ypos = des_pos_new(lcurpar,2)
185 write(44,*)(is_ghost(lcurpar).or.is_entering_ghost(lcurpar).or.is_exiting_ghost
188 ltordimn = merge(1,3,
no_k)
189 lpacketsize = 9*dimn + ltordimn*4 + 13
192 lparcnt =
dsendbuf(1+mod(lface,2))%facebuf(1)
193 if (lparcnt .gt. 0)
then 195 "------------------------------------------------------" 196 write(44,*)
"particle crossing info send buffer", lface
197 write(44,*)
"Number of particles in sendbuf",lparcnt
198 do lcurpar = 1,lparcnt
200 write(44,*)
"global_id ijk prvijk radius i,j,k, ijk" 202 "-----------------------------------------------------" 204 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
207 write(44,*)
"phase density vol mass omoi pos_old" 209 "-----------------------------------------------------" 211 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
214 write(44,*)
"pos_new vel_old vel_new" 216 "-----------------------------------------------------" 218 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
221 write(44,*)
"omega_old omega_new" 223 "-----------------------------------------------------" 225 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
228 write(44,*)
"acc_old rot_acc_old fc " 230 "-----------------------------------------------------" 231 lsize = 2*dimn + ltordimn
232 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
235 write(44,*)
"fn ft tow" 237 "-----------------------------------------------------" 238 lsize = 2*dimn + ltordimn
239 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
243 lneighcnt =
dsendbuf(1+mod(lface,2))%facebuf(lbuf);lbuf
244 write(44,*)
"total neighbour=",lneighcnt
245 write(44,*)
"neighbou",lneighcnt
246 do lneighindx = 1, lneighcnt
248 write(44,
'(5(2x,f8.4))') (
dsendbuf(1+mod(lface,2))%facebuf
255 write(44,*)
"-----------------------------------------------" 256 write(44,*)
"at Time =",s_time
257 write(44,*)
"Total paticles =",pip
258 write(44,*)
"Total ghost paticles =",ighost_cnt
259 write(44,*)
"do_nsearch =",do_nsearch
261 do lcurpar = 1,max_pip
262 if(lparcnt.gt.pip)
exit 263 lparcnt = lparcnt + 1
264 write(44,*)
"particle position =",des_pos_new(lcurpar,1:dimn
266 write(44,*)
"-----------------------------------------------" 268 write(44,*)
"-----------------------------------------------" 269 write(44,*)
"pip and max_pip" , pip, max_pip,.not.is_nonexistent
272 do lcurpar =1,max_pip
273 if(lparcnt.gt.pip)
exit 274 if(is_nonexistent(lcurpar)) cycle
276 if(is_ghost(lcurpar).or.is_entering_ghost(lcurpar).or.is_exiting_ghost
277 write(44,*)
"Info for particle", iglobal_id(lcurpar)
278 write(44,*)
"position new ", des_pos_new(lcurpar,:)
280 write(44,*)
"-----------------------------------------------" integer, dimension(:), allocatable igathercnts
double precision, dimension(:), allocatable dprocbuf
integer iparticlepacketsize
subroutine des_dbgmpi(ptype)
double precision, dimension(:), allocatable dpar_rad
logical, dimension(:), allocatable iexchflag
integer, dimension(:), allocatable irootbuf
type(array), dimension(:), allocatable dsendbuf
double precision, dimension(:), allocatable dpar_den
integer, dimension(:), allocatable isendreq
type(array), dimension(:), allocatable drecvbuf
integer, dimension(:,:), allocatable isendindices
integer function iofpos(fpos)
integer, dimension(:), allocatable iprocbuf
double precision, dimension(:,:), allocatable dpar_pos
integer, parameter ibufoffset
double precision, dimension(:,:), allocatable dcycl_offset
integer, dimension(:), allocatable idispls
integer, dimension(:), allocatable ineighproc
integer, dimension(:,:), allocatable irecvindices
integer function dg_funijk(fi, fj, fk)
integer function jofpos(fpos)
integer, dimension(:), allocatable isendcnt
double precision, dimension(:,:), allocatable dpar_vel
double precision, dimension(:), allocatable drootbuf
integer, dimension(:), allocatable irecvreq
integer, dimension(:), allocatable iscattercnts