Merge branch 'development' into 3-adding-plastic-constitutive-law-with-kinematic-hardening

This commit is contained in:
Zhuowen Zhao 2017-11-06 18:11:47 -05:00
commit 566cf3d855
3 changed files with 46 additions and 10 deletions

View File

@ -0,0 +1,25 @@
[Air]
## Isotropic Material model to simulate free surfaces ##
## For more information see paper Maiti+Eisenlohr2018, Scripta Materialia,
## "Fourier-based spectral method solution to finite strain crystal plasticity with free surfaces"
elasticity hooke
plasticity isotropic
/dilatation/
(output) flowstress
(output) strainrate
lattice_structure isotropic
c11 110.9e9
c12 0.0
taylorfactor 3
tau0 31e6
gdot0 0.001
n 20
h0 75e6
tausat 63e6
w0 2.25
atol_resistance 1

View File

@ -22,7 +22,13 @@ parser.add_option('-t','--tensor',
dest = 'tensor',
action = 'extend', metavar = '<string LIST>',
help = 'heading of columns containing tensor field values')
parser.add_option('--no-check',
dest = 'rh',
action = 'store_false',
help = 'skip check for right-handed eigenvector basis')
parser.set_defaults(rh = True,
)
(options,filenames) = parser.parse_args()
if options.tensor is None:
@ -57,8 +63,10 @@ for name in filenames:
if dim != data['dim']: remarks.append('column {} is not a {}...'.format(what,type))
else:
items[type]['column'].append(table.label_index(what))
table.labels_append(['{}_eigval({})'.format(i+1,what) for i in range(3)]) # extend ASCII header with new labels
table.labels_append(['{}_eigvec({})'.format(i+1,what) for i in range(9)]) # extend ASCII header with new labels
for order in ['Min','Mid','Max']:
table.labels_append(['eigval{}({})'.format(order,what)]) # extend ASCII header with new labels
for order in ['Min','Mid','Max']:
table.labels_append(['{}_eigvec{}({})'.format(i+1,order,what) for i in range(3)]) # extend ASCII header with new labels
if remarks != []: damask.util.croak(remarks)
if errors != []:
@ -78,10 +86,10 @@ for name in filenames:
for type, data in items.iteritems():
for column in data['column']:
(u,v) = np.linalg.eigh(np.array(map(float,table.data[column:column+data['dim']])).reshape(data['shape']))
if np.dot(np.cross(v[:,0], v[:,1]), v[:,2]) < 0.0 : v[:, 2] *= -1.0 # ensure right-handed coordinate system
table.data_append(list(u))
table.data_append(list(v.transpose().reshape(data['dim'])))
outputAlive = table.data_write() # output processed line
if options.rh and np.dot(np.cross(v[:,0], v[:,1]), v[:,2]) < 0.0 : v[:, 2] *= -1.0 # ensure right-handed eigenvector basis
table.data_append(list(u)) # vector of max,mid,min eigval
table.data_append(list(v.transpose().reshape(data['dim']))) # 3x3=9 combo vector of max,mid,min eigvec coordinates
outputAlive = table.data_write() # output processed line in accordance with column labeling
# ------------------------------------------ output finalization -----------------------------------

View File

@ -60,15 +60,18 @@ module plastic_isotropic
flowstress, &
accumulatedShear
end type
type, private :: tIsotropicAbsTol !< internal alias for abs tolerance in state
real(pReal), pointer :: & ! scalars
flowstress, &
accumulatedShear
end type
type(tIsotropicState), allocatable, dimension(:), private :: & !< state aliases per instance
state, &
state0, &
dotState
type(tIsotropicAbsTol), allocatable, dimension(:), private :: & !< state aliases per instance
stateAbsTol
@ -140,7 +143,7 @@ subroutine plastic_isotropic_init(fileUnit)
extmsg = ''
character(len=64) :: &
outputtag = ''
integer(pInt) :: NipcMyPhase
integer(pInt) :: NipcMyPhase
write(6,'(/,a)') ' <<<+- constitutive_'//PLASTICITY_ISOTROPIC_label//' init -+>>>'
write(6,'(a15,a)') ' Current time: ',IO_timeStamp()
@ -293,9 +296,9 @@ subroutine plastic_isotropic_init(fileUnit)
!--------------------------------------------------------------------------------------------------
! allocate state arrays
sizeState = 2_pInt ! flowstress, accumulated_shear
sizeDotState = sizeState ! both evolve
sizeDotState = 2_pInt ! flowstress, accumulated_shear
sizeDeltaState = 0_pInt ! no sudden jumps in state
sizeState = sizeDotState + sizeDeltaState
plasticState(phase)%sizeState = sizeState
plasticState(phase)%sizeDotState = sizeDotState
plasticState(phase)%sizeDeltaState = sizeDeltaState