Export yarn path
Moderators: Martin, Developers
Export yarn path
Hi!
Is there any script available to export the yarn paths (and perhaps points of the cross section) of a given textile?
Thanks!.
Is there any script available to export the yarn paths (and perhaps points of the cross section) of a given textile?
Thanks!.
Re: Export yarn path
Hi,
I don't know of a script that does this but you can use yarn.GetMasterNodes() to get the specified nodes or yarn.GetSlaveNodes() to get the intermediate nodes determined by the interpolation.
From the slave nodes you can use the CSlaveNode::GetSectionPoints function which will return a vector of XYZ points.
I am part way through editing a scripting guide which was started by a colleague last year. I really need to get it finished...
Hope that helps,
Louise
I don't know of a script that does this but you can use yarn.GetMasterNodes() to get the specified nodes or yarn.GetSlaveNodes() to get the intermediate nodes determined by the interpolation.
From the slave nodes you can use the CSlaveNode::GetSectionPoints function which will return a vector of XYZ points.
I am part way through editing a scripting guide which was started by a colleague last year. I really need to get it finished...
Hope that helps,
Louise
Re: Export yarn path
louisepb wrote:Hi,
I don't know of a script that does this but you can use yarn.GetMasterNodes() to get the specified nodes or yarn.GetSlaveNodes() to get the intermediate nodes determined by the interpolation.
From the slave nodes you can use the CSlaveNode::GetSectionPoints function which will return a vector of XYZ points.
I am part way through editing a scripting guide which was started by a colleague last year. I really need to get it finished...
Hope that helps,
Louise
Thanks. How actually CSlaveNode::GetSectionPoints works? Is it possible to get such a list of points (in the centerline) and export it to text?
Thanks,
/UOMO.
Re: Export yarn path
Hi Uomo,
The yarn.GetSlaveNodes() function will return a list of a set of points along the yarn centreline, created by the interpolation function using the master nodes. The number of slave nodes is determined by the yarn resolution.
The SlaveNode.GetSectionPoints() function returns the yarn cross-section at a given slave node in the form of a set of XYZ points around the perimeter of the section. The cross-section is assumed to be normal to the yarn tangent at that point.
Hope that helps,
Louise
The yarn.GetSlaveNodes() function will return a list of a set of points along the yarn centreline, created by the interpolation function using the master nodes. The number of slave nodes is determined by the yarn resolution.
The SlaveNode.GetSectionPoints() function returns the yarn cross-section at a given slave node in the form of a set of XYZ points around the perimeter of the section. The cross-section is assumed to be normal to the yarn tangent at that point.
Hope that helps,
Louise
Re: Export yarn path
I will take on that Louis, thank you.
By coincidence, have you ever tried to export the model/geometry to a meshing tool like (e.g. GMSH?) to have more control in the meshing? (add holes, voids, etc.?).
Best,
/UOMO.
By coincidence, have you ever tried to export the model/geometry to a meshing tool like (e.g. GMSH?) to have more control in the meshing? (add holes, voids, etc.?).
Best,
/UOMO.
louisepb wrote:Hi Uomo,
The yarn.GetSlaveNodes() function will return a list of a set of points along the yarn centreline, created by the interpolation function using the master nodes. The number of slave nodes is determined by the yarn resolution.
The SlaveNode.GetSectionPoints() function returns the yarn cross-section at a given slave node in the form of a set of XYZ points around the perimeter of the section. The cross-section is assumed to be normal to the yarn tangent at that point.
Hope that helps,
Louise
Re: Export yarn path
Hi Uomo,
Some of the researchers here export geometries as stp or iges files and then use Hypermesh to do the meshing. They then use the TexGen model to obtain the Vf and orientation data for the elements generated. I haven't used GMSH but it looks like it could be worth investigating. The problem with generating meshes of composites is always the very small areas created where yarns meet.
Best regards,
Louise
Some of the researchers here export geometries as stp or iges files and then use Hypermesh to do the meshing. They then use the TexGen model to obtain the Vf and orientation data for the elements generated. I haven't used GMSH but it looks like it could be worth investigating. The problem with generating meshes of composites is always the very small areas created where yarns meet.
Best regards,
Louise
Re: Export yarn path
louisepb wrote:Hi Uomo,
Some of the researchers here export geometries as stp or iges files and then use Hypermesh to do the meshing. They then use the TexGen model to obtain the Vf and orientation data for the elements generated. I haven't used GMSH but it looks like it could be worth investigating. The problem with generating meshes of composites is always the very small areas created where yarns meet.
Best regards,
Louise
Thank you Louis...
I'm very interested in such a procedure... Having a mesh of a woven composite, to obtain the orientation of each element... is it described in any example/manual/thesis?
Thank you!.
/UOMO.
Re: Export yarn path
Hi Uomo,
You can obtain the orientations by using one of the CTextile::GetPointInformation functions shown here: http://texgen.sourceforge.net/api/class ... xtile.html
Given a vector of points the function returns a corresponding vector of point information, one of the members being the orientation at that point.
The way it has been used here (and unfortunately I don't think the script is available to be shared is as follows:
1. Create TexGen model
2. Export as IGES/STP
3. Use exported file to create mesh in Hypermesh
4. Extract the centre points of the mesh element
5. Call TexGen GetPointInformation using list of centre points to get orientations.
I hope that helps,
Louise
You can obtain the orientations by using one of the CTextile::GetPointInformation functions shown here: http://texgen.sourceforge.net/api/class ... xtile.html
Given a vector of points the function returns a corresponding vector of point information, one of the members being the orientation at that point.
The way it has been used here (and unfortunately I don't think the script is available to be shared is as follows:
1. Create TexGen model
2. Export as IGES/STP
3. Use exported file to create mesh in Hypermesh
4. Extract the centre points of the mesh element
5. Call TexGen GetPointInformation using list of centre points to get orientations.
I hope that helps,
Louise
Re: Export yarn path
louisepb wrote:Hi Uomo,
You can obtain the orientations by using one of the CTextile::GetPointInformation functions shown here: http://texgen.sourceforge.net/api/class ... xtile.html
Given a vector of points the function returns a corresponding vector of point information, one of the members being the orientation at that point.
The way it has been used here (and unfortunately I don't think the script is available to be shared is as follows:
1. Create TexGen model
2. Export as IGES/STP
3. Use exported file to create mesh in Hypermesh
4. Extract the centre points of the mesh element
5. Call TexGen GetPointInformation using list of centre points to get orientations.
I hope that helps,
Louise
Thank you Louis for your fast response.
Let's assume that I have my mesh done in other software... and I know as well the geometrical center of each element.
With this information, can I get the orientations? Is it necessary to define to which Yarn the element belongs to and if it is orientated parallel to X or Y direction?
Thank you.
/UOMO.
Re: Export yarn path
Hi Uomo,
You can use your list of centre points as the input for the GetPointInformation function. The orientations will be returned in the point information vector that is returned from the function. As you will see there are two versions of the function, one of which sends the yarn number. Use this function if you know which yarn the points are in as it is faster, otherwise it just takes a bit longer to work it out. It doesn't need to know if it's oriented parallel to the x or y direction.
Best regards,
Louise
You can use your list of centre points as the input for the GetPointInformation function. The orientations will be returned in the point information vector that is returned from the function. As you will see there are two versions of the function, one of which sends the yarn number. Use this function if you know which yarn the points are in as it is faster, otherwise it just takes a bit longer to work it out. It doesn't need to know if it's oriented parallel to the x or y direction.
Best regards,
Louise
Re: Export yarn path
It sounds great... I'll look at it.louisepb wrote:Hi Uomo,
You can use your list of centre points as the input for the GetPointInformation function. The orientations will be returned in the point information vector that is returned from the function. As you will see there are two versions of the function, one of which sends the yarn number. Use this function if you know which yarn the points are in as it is faster, otherwise it just takes a bit longer to work it out. It doesn't need to know if it's oriented parallel to the x or y direction.
Best regards,
Louise
Thanks!
Best,
/UOMO.