How to select nodes/elements which belong to a line

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

Dear all,

 

I'm struggling with a TCL code. The problem is that I need to select and count in automatic way nodes which belong to a specific line.

Usually I have a meshed surface and need to count nodes on one specific line. The line number is always known and stored in a variable.

 

My initial idea to count elements/nodes was following:


*createmark elems 1 “Which belong to a line” “line no”
set elemIds [hm_getmark elems 1]
set numElems [llength $elemIds]

Do you have any ides how to solve that problem?

Thank you in advance.

 

Best regards

Jakub

Tagged:

Answers

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited September 2015

    Hi Jakub,

     

    maybe below commands can help.

     

    *createmark lines 

    *findmark lines 1 1 1 nodes 0 2

    *createmark nodes 

  • tinh
    tinh Altair Community Member
    edited September 2015

    Hi,

    I read help about '*createmark' and there is an option

    *createmark nodes 1 'by lines' lineid1 lineid2,...

     

    But i am not sure it works or not. so please try this

    image/emoticons/default_wink.png' alt=';)' srcset='/emoticons/wink@2x.png 2x' width='20' height='20'>

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited September 2015

    Hi,

    I read help about '*createmark' and there is an option

    *createmark nodes 1 'by lines' lineid1 lineid2,...

     

    But i am not sure it works or not. so please try this

    image/emoticons/default_wink.png' alt=';)' srcset='/emoticons/wink@2x.png 2x' width='20' height='20'>

     

    Thank you for the tip. Just missed that entry in the hypermesh help image/emoticons/default_smile.png' alt=':)' srcset='/emoticons/smile@2x.png 2x' width='20' height='20'>