elastic phenopowerlaw for hex crystals is working, results are close to analytic ones but there is a small "elastic hardening" and the values are a little bit higher than the ones calculated with mtex
This commit is contained in:
parent
99d6dcecb5
commit
ee6b1eb22c
|
@ -61,7 +61,7 @@ class Texture(Section):
|
||||||
def add_component(self,theType,properties):
|
def add_component(self,theType,properties):
|
||||||
|
|
||||||
if 'scatter' not in map(str.lower,properties.keys()):
|
if 'scatter' not in map(str.lower,properties.keys()):
|
||||||
scatter = 1.0
|
scatter = 0.0
|
||||||
else: scatter = properties['scatter']
|
else: scatter = properties['scatter']
|
||||||
if 'fraction' not in map(str.lower,properties.keys()):
|
if 'fraction' not in map(str.lower,properties.keys()):
|
||||||
fraction = 1.0
|
fraction = 1.0
|
||||||
|
@ -183,7 +183,7 @@ class Material():
|
||||||
|
|
||||||
print('Writing material data to file %s'%saveFile)
|
print('Writing material data to file %s'%saveFile)
|
||||||
f=open(saveFile,'w')
|
f=open(saveFile,'w')
|
||||||
f.write(str(self))
|
f.write(str(self)+'\n') #newline at end
|
||||||
f.close()
|
f.close()
|
||||||
return saveFile
|
return saveFile
|
||||||
|
|
||||||
|
|
|
@ -139,14 +139,14 @@ class Test():
|
||||||
try:
|
try:
|
||||||
shutil.copy2(self.fileInReference(file),self.fileInCurrent(file))
|
shutil.copy2(self.fileInReference(file),self.fileInCurrent(file))
|
||||||
except:
|
except:
|
||||||
print 'Unable to copy file ', file
|
print 'Reference2Current: Unable to copy file ', file
|
||||||
|
|
||||||
def copy_Current2Current(self,files=[]):
|
def copy_Current2Current(self,files=[]):
|
||||||
for file in files:
|
for file in files:
|
||||||
try:
|
try:
|
||||||
shutil.copy2(self.fileInCurrent(file[0]),self.fileInCurrent(file[1]))
|
shutil.copy2(self.fileInCurrent(file[0]),self.fileInCurrent(file[1]))
|
||||||
except:
|
except:
|
||||||
print 'Unable to copy file ', file
|
print 'Current2Current: Unable to copy file ', file
|
||||||
|
|
||||||
def execute_inCurrentDir(self,cmd):
|
def execute_inCurrentDir(self,cmd):
|
||||||
os.chdir(self.dirCurrent())
|
os.chdir(self.dirCurrent())
|
||||||
|
@ -178,4 +178,4 @@ class Test():
|
||||||
print '%s passed.'%({False: 'The test',
|
print '%s passed.'%({False: 'The test',
|
||||||
True: 'All %i tests'%(len(self.variants))}[len(self.variants) > 1])
|
True: 'All %i tests'%(len(self.variants))}[len(self.variants) > 1])
|
||||||
else:
|
else:
|
||||||
print 'Test %i failed...'%(culprit+1)
|
print ' ********\n * Test %i failed...\n ********'%(culprit+1)
|
||||||
|
|
Loading…
Reference in New Issue