I am trying to model a fabric with a 10/12 yarns/cm. So 1mm in one direction and ~ 0.83mm in the other. For now I do not really care about the shape of the sections so I am trying CTextileWeave2D to do it (it is supposed to be able to solve interference problems when you set refine to 1, am I right?).
The thing is that it does create interference on the SwapPositions parts (I tried setting GapSize but it does not work. The interference created is too big for the "solve interference & export to Abaqus" to work and the simulation gives an "Error of excessive overclosure" in the contacts. Any suggestion on how to solve this?
Here is the Script:
Code: Select all
from _Embedded import *
from TexGen.Core import *
from TexGen.Renderer import *
from TexGen.Export import *
from TexGen.WeavePattern import *
from TexGen.WiseTex import *
from TexGen.FlowTex import *
import math
weave = CTextileWeave2D(5, 5, 1, 0.5, 1,1)
weave.SetYarnWidths(1)
weave.SwapPosition(0, 0)
weave.SwapPosition(1, 3)
weave.SwapPosition(2, 1)
weave.SwapPosition(3, 4)
weave.SwapPosition(4, 2)
weave.SetXYarnWidths(0, 1)
weave.SetXYarnHeights(0, 0.2)
weave.SetXYarnSpacings(0, 1)
weave.SetXYarnWidths(1, 1)
weave.SetXYarnHeights(1, 0.2)
weave.SetXYarnSpacings(1, 1)
weave.SetXYarnWidths(2, 1)
weave.SetXYarnHeights(2, 0.2)
weave.SetXYarnSpacings(2, 1)
weave.SetXYarnWidths(3, 01)
weave.SetXYarnHeights(3, 0.2)
weave.SetXYarnSpacings(3, 1)
weave.SetXYarnWidths(4, 1)
weave.SetXYarnHeights(4, 0.2)
weave.SetXYarnSpacings(4, 1)
weave.SetYYarnWidths(0, 0.83)
weave.SetYYarnHeights(0, 0.21)
weave.SetYYarnSpacings(0, 0.83)
weave.SetYYarnWidths(1, 0.83)
weave.SetYYarnHeights(1, 0.21)
weave.SetYYarnSpacings(1, 0.83)
weave.SetYYarnWidths(2, 0.83)
weave.SetYYarnHeights(2, 0.21)
weave.SetYYarnSpacings(2, 0.83)
weave.SetYYarnWidths(3, 0.83)
weave.SetYYarnHeights(3, 0.21)
weave.SetYYarnSpacings(3, 0.83)
weave.SetYYarnWidths(4, 0.83)
weave.SetYYarnHeights(4, 0.21)
weave.SetYYarnSpacings(4, 0.83)
weave.SetGapSize(0)
#weave.SetGapSize(0.001)
weave.AssignDefaultDomain()
textilename = AddTextile(weave)
textile = GetTextile(textilename)
print textile.GetType()
weave =textile.GetWeave()
weave.SetResolution(50)
sectionMesh = CSectionMeshRectangular (4,True)
print sectionMesh.GetType()
weave.AssignSectionMesh(sectionMesh)Thank you,
Sincerely,
Rodrigo