diff --git a/code/debug.f90 b/code/debug.f90 index 3dc74581a..299fb84df 100644 --- a/code/debug.f90 +++ b/code/debug.f90 @@ -123,8 +123,8 @@ endsubroutine write(6,*) write(6,*) 'distribution_StressLoop :' do i=1,nStress - if (debug_StressLoopDistribution(i) /= 0) then - integral = integral + i*debug_StressLoopDistribution(i) + if (debug_StressLoopDistribution(i,1) /= 0 .or. debug_StressLoopDistribution(i,2) /= 0) then + integral = integral + i*debug_StressLoopDistribution(i,1) + i*debug_StressLoopDistribution(i,2) write(6,'(i25,x,i10,x,i10)') i,debug_StressLoopDistribution(i,1),debug_StressLoopDistribution(i,2) endif enddo diff --git a/code/mesh.f90 b/code/mesh.f90 index ecfb47b40..366c71749 100644 --- a/code/mesh.f90 +++ b/code/mesh.f90 @@ -2969,6 +2969,7 @@ subroutine mesh_marc_count_cpSizes (unit) use prec, only: pInt use math, only: math_range use IO, only: IO_error + use debug, only: verboseDebugger implicit none @@ -2985,60 +2986,67 @@ subroutine mesh_marc_count_cpSizes (unit) mesh_HomogMicro(mesh_element(3,i),mesh_element(4,i)) = & mesh_HomogMicro(mesh_element(3,i),mesh_element(4,i)) + 1 ! count combinations of homogenization and microstructure enddo - -!$OMP CRITICAL (write2out) -! write(6,*) -! write(6,*) 'Input Parser: IP COORDINATES' -! write(6,'(a5,x,a5,3(x,a12))') 'elem','IP','x','y','z' -! do e = 1,mesh_NcpElems -! do i = 1,FE_Nips(mesh_element(2,e)) -! write (6,'(i5,x,i5,3(x,f12.8))') e, i, mesh_ipCenterOfGravity(:,i,e) -! enddo -! enddo -! write(6,*) -! write(6,*) "Input Parser: IP NEIGHBORHOOD" -! write(6,*) -! write(6,"(a10,x,a10,x,a10,x,a3,x,a13,x,a13)") "elem","IP","neighbor","","elemNeighbor","ipNeighbor" -! do e = 1,mesh_NcpElems ! loop over cpElems -! t = mesh_element(2,e) ! get elemType -! do i = 1,FE_Nips(t) ! loop over IPs of elem -! do n = 1,FE_NipNeighbors(t) ! loop over neighbors of IP -! write (6,"(i10,x,i10,x,i10,x,a3,x,i13,x,i13)") e,i,n,'-->',mesh_ipNeighborhood(1,n,i,e),mesh_ipNeighborhood(2,n,i,e) -! enddo -! enddo -! enddo -! write (6,*) -! write (6,*) "Input Parser: ELEMENT VOLUME" -! write (6,*) -! write (6,"(a13,x,e15.8)") "total volume", sum(mesh_ipVolume) -! write (6,*) -! write (6,"(a5,x,a5,x,a15,x,a5,x,a15,x,a16)") "elem","IP","volume","face","area","-- normal --" -! do e = 1,mesh_NcpElems -! do i = 1,FE_Nips(mesh_element(2,e)) -! write (6,"(i5,x,i5,x,e15.8)") e,i,mesh_IPvolume(i,e) -! do f = 1,FE_NipNeighbors(mesh_element(2,e)) -! write (6,"(i33,x,e15.8,x,3(f6.3,x))") f,mesh_ipArea(f,i,e),mesh_ipAreaNormal(:,f,i,e) -! enddo -! enddo -! enddo -! write (6,*) -! write (6,*) "Input Parser: SUBNODE COORDINATES" -! write (6,*) -! write(6,'(a5,x,a5,x,a15,x,a15,x,a20,3(x,a12))') 'elem','IP','IP neighbor','IPFaceNodes','subNodeOnIPFace','x','y','z' -! do e = 1,mesh_NcpElems ! loop over cpElems -! t = mesh_element(2,e) ! get elemType -! do i = 1,FE_Nips(t) ! loop over IPs of elem -! do f = 1,FE_NipNeighbors(t) ! loop over interfaces of IP -! do n = 1,FE_NipFaceNodes ! loop over nodes on interface -! write(6,'(i5,x,i5,x,i15,x,i15,x,i20,3(x,f12.8))') e,i,f,n,FE_subNodeOnIPFace(n,f,i,t),& -! mesh_subNodeCoord(1,FE_subNodeOnIPFace(n,f,i,t),e),& -! mesh_subNodeCoord(2,FE_subNodeOnIPFace(n,f,i,t),e),& -! mesh_subNodeCoord(3,FE_subNodeOnIPFace(n,f,i,t),e) -! enddo -! enddo -! enddo -! enddo + if (verboseDebugger) then + !$OMP CRITICAL (write2out) + + write(6,*) + write(6,*) 'Input Parser: IP COORDINATES' + write(6,'(a5,x,a5,3(x,a12))') 'elem','IP','x','y','z' + do e = 1,mesh_NcpElems + do i = 1,FE_Nips(mesh_element(2,e)) + write (6,'(i5,x,i5,3(x,f12.8))') e, i, mesh_ipCenterOfGravity(:,i,e) + enddo + enddo + write(6,*) + write(6,*) "Input Parser: IP NEIGHBORHOOD" + write(6,*) + write(6,"(a10,x,a10,x,a10,x,a3,x,a13,x,a13)") "elem","IP","neighbor","","elemNeighbor","ipNeighbor" + do e = 1,mesh_NcpElems ! loop over cpElems + t = mesh_element(2,e) ! get elemType + do i = 1,FE_Nips(t) ! loop over IPs of elem + do n = 1,FE_NipNeighbors(t) ! loop over neighbors of IP + write (6,"(i10,x,i10,x,i10,x,a3,x,i13,x,i13)") e,i,n,'-->',mesh_ipNeighborhood(1,n,i,e),mesh_ipNeighborhood(2,n,i,e) + enddo + enddo + enddo + write (6,*) + write (6,*) "Input Parser: ELEMENT VOLUME" + write (6,*) + write (6,"(a13,x,e15.8)") "total volume", sum(mesh_ipVolume) + write (6,*) + write (6,"(a5,x,a5,x,a15,x,a5,x,a15,x,a16)") "elem","IP","volume","face","area","-- normal --" + do e = 1,mesh_NcpElems + do i = 1,FE_Nips(mesh_element(2,e)) + write (6,"(i5,x,i5,x,e15.8)") e,i,mesh_IPvolume(i,e) + do f = 1,FE_NipNeighbors(mesh_element(2,e)) + write (6,"(i33,x,e15.8,x,3(f6.3,x))") f,mesh_ipArea(f,i,e),mesh_ipAreaNormal(:,f,i,e) + enddo + enddo + enddo + write (6,*) + write (6,*) "Input Parser: SUBNODE COORDINATES" + write (6,*) + write(6,'(a5,x,a5,x,a15,x,a15,x,a20,3(x,a12))') 'elem','IP','IP neighbor','IPFaceNodes','subNodeOnIPFace','x','y','z' + do e = 1,mesh_NcpElems ! loop over cpElems + t = mesh_element(2,e) ! get elemType + do i = 1,FE_Nips(t) ! loop over IPs of elem + do f = 1,FE_NipNeighbors(t) ! loop over interfaces of IP + do n = 1,FE_NipFaceNodes ! loop over nodes on interface + write(6,'(i5,x,i5,x,i15,x,i15,x,i20,3(x,f12.8))') e,i,f,n,FE_subNodeOnIPFace(n,f,i,t),& + mesh_subNodeCoord(1,FE_subNodeOnIPFace(n,f,i,t),e),& + mesh_subNodeCoord(2,FE_subNodeOnIPFace(n,f,i,t),e),& + mesh_subNodeCoord(3,FE_subNodeOnIPFace(n,f,i,t),e) + enddo + enddo + enddo + enddo +!$OMP END CRITICAL (write2out) +endif + + + !$OMP CRITICAL (write2out) + write (6,*) write (6,*) "Input Parser: STATISTICS" write (6,*)