Jump to content


  • Content Count

  • Joined

  • Last visited

About Jeffrey

  • Rank

Recent Profile Visitors

1074 profile views
  1. Hello, I'm currently at a point where HyperMesh seems to run out of options, or I want to do more than HyperMesh was designed for. I'm experimenting with Nastran's glue contact surfaces, with attributes BSURF, BSURFS and BGSET. Now, I have already created funcionality in HyperMesh for BSURF(S) and BGSET, but now I want to create a custom connector to use this functionality in HyperMesh. I have a construction made out of several layers of shell or solid elements and I want to 'glue' all the intermediate surfaces/solids to eachother. Seeing from the functionality for, for example, bolts, HyperMesh is capable of realising connections with purely the connector location, the to be attached components/surfs/elems and a tolerance value. Of course, information of the type of connection is required as well, but many are preset. Now I'd like to create my own custom connector, allowing me to input the to be connected contactsurfs and a tolerance value, and let HyperMesh figure out which contactsurf should be connected to which other contactsurf. After that, it should all be formatted in the NASTRAN's BSURF(S) and BGSET. Now the latter can be arranged via a post processing script that you can add to the FECONFIG.cfg file. My question is, is the former (creating a custom connector) possible to users in HyperMesh, or is it solely purposed for Altair development? Thank you for your time and help. Jeffrey PS. Please see the attachment. I want to be able to select contactsurfs 1, 2, 3 and 4. The idea is that contactsurf 2 is connected to 1. Contactsurf 3 is connected to 2, etc. This functionality is already present in bolt creation, that's why I want to make use of the HyperMesh connectors rather than write a MATLAB script to do the same.
  2. Hello Mario, I think the string length is limited. I've created a workaround, grouping ranges of values together. The string created is far smaller than the original string and it does create the string via this method. Nonetheless, I've checked the items inside $elems and the information is just numbers, element ID numbers. How and where could I check the maximum length of *createstringarray? Thank you, Jeffrey
  3. Hello Mario, The "$" was a typo from my side. It appears that the $elements variable that is created in HyperMesh causes an error, while using a user created variable with set numbers seem to work perfectly: set elements {213 5342 53 213 642}; set str [subst {\$BSURF 1 $elements}]; *createstringarray 3 "\$beginbsurfs" $str "\$endbsurfs" Works. The following does not: $elems is a list created in HyperMesh by means of a TCL script. This is just an ordinary but lengthy list. set str [subst {\$BSURF 1 $elems}]; *createstringarray 3 "\$beginbsurfs" $str "\$endbsurfs" Maybe the error window output gives more insight of what the problem is? 0 while executing "*createstringarray 3 "\$beginbsurfs" $str "\$endbsurfs"" ("uplevel" body line 1) invoked from within "uplevel #0 {*createstringarray 3 "\$beginbsurfs" $str "\$endbsurfs"}" invoked from within "interp eval $::tkcon::OPT(exec) $args" (procedure "::tkcon::EvalSlave" line 2) invoked from within "EvalAttached $cmd" Thanks for your help and time. Jeffrey
  4. Hello, I have written a TCL script that selects certain elements in my mesh. I want to have these elements put into a string array, so I can use this array to update a certain NASTRAN card, in comments, so I can use them later on in a different routine. The problem now, however, is whenever I try to use *createstringarray it gives back a 0 in the left corner. The string is in a variable that needs to be substituted into *createstring array: set elements {213 5342 53 213 642}; set $str [subst {\$BSURF 1 $elements}]; (Note that the BSURF is commented via $, hence the backslash) *createstringarray 3 "\$beginbsurfs" $str "\$endbsurfs" This following procedure returns a zero. What am I doing wrong? Thank you for your help and time! Jeffrey
  5. Hello, I have solved the problem by selecting multiple surfaces to trim. Thanks, Jeffrey
  6. Hell Tinh, Thank you for your response. To answer your question: I am not generating two surfs with the same ID. The small circular piece just takes the value of the next surf, renumbering the next surf to the max surf id. That's why things go bad. I've tried your method to select surfs by geomid, but no surfs are selected no matter what I try. Regards, Jeffrey
  7. Hello, Thank you in advance for reading this and for your help. I am currently working on a project where I create a geometry and eventually mesh this geometry in HyperMesh. The key here is, that I use Matlab to generate my TCL/HM code (since the working force here is more aquainted with Matlab than with the TCL code. This code uses certain input parameters and generate information that can be translated to HyperMesh. Now I am at the point where the whole geometry creation using HM/TCL goes perfectly fine, even after some setbacks where I had to cleverly write the program due to the lack of control on the node, line and surface numbering. I'm stuck at the point where I create holes in my geometry, where certain other parts can connect to. The geometry consists of several suppressed edges. These edges do not influence the shape of the geometry, like edges that will change the angle of the geometry will; these suppressed edges just lie in the same plane but are used to create the geometry. The surfaces are all numbered in the sequence of generation, so the first generated surface has ID 1, second has ID 2, etc. I create holes by creating a node at the location where the hole centre should be, create a circle with a given radius around it, trim the existing surface with the line and eventually deleting this circular surface, creating a hole. Note again, this is all done by programming, not by using the GUI. Whenever these circles, hence the trimming, do not intersect with a suppressed edge, everything goes fine. It creates a nice hole in my surface, which has that certain ID. Whenever said circle intersects with a suppressed edge, things go wrong. Say there is a piece of the circle that crosses that suppressed edge. What I would want, is that the surface created by trimming would simply get the newest maximum surface ID. What happens instead, is that the surface gets the ID of the one it is partly intersecting. You must understand, that from a programming point of view, this gives me no control whatsoever of the surface IDs that come after, hence my program fails there. Now, I have thought of ideas on how to counter this problem. For example, I could create a component for every generated surface, and assign it a name, giving me control of the names and not having to look at the IDs of the surfaces anymore. This is not such elegant solution. Instead, I'd like to use different means to solve the problem, for example, by using the ID of the last created surface, rather than the max surface ID. My question to you is, what would you do to solve this problem? Would you go for the component solution? Are there query commands that I haven't looked at? Are there macros to solve this problem? Any help is appreciated. I've added some screenshots that hopefully clarify my situation. Thank you for any help that is supplied! Jeffrey This will yield no problems, there is no intersection: This will yield problems, as there is an intersection: Note that in both cases, these edges are suppressed!
  • Create New...