Skip to content
Snippets Groups Projects
Commit 66618bcd authored by Douglas Guptill's avatar Douglas Guptill
Browse files

adjust osolve%x,y,z,lsf after octree_find_node_connectivity, print date

parent 29c82e00
No related branches found
No related tags found
No related merge requests found
......@@ -71,6 +71,7 @@ logical, dimension(:), allocatable :: iproc_col
double precision, dimension(:), allocatable :: avals
double precision, dimension(:,:), allocatable :: b
double precision, dimension(:), allocatable :: weightel
double precision, dimension(:), allocatable :: xyz_t
shift=' '
......@@ -100,6 +101,7 @@ call int_to_char(ciproc,3,iproc)
threadinfo%Logunit=1000+iproc
open (unit=threadinfo%Logunit,file='./DEBUG/mpilogs/Log_'//ciproc//'.dat',status='replace')
write(threadinfo%Logunit,*) 'This is douar, last modifed 2009-07-14'
write(threadinfo%Logunit,'(a,i3)') 'Log file of mpi process',iproc
call heap_init(threadinfo,2000+iproc,'./DEBUG/mpilogs/mem_heap_'//ciproc//'.dat')
......@@ -426,6 +428,54 @@ do while (istep.le.params%nstep)
call octree_find_node_connectivity (osolve%octree,osolve%noctree, &
osolve%icon,osolve%nleaves,osolve%x,osolve%y,osolve%z,osolve%nnode)
! osolve%nnode has been changed by octree_find_node_connectivity.
allocate (xyz_t(osolve%nnode),stat=threadinfo%err)
call heap (threadinfo, 'xyz_t', 'main', size(xyz_t), 'dp', +1)
! re-size x
do i = 1, osolve%nnode
xyz_t(i) = osolve%x(i)
enddo
call heap (threadinfo,'osolve%x', 'main',size(osolve%x),'dp',-1)
deallocate (osolve%x)
allocate (osolve%x(osolve%nnode),stat=threadinfo%err)
call heap (threadinfo,'osolve%x', 'main',size(osolve%x),'dp',+1)
do i = 1, osolve%nnode
osolve%x(i) = xyz_t(i)
enddo
! re-size y
do i = 1, osolve%nnode
xyz_t(i) = osolve%y(i)
enddo
call heap (threadinfo,'osolve%y', 'main',size(osolve%y),'dp',-1)
deallocate (osolve%y)
allocate (osolve%y(osolve%nnode),stat=threadinfo%err)
call heap (threadinfo,'osolve%y', 'main',size(osolve%y),'dp',+1)
do i = 1, osolve%nnode
osolve%y(i) = xyz_t(i)
enddo
! re-size z
do i = 1, osolve%nnode
xyz_t(i) = osolve%z(i)
enddo
call heap (threadinfo,'osolve%z', 'main',size(osolve%z),'dp',-1)
deallocate (osolve%z)
allocate (osolve%z(osolve%nnode),stat=threadinfo%err)
call heap (threadinfo,'osolve%z', 'main',size(osolve%z),'dp',+1)
do i = 1, osolve%nnode
osolve%z(i) = xyz_t(i)
enddo
! delete the temporary buffer
call heap (threadinfo,'xyz_t', 'main',size(xyz_t),'dp',-1)
deallocate (xyz_t)
! resize lsf
call heap (threadinfo,'osolve%lsf', 'main',size(osolve%lsf),'dp',-1)
deallocate (osolve%lsf)
allocate (osolve%lsf(osolve%nnode,osolve%nlsf),stat=threadinfo%err)
call heap (threadinfo,'osolve%lsf', 'main',size(osolve%lsf),'dp',+1)
osolve%lsf=0.d0
!------------------------------------------------------------------------|
!------------------------------------------------------------------------|
! imbed the surfaces in osolve
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment