Skip to content

Commit

Permalink
FEM: ccxInpWriter shouldn't do any validation or guessing
Browse files Browse the repository at this point in the history
Also, there is no need to print material parameters to the console.
User can see that info in dialog box, in .inp file and it's also printed
to console after material has been set.

Signed-off-by: Przemo Firszt <przemo@firszt.eu>
  • Loading branch information
PrzemoF authored and wwmayer committed Apr 27, 2015
1 parent 5e48d62 commit 7036d46
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/Mod/Fem/ccxInpWriter.py
Expand Up @@ -97,14 +97,7 @@ def write_calculix_input_file(self):
for material_object in self.material_objects:
# get material properties
YM = FreeCAD.Units.Quantity(material_object['Object'].Material['YoungsModulus'])
if YM.Unit.Type == '':
print 'Material "YoungsModulus" has no Unit, asuming kPa!'
YM = FreeCAD.Units.Quantity(YM.Value, FreeCAD.Units.Unit('Pa'))
else:
print 'YM unit: ', YM.Unit.Type
print 'YM = ', YM
PR = float(material_object['Object'].Material['PoissonRatio'])
print 'PR = ', PR
material_name = material_object['Object'].Material['Name'][:80]
# write material properties
inpfile.write('*MATERIAL, NAME=' + material_name + '\n')
Expand Down

0 comments on commit 7036d46

Please sign in to comment.