🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

Getting the length of multiple RBE2 elements at a time

User: "Altair Forum User"
Altair Employee
Updated by Altair Forum User

I have created an assembly model with around 200 RBE2 connections.

My requirement is to measure the length of all the RBE2 element and save it as text or excel file.

The number of RBE2 elements will vary from project to project.

Is there any TCL script to measure the length of displayed RBE2 element and save the details as required.

Or is there any other method to make the process simple by displaying the length of all the RBE2 element on screen, so that the length can be checked visually.

 

Thanks,

Prabhu P

 

Find more posts tagged with

Sort by:
1 - 6 of 61
    User: "tinh"
    Altair Community Member
    Updated by tinh

    Hi,

    Try:

    *createmark elems 1 'by config' rigid rigidlink

    set ElemLengthValues [hm_getmarkvalue elems 1 length 0]

    User: "Altair Forum User"
    Altair Employee
    OP
    Updated by Altair Forum User

    Hi Tinh,

     

    That worked really good. Thank you.

    But it is giving the output of all the RBE2 elements.

    Is it possible to get the values of on screen displayed elements alone.

    User: "tinh"
    Altair Community Member
    Updated by tinh

    Hi

    the code is like this

    *createmark elems 1 'by config' rigid rigidlink

    *createmark elems 2 displayed

    *markintersection elems 1 elems 2

    set ElemLengthValues [hm_getmarkvalue elems 1 length 0]

    User: "Altair Forum User"
    Altair Employee
    OP
    Updated by Altair Forum User

    Tinh,

     

    That's really awesome. Very helpful.

    I have one more request.

    Is it possible to tag the values to the respective element.

    Sample image is provided. In this image, the element number is displayed near to the respective element.

    Like wise, is it possible to get the values near to the respective element..

    <?xml version="1.0" encoding="UTF-8"?>sample.PNG

    User: "tinh"
    Altair Community Member
    Updated by tinh

    Yes, it is possible.

    The code is like this:

    *createmark elems 1 'by config' rigid rigidlink

    *createmark elems 2 displayed

    *markintersection elems 1 elems 2

    set ElemLengthValues [hm_getmarkvalue elems 1 length 0]

    set ElemList [hm_getmark elems 1]

    foreach LengthValue $ElemLengthValues ElemID $ElemList {

         *tagcreate elems $ElemID [format %.3f $LengthValue] $ElemID 2

    }

    User: "Altair Forum User"
    Altair Employee
    OP
    Updated by Altair Forum User

    Hi Tinh,

     

    This worked perfectly.....

     

    Thank you for the support....