Simon90
Aerospace
- Jun 14, 2019
- 1
I want to make a set with the help of some python code. The coordinates for the set are stored in the list circle list.
The following I tried:
So I stored the coordinates in a tupel. In faces I tried to reference these tupels.
This brings the error "Keyword error on faces" while running the code in python.
I also tried to make a list of tupels and hand over that list of tupels. Attached is the whole code.
The following I tried:
Code:
p = mdb.models['Model-1'].parts['Part-1']
f = p.faces
coordinates_for_faces = tuple()
for i in range(0, len(circleList)):
tuple_coordinates= (circleList[i].center.x, circleList[i].center.y,0.0)
coordinates_for_faces = coordinates_for_faces + tuple_coordinates
print("coordinates_for_faces:", coordinates_for_faces)
faces = f.findAt(*coordinates_for_faces)
p.Set(faces=faces, name='SetOfFibers')
So I stored the coordinates in a tupel. In faces I tried to reference these tupels.
This brings the error "Keyword error on faces" while running the code in python.
I also tried to make a list of tupels and hand over that list of tupels. Attached is the whole code.