- need to get crystal structure as attribute in test (generic function
  was removed, because the crystal structure is in general not the same
  over the whole domain)
- consistent sorting of attributes
This commit is contained in:
Martin Diehl 2020-11-29 09:06:47 +01:00
parent f48f5cb0e8
commit 1d05edd7b3
6 changed files with 64 additions and 11 deletions

View File

@ -2,12 +2,12 @@
homogenization:
SX:
N_constituents: 1
mech: {type: none}
mechanics: {type: none}
phase:
pheno_fcc:
lattice: fcc
mech:
lattice: cF
mechanics:
output: [F, P, F_e, F_p, L_p, O]
elasticity: {C_11: 106.75e9, C_12: 60.41e9, C_44: 28.34e9, type: hooke}
plasticity:
@ -23,8 +23,8 @@ phase:
xi_0_sl: [31e6]
xi_inf_sl: [63e6]
pheno_bcc:
lattice: bcc
mech:
lattice: cI
mechanics:
output: [F, P, F_e, F_p, L_p, O]
elasticity: {C_11: 106.75e9, C_12: 60.41e9, C_44: 28.34e9, type: hooke}
plasticity:

View File

@ -0,0 +1,56 @@
---
homogenization:
SX:
N_constituents: 1
mechanics: {type: none}
phase:
pheno_fcc:
lattice: cF
mechanics:
output: [F, P, F_e, F_p, L_p, O]
elasticity: {C_11: 106.75e9, C_12: 60.41e9, C_44: 28.34e9, type: hooke}
plasticity:
N_sl: [12]
a_sl: 2.25
atol_xi: 1.0
dot_gamma_0_sl: 0.001
h_0_sl_sl: 75e6
h_sl_sl: [1, 1, 1.4, 1.4, 1.4, 1.4]
n_sl: 20
output: [xi_sl]
type: phenopowerlaw
xi_0_sl: [31e6]
xi_inf_sl: [63e6]
material:
- constituents:
- fraction: 1.0
O: [0.8229200444892315, 0.5284940239127993, -0.11958598847729246, 0.17086795611292308]
phase: pheno_fcc
homogenization: SX
- constituents:
- fraction: 1.0
O: [0.029934934533052786, -0.0463822071939717, 0.9983440440417412, 0.01617900728410769]
phase: pheno_fcc
homogenization: SX
- constituents:
- fraction: 1.0
O: [0.5285808688806949, 0.7326575088838098, 0.4051997815944012, 0.1401013087924221]
phase: pheno_fcc
homogenization: SX
- constituents:
- fraction: 1.0
O: [0.1839974517790312, 0.49550065903084944, -0.1541415483910751, -0.8347840545305227]
phase: pheno_fcc
homogenization: SX
- constituents:
- fraction: 1.0
O: [0.8055693100147384, -0.22778497057116814, -0.028331746016454287, 0.5462320075864553]
phase: pheno_fcc
homogenization: SX
- constituents:
- fraction: 1.0
O: [0.8025842700117737, -0.33640019337884963, -0.3847408071640489, 0.3076815085881779]
phase: pheno_fcc
homogenization: SX

View File

@ -5,7 +5,7 @@ step:
t: 20
N: 40
f_out: 4
mech:
mechanics:
dot_F: [x, 0, 0,
0, 1.0e-3, 0,
0, 0, x]

View File

@ -173,11 +173,8 @@ class TestResult:
loc = {'O': default.get_dataset_location('O'),
'color': default.get_dataset_location('IPFcolor_[{} {} {}]'.format(*d))}
qu = default.read_dataset(loc['O']).view(np.double).squeeze()
crystal_structure = default.get_crystal_structure()
c = Orientation(rotation=qu,
lattice={'fcc':'cF',
'bcc':'cI',
'hex':'hP'}[crystal_structure])
crystal_structure = default._get_attribute(default.get_dataset_location('O')[0],'Lattice')
c = Orientation(rotation=qu,lattice=crystal_structure)
in_memory = np.uint8(c.IPF_color(np.array(d))*255)
in_file = default.read_dataset(loc['color'])
assert np.allclose(in_memory,in_file)