Skip to content

Commit

Permalink
0.9.3
Browse files Browse the repository at this point in the history
Linux binaries removed from distribution
Contact between parts added
  • Loading branch information
spacether committed Jun 10, 2015
1 parent 7a06336 commit 3c81f1b
Show file tree
Hide file tree
Showing 24 changed files with 137 additions and 1,531 deletions.
27 changes: 14 additions & 13 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -237,19 +237,20 @@ TODO:
Add tutorial videos
Update pdf
Improve Pylint Scores:
feamodel: 9.28
geometry: 9.02
results_file: 9.75 X
part: 9.64 X
selector 9.89 X
mesh: 9.66 X
loads: 9.80 X
cadimporter 9.71 X
problem: 9.82 X
base_classes: 9.51 X
components: 10.0 X
material: 10.0 X
environment 9.39 X
feamodel 9.28
geometry 9.02
results_file 9.75
part 9.64
selector 9.89
mesh 9.66
loads 9.80
cadimporter 9.71
problem 9.82
base_classes 9.51
components 10.0
material 10.0
environment 9.39
connectors 9.57

Future Goals:
-CAD import of: brep, step, iges
Expand Down
Binary file modified dist/documentation.zip
Binary file not shown.
Binary file modified dist/examples.zip
Binary file not shown.
Binary file modified dist/pycalculix-0.9.3.zip
Binary file not shown.
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-
#
# pycalculix documentation build configuration file, created by
# sphinx-quickstart on Wed May 6 15:10:54 2015.
# sphinx-quickstart on Tue Jun 9 21:27:50 2015.
#
# This file is execfile()d with the current directory set to its
# containing dir.
Expand Down
2 changes: 1 addition & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
.. pycalculix documentation master file, created by
sphinx-quickstart on Wed May 6 15:10:54 2015.
sphinx-quickstart on Tue Jun 9 21:27:50 2015.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
Expand Down
12 changes: 9 additions & 3 deletions examples/pinned-plate.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import pycalculix as pyc

# Model of a pinned plate with 3 pins
# one wil be force, the other will be fixity
# one will be force, the others will be fixed
proj_name = 'pinned-plate'
model = pyc.FeaModel(proj_name)
model.set_units('in')
Expand All @@ -12,7 +12,7 @@
pin2 = [pin1[0], 4]
pin3 = [4, 8]

# dimentions for drawing parts
# dimensions for drawing parts
pinhole_rad = 0.25
pin_rad = pinhole_rad - .015
width_plate = 1
Expand Down Expand Up @@ -91,7 +91,7 @@
factor = 5 # can be between 5 and 50
kval = youngs*factor
for (pin, hole) in zip(pins, holes):
model.set_contact_linear(pin, hole, kval)
model.set_contact_linear(pin, hole, kval, True)

# mesh the model
model.set_eshape('tri', 2)
Expand All @@ -111,3 +111,9 @@
for field in fields:
fname = proj_name+'_'+field
prob.rfile.nplot(field, fname, display=False)

model.view.select(part)
model.view.allsel_under('parts')
for field in fields:
fname = proj_name+'_PART_'+field
prob.rfile.nplot(field, fname, display=False)
27 changes: 18 additions & 9 deletions examples/pipe-crush-elastic.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
pipe_wall_th = .00887 # wall thickness
rad_inner = rad_outer - pipe_wall_th
pipe_length = 10*rad_outer
e_size = pipe_wall_th/4.0
wall_elements = 4.0
e_size = pipe_wall_th/wall_elements
disp = False

# Draw pipe, x, y = radial, axial
pipe = pyc.Part(model)
Expand All @@ -34,10 +36,10 @@
num_plate_eles = int(round(plate_bottom.length()/e_size,0))

# view model
model.plot_geometry(proj_name+'_geometry')
model.plot_parts(proj_name+'_parts')
model.plot_areas(proj_name+'_areas')
model.plot_lines(proj_name+'_lines')
model.plot_geometry(proj_name+'_geometry', display=disp)
model.plot_parts(proj_name+'_parts', display=disp)
model.plot_areas(proj_name+'_areas', display=disp)
model.plot_lines(proj_name+'_lines', display=disp)

# set loads and constraints
model.set_constr('fix',pipe.left,'y')
Expand All @@ -63,12 +65,12 @@
model.set_eshape('quad', 2)
model.set_etype('plstrain', pipe, pipe_length)
model.set_etype('plstrain', plate, pipe_length)
model.set_ediv(['L1','L3', 'L4', 'L6'], 4) # set element divisions
model.set_ediv(['L1','L3', 'L4', 'L6'], wall_elements) # set element divisions
model.set_ediv(['L0','L2'], num_arc_eles) # set element divisions
model.set_ediv(['L5','L7'], num_plate_eles)
model.mesh(1.0, 'gmsh') # mesh 1.0 fineness, smaller is finer
model.plot_elements(proj_name+'_elem') # plot part elements
model.plot_constraints(proj_name+'_constr')
model.plot_elements(proj_name+'_elem', display=disp) # plot part elements
model.plot_constraints(proj_name+'_constr', display=disp)

# make and solve the model
prob = pyc.Problem(model, 'struct')
Expand All @@ -79,4 +81,11 @@
fields = fields.split(',')
for field in fields:
fname = proj_name+'_'+field
prob.rfile.nplot(field, fname, display=False)
prob.rfile.nplot(field, fname, display=disp)

model.view.select(pipe)
model.view.allsel_under('parts')

for field in fields:
fname = proj_name+'_PIPE_'+field
prob.rfile.nplot(field, fname, display=disp)
Binary file modified pycalculix/__pycache__/connectors.cpython-34.pyc
Binary file not shown.
Binary file modified pycalculix/__pycache__/feamodel.cpython-34.pyc
Binary file not shown.
Binary file modified pycalculix/__pycache__/mesh.cpython-34.pyc
Binary file not shown.
Loading

0 comments on commit 3c81f1b

Please sign in to comment.