Skip to content

Commit 68fcdba

Browse files
author
Teseo Schneider
committed
updated the scripts for new module
1 parent 85d9554 commit 68fcdba

File tree

3 files changed

+12
-16
lines changed

3 files changed

+12
-16
lines changed

python/bending.py renamed to test/bending.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33

44

5-
mesh_path = "/../3rdparty/data/square_beam.mesh"
5+
mesh_path = "../3rdparty/data/square_beam.mesh"
66
tag_path = "../3rdparty/data/square_beam.txt"
77

88
settings = pf.Settings()
Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,23 @@
1-
import polyfempy
1+
import polyfempy as pf
22
import numpy as np
3-
import Settings
4-
import Problems
53

64

75

86

9-
solver = polyfempy.Solver()
7+
solver = pf.Solver()
108

119

1210
#some setup
1311
mesh_path = "../3rdparty/data/circle2.msh"
1412
output = "inflation.obj"
1513

16-
settings = Settings.Settings()
14+
settings = pf.Settings()
1715
settings.discr_order = 2
1816
settings.normalize_mesh = True
1917
settings.vismesh_rel_area = 0.00001
20-
settings.scalar_formulation = polyfempy.ScalarFormulations.Laplacian
18+
settings.scalar_formulation = pf.ScalarFormulations.Laplacian
2119

22-
problem = Problems.GenericScalar()
20+
problem = pf.GenericScalar()
2321
problem.add_dirichlet_value("all", 10)
2422
problem.rhs = 0
2523
settings.set_problem(problem)
@@ -35,7 +33,7 @@
3533

3634
# now we got the solution of the first laplacian, we use it as rhs for the second one
3735
# setup zero bc and use sol as rhs
38-
problem = Problems.GenericScalar()
36+
problem = pf.GenericScalar()
3937
problem.add_dirichlet_value("all", 0)
4038
problem.rhs = 0
4139
settings.set_problem(problem)

python/torsion.py renamed to test/torsion.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
1-
import polyfempy
2-
import Settings
3-
import Problems
1+
import polyfempy as pf
42

53

64

75

86

97
mesh_path = "../3rdparty/data/square_beam_h.HYBRID"
108

11-
settings = Settings.Settings()
9+
settings = pf.Settings()
1210
settings.discr_order = 1
1311
settings.normalize_mesh = False
1412

@@ -18,9 +16,9 @@
1816
settings.set_material_params("nu", 0.35)
1917

2018
settings.nl_solver_rhs_steps = 5
21-
settings.tensor_formulation = polyfempy.TensorFormulations.NeoHookean
19+
settings.tensor_formulation = pf.TensorFormulations.NeoHookean
2220

23-
problem = Problems.Torsion()
21+
problem = pf.Torsion()
2422
problem.fixed_boundary = 5
2523
problem.turning_boundary = 6
2624
problem.axis_coordiante = 2
@@ -32,7 +30,7 @@
3230
settings.set_problem(problem)
3331

3432

35-
solver = polyfempy.Solver()
33+
solver = pf.Solver()
3634

3735

3836
solver.settings(settings.serialize())

0 commit comments

Comments
 (0)