Tcl command to get Surfaces names

Altair Forum User
Altair Forum User
Altair Employee
edited October 2020 in Community Q&A

Hi all,

I have imported geometry from a CATPart into HyperMesh and now I am trying to get the names of the surfaces in the model.

I am using following commands and till now have no success. (I can get the IDs of surfaces e.g. 1,2,3,4 ..)

 *createmark surfs 1 all set surfsList [hm_getmark surfs 1] hm_getentityvalue surfs 2 name 1 -byid

The first two commands return results (hm_getmark returns the IDs of surfaces: 1,2,3,4,5). However the last command (hm_getentityvalue from Reference manual)  doesn't return anything at all, (not even any error). 

My goal is to get the names of the surfaces (via any Tcl command). I will be very thankful for any help.

 

Best regards,

Mubeen

Tagged:

Answers

  • Q.Nguyen-Dai
    Q.Nguyen-Dai Altair Community Member
    edited May 2017

    I can't found surface 'name' in Data Names help doc:

    surface.png.e2b51521cc6d077cc577e3146da90086.png

  • tinh
    tinh Altair Community Member
    edited May 2017

    Yes surface is not a named hypermesh entity.

    If you tagged the surf in catia. Maybe the tag will be imported into hm as metadata. Try searching it by:

    set md [hm_metadata findall]

    puts [join [lsearch -all -inline -glob $md 'surfs $surfID *'] \n]

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited May 2017

    Yes surface is not a named hypermesh entity.

    If you tagged the surf in catia. Maybe the tag will be imported into hm as metadata. Try searching it by:

    set md [hm_metadata findall]

    puts [join [lsearch -all -inline -glob $md 'surfs $surfID *'] \n]

     

    Thanks tinh, it works.

    The surfaces which are tagged in CATIA can now be recognized in HyperMesh.

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited July 2018

    @Mubeen

    I'm having a similar problem but with Rhino instead of CATIA. Do you mind telling me what file type you use to export and how you're tagging the surfaces in the program?

     

    Thank you,

    Alex