Element ID - if MAT8 => PCOMP + MID5

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

Hi,

 

Here is my problem.

I have an element ID. If I get a MAT8, I would like to get the PCOMP ID.
And thanks to PCOMP ID, the MID5, and then, G11, G22, G33, G12.

 

However, I tried to use hm_getentityvalue elems elementid propertyid 0 -byid, but it seems to return an incorrect ID for the property.
I followed advices searching in templates files the information about hm_getentityvalue function to get propertyid but each (propertyid, collector.propertyid, property.id...) returns an ID of 809 instead of 3xxxxxxx.

 

If you have some information, thanks for help ! image/emoticons/default_smile.png' alt=':)' srcset='/emoticons/smile@2x.png 2x' width='20' height='20'>

 

 

 

old problem beside_________________________________________________________

 

SYNTAX
hm_getentityvalue entity_type entity_name_or_id data_name output_type ?search_type?


I was looking for hm_getentityvalue function.

However, in the reference guide, we can't find any information about data names.

 

I would like to get the X1/X2/X3 of CBUSH element, but I don't know the data_name for this.

 

If you have any ideas !... image/emoticons/default_wink.png' alt=';)' srcset='/emoticons/wink@2x.png 2x' width='20' height='20'>

Thanks !

Answers

  • tinh
    tinh Altair Community Member
    edited November 2013

    Hi,

    as in my previous post

    just some data  names  specified by hypermesh (you can search 'data names' in help)

    others are solver specified (and so stored in attributes)

    to know solver-specified data names, you should look for them in output template

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited November 2013

    Thanks for your post.
    However, in Nastran output templates, there is no cbush.tpl file but only cbush1d.tpl. The difference between both is exactly what I need, X1/X2/X3 coordinates of the orientation vector, that are missing on CBUSH1D card. image/emoticons/default_sad.png' alt=':(' srcset='/emoticons/sad@2x.png 2x' width='20' height='20'>

  • tinh
    tinh Altair Community Member
    edited November 2013

    did you find out the attrib file?

    main template file usually link to an attrib file in which every neccessary solver-specified data names will be defined

    i think they will look like the text appeared in card editor, forexample 'X1', 'X2', 'X3'  (with some prefix or suffix perhaps), please check it

     

    remember that everything you see in card editor were written in template files, if something missing then you could not see, so please check it again

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited November 2013

    I found attrib.lst file, but there is nothing inside.
    Only CID for CBUSH1D but nothing about X1, X2, X3 coordinates for CBUSH. :/

    Edit: I may have something in general2, I'll take a look to that !

  • tinh
    tinh Altair Community Member
    edited November 2013

    no no Cya pls.

    I am sorry for my mistake that I did not read all hypermesh data names of cbush

    the data names are 'vector' and 'vectorid'

    you can get x1, x2, x3 of cbush by refer to 'vector.xcomp', .ycomp, .zcomp

    hm_getentityvalue elems $cbushid vector.xcomp 0 -byid

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited November 2013

    Yes, I found it too in general2 ! Thanks for your help ! 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 November 2013

    I have a new problem described in the first post !

    If you have something to help... image/emoticons/default_wink.png' alt=';)' srcset='/emoticons/wink@2x.png 2x' width='20' height='20'>

  • tinh
    tinh Altair Community Member
    edited November 2013

    it's internal id (hypermesh-specified ID)

    and the ID appears in browser is solver id

    you can use hm_getsolverid props $internalid 

    => will return 3xxxxxxx same as in browser

     

    another way, search in template file for solver-specified data name of property id, and use that data name  in stead of property.id