Corrected undefined "state" in HomogenisedC

Added "forall" loops in C construction
This commit is contained in:
Luc Hantcherli 2007-12-07 10:54:19 +00:00
parent d615406722
commit f63f6949cc
2 changed files with 14 additions and 11 deletions

View File

@ -526,13 +526,13 @@ do i=1,material_maxN
material_Gmod(i)=material_C44(i) material_Gmod(i)=material_C44(i)
select case (material_CrystalStructure(i)) select case (material_CrystalStructure(i))
case(1:2) ! cubic(s) case(1:2) ! cubic(s)
do k=1,3 forall(k=1:3)
do j=1,3 forall(j=1:3)
material_Cslip_66(k,j,i)=material_C12(i) material_Cslip_66(k,j,i)=material_C12(i)
enddo endforall
material_Cslip_66(k,k,i)=material_C11(i) material_Cslip_66(k,k,i)=material_C11(i)
material_Cslip_66(k+3,k+3,i)=material_C44(i) material_Cslip_66(k+3,k+3,i)=material_C44(i)
enddo endforall
case(3) ! hcp case(3) ! hcp
material_Cslip_66(1,1,i)=material_C11(i) material_Cslip_66(1,1,i)=material_C11(i)
material_Cslip_66(2,2,i)=material_C11(i) material_Cslip_66(2,2,i)=material_C11(i)
@ -750,6 +750,7 @@ implicit none
!* Definition of variables !* Definition of variables
integer(pInt) ipc,ip,el integer(pInt) ipc,ip,el
real(pReal), dimension(6,6) :: constitutive_homogenizedC real(pReal), dimension(6,6) :: constitutive_homogenizedC
real(pReal), dimension(constitutive_Nstatevars(ipc,ip,el)) :: state
!* Homogenization scheme !* Homogenization scheme
constitutive_homogenizedC=material_Cslip_66(:,:,constitutive_matID(ipc,ip,el)) constitutive_homogenizedC=material_Cslip_66(:,:,constitutive_matID(ipc,ip,el))

View File

@ -503,13 +503,13 @@ close(fileunit)
do i=1,material_maxN do i=1,material_maxN
select case (material_CrystalStructure(i)) select case (material_CrystalStructure(i))
case(1:2) ! cubic(s) case(1:2) ! cubic(s)
do k=1,3 forall(k=1:3)
do j=1,3 forall(j=1:3)
material_Cslip_66(k,j,i)=material_C12(i) material_Cslip_66(k,j,i)=material_C12(i)
enddo endforall
material_Cslip_66(k,k,i)=material_C11(i) material_Cslip_66(k,k,i)=material_C11(i)
material_Cslip_66(k+3,k+3,i)=material_C44(i) material_Cslip_66(k+3,k+3,i)=material_C44(i)
enddo endforall
case(3) ! hcp case(3) ! hcp
material_Cslip_66(1,1,i)=material_C11(i) material_Cslip_66(1,1,i)=material_C11(i)
material_Cslip_66(2,2,i)=material_C11(i) material_Cslip_66(2,2,i)=material_C11(i)
@ -696,10 +696,11 @@ constitutive_maxNresults = maxval(constitutive_Nresults)
end subroutine end subroutine
function constitutive_HomogenizedC(ipc,ip,el) function constitutive_HomogenizedC(state,ipc,ip,el)
!********************************************************************* !*********************************************************************
!* This function returns the homogenized elacticity matrix * !* This function returns the homogenized elacticity matrix *
!* INPUT: * !* INPUT: *
!* - state : state variables *
!* - ipc : component-ID of current integration point * !* - ipc : component-ID of current integration point *
!* - ip : current integration point * !* - ip : current integration point *
!* - el : current element * !* - el : current element *
@ -710,9 +711,10 @@ implicit none
!* Definition of variables !* Definition of variables
integer(pInt) ipc,ip,el integer(pInt) ipc,ip,el
real(pReal), dimension(6,6) :: constitutive_homogenizedC real(pReal), dimension(6,6) :: constitutive_homogenizedC
real(pReal), dimension(constitutive_Nstatevars(ipc,ip,el)) :: state
!* Homogenization scheme !* Homogenization scheme
constitutive_homogenizedC=constitutive_MatVolFrac(ipc,ip,el)*material_Cslip_66(:,:,constitutive_matID(ipc,ip,el)) constitutive_homogenizedC=material_Cslip_66(:,:,constitutive_matID(ipc,ip,el))
return return
end function end function
@ -798,7 +800,7 @@ end subroutine
function constitutive_dotState(Tstar_v,state,Temperature,ipc,ip,el) function constitutive_dotState(Tstar_v,state,Temperature,ipc,ip,el)
!********************************************************************* !*********************************************************************
!* This subroutine contains the constitutive equation for * !* This subroutine contains the constitutive equation for *
!* calculating the velocity gradient * !* calculating the rate of change of microstructure *
!* INPUT: * !* INPUT: *
!* - Tstar_v : 2nd Piola Kirchhoff stress tensor (Mandel) * !* - Tstar_v : 2nd Piola Kirchhoff stress tensor (Mandel) *
!* - state : current microstructure * !* - state : current microstructure *