fixed two memory faults (unallocated and wrong index)
This commit is contained in:
parent
63b939489b
commit
ef506b801e
|
@ -151,6 +151,8 @@ subroutine homogenization_RGC_init(fileUnit)
|
||||||
allocate(homogenization_RGC_sizeState(maxNinstance), source=0_pInt)
|
allocate(homogenization_RGC_sizeState(maxNinstance), source=0_pInt)
|
||||||
allocate(homogenization_RGC_sizePostResults(maxNinstance), source=0_pInt)
|
allocate(homogenization_RGC_sizePostResults(maxNinstance), source=0_pInt)
|
||||||
|
|
||||||
|
allocate(param(maxNinstance)) ! one container of parameters per instance
|
||||||
|
|
||||||
allocate(homogenization_RGC_Noutput(maxNinstance), source=0_pInt)
|
allocate(homogenization_RGC_Noutput(maxNinstance), source=0_pInt)
|
||||||
allocate(homogenization_RGC_Ngrains(3,maxNinstance), source=0_pInt)
|
allocate(homogenization_RGC_Ngrains(3,maxNinstance), source=0_pInt)
|
||||||
allocate(homogenization_RGC_ciAlpha(maxNinstance), source=0.0_pReal)
|
allocate(homogenization_RGC_ciAlpha(maxNinstance), source=0.0_pReal)
|
||||||
|
@ -170,7 +172,7 @@ subroutine homogenization_RGC_init(fileUnit)
|
||||||
instance = homogenization_typeInstance(h)
|
instance = homogenization_typeInstance(h)
|
||||||
associate(prm => param(instance))
|
associate(prm => param(instance))
|
||||||
prm%Nconstituents = config_homogenization(h)%getInts('clustersize',requiredShape=[3])
|
prm%Nconstituents = config_homogenization(h)%getInts('clustersize',requiredShape=[3])
|
||||||
if (homogenization_Ngrains(section) /= product(prm%Nconstituents)) &
|
if (homogenization_Ngrains(h) /= product(prm%Nconstituents)) &
|
||||||
call IO_error(211_pInt,ext_msg=trim(tag)//' ('//HOMOGENIZATION_RGC_label//')')
|
call IO_error(211_pInt,ext_msg=trim(tag)//' ('//HOMOGENIZATION_RGC_label//')')
|
||||||
prm%xiAlpha = config_homogenization(h)%getFloat('scalingparameter')
|
prm%xiAlpha = config_homogenization(h)%getFloat('scalingparameter')
|
||||||
prm%ciAlpha = config_homogenization(h)%getFloat('overproportionality')
|
prm%ciAlpha = config_homogenization(h)%getFloat('overproportionality')
|
||||||
|
|
Loading…
Reference in New Issue