Findmark

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

hi,

I have a set of nodes .I have to find the elements attached to that.

And store it in a variable.

Can anyone tell how to use *findmark  for this.

 

Thanks,

Mahes

Answers

  • llyle_20499
    llyle_20499 New Altair Community Member
    edited August 2017

    Hello Mahes,

     

    #put all node Ids in a mark:

    *createmark nodes 1 5000 285201 285459 286047 286925 286926 286929 286930 286932 

    #All elements attached to nodes, saved in Node Mark 1, will be saved in Elements Mark 2:

     *findmark nodes 1 257 1 elements 0 2

     

    #to set it in a variable

    set elementIDS [hm_getmark elements 2]

    puts $elementIDS

     

    Please refer *findmark documentation for more details :http://www.altairhyperworks.com/hwhelp/Altair/2017/help/hm_ref_guide/topics/reference/hm/_findmark.htm

     

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited August 2017

    hi livillyle,

    Thanks ....

  • tinh
    tinh Altair Community Member
    edited August 2017

    Hi,

    another way is to use *createmark directly, like this:

    eval *createmark elems 1 {'by node'} 5000 285201 285459 286047 286925 286926 286929 286930 286932

    set ElemList [hm_getmark elems 1]

    #puts $ElemList

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited September 2017

    Hi,

    Thanks Super tinh.