How to create a node in the center by selecting one circular curve?

Altair Forum User
Altair Forum User
Altair Employee
edited May 2022 in Community Q&A

Hi all,

In hypermesh, we can create a node in the center by selecting three node on a circular curve. How can we script this?

 

Roy

Tagged:

Answers

  • tinh
    tinh Altair Community Member
    edited December 2018

    Open command.tcl file you will see the script

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited December 2018

    Open command.tcl file you will see the script

    Hi tinh,

    I know your meaning. When using GUI, the center node can be created by selecting three nodes. How can we create the center node directly by only selecting one circular line not three nodes by using script?

     

    Roy

  • Beta
    Beta New Altair Community Member
    edited December 2018

    Hi Roy,

     

    You may already know this panel

    <?xml version="1.0" encoding="UTF-8"?>image.thumb.png.8b2233a3eb575810117aaa1b463409d9.png

    use it generate nodes on the curve and use generated nodes to create center nodes. do necessary steps then you could find out commands in command.tcl

  • tinh
    tinh Altair Community Member
    edited December 2018

    Hi tinh,

    I know your meaning. When using GUI, the center node can be created by selecting three nodes. How can we create the center node directly by only selecting one circular line not three nodes by using script?

     

    Roy

     

    F8>create node at 'circle center'

  • Pandurang
    Pandurang Altair Community Member
    edited December 2018

    *createmarkpanel lines 1 'Select Line to get center';
    *createbestcirclecenternode lines 1 0 1 0;

    *clearmark lines 1

  • PSiedlaczek
    PSiedlaczek Altair Community Member
    edited May 2022

    #
    # to loop trough many crucial lines at one selection :

    *createmarkpanel lines 1 'Select all lines to put temp-node at center';
    set line_sh [ hm_getmark lines 1 ];
    set ile_li [ llength $line_sh ]

    if { ! [ Null line_list ] } {
      for {set i 0} {$i <$ile_li} {incr i} {
        set liID [ lindex $line_sh $i ] ;
        eval *createmark lines 1 $liID
        *createbestcirclecenternode lines 1 0 1 0;
        *clearmark lines 1
      }
    };
    puts "Enter: tcl is harder than you think"