🎉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

Query Young's Modulus, Poisson's ratio in Ansys profile

User: "Roshan Shiveshwar"
Altair Community Member
Updated by Roshan Shiveshwar

Hi ,

 

I am trying to query  Young's Moduls, Poisson's ratio of a material Ansys profile.

The following command doesn't seem to work - 

         set E [hm_getvalue materials id=$mat_id dataname=E];         set Nu [hm_getvalue materials id=$mat_id dataname=Nu];

 

I also tried the following

image.png.d2c003d16a153519666ae313d8f32f3b.png

 

Is there any way I can successfuly query all the attributes assigned to the material, irrespective of solver setings?

 

Thanks!

Find more posts tagged with

Sort by:
1 - 7 of 71
    User: "QuyNguyenDai"
    Altair Community Member
    Updated by QuyNguyenDai

    Which 'Card image' do you use for your material?  If you use 'MATERIAL', you can try:

     

     hm_getvalue mat id=1 dataname=MP_EX_VAL2

     

    User: "tinh"
    Altair Community Member
    Updated by tinh

    Hi

    Query attribute name by

    hm_attributelistall mats 3 name

    User: "QuyNguyenDai"
    Altair Community Member
    Updated by QuyNguyenDai

    @tinh: on my 2019.1 Hypermesh, this command does not work. In the help I see:

     hm_attributelistall  Returns a list of all attribute IDs, names, types or type names for the current template.  Syntax : hm_attributelistall value  Type : HyperMesh Tcl Query  Description : Returns a list of all attribute IDs, names, types or type names for the current template. Inputs  value     The type of list to return. Valid values are:      id - the attribute ID      name - the attribute name      type - the attribute type number      typename - the attribute type string 

     

    User: "Roshan Shiveshwar"
    Altair Community Member
    OP
    Updated by Roshan Shiveshwar

    @tinh: on my 2019.1 Hypermesh, this command does not work. In the help I see:

      hm_attributelistall  Returns a list of all attribute IDs, names, types or type names for the current template.  Syntax : hm_attributelistall value  Type : HyperMesh Tcl Query  Description : Returns a list of all attribute IDs, names, types or type names for the current template. Inputs  value     The type of list to return. Valid values are:      id - the attribute ID      name - the attribute name      type - the attribute type number      typename - the attribute type string

     

     

    I think he meant

     hm_attributelist mats 3 name

     

    User: "Roshan Shiveshwar"
    Altair Community Member
    OP
    Updated by Roshan Shiveshwar

    Which 'Card image' do you use for your material?  If you use 'MATERIAL', you can try:

     

      hm_getvalue mat id=1 dataname=MP_EX_VAL2

     

     

    Thanks Q.Nguyen-Dai !

    If the profile was Abaqus, I believe I have to use the following:

     hm_getvalue mat id=1 dataname=Young

    Now, since I want to write a code which is profile independent, I am wondering if there is a generic query command. (Atleast for basic properties such as Density, Young's modulus, Poisson's ratio etc.)

     

    User: "tinh"
    Altair Community Member
    Updated by tinh

    Yes, I am sorry for the mistake!

    I mean hm_attributelist mats 3 name

     

    @Roshan Shiveshwar if you want a generic way, you will have to filter tokens like E , young in attrib names

    As i see, attrib names of profiles are not same. That means you should store them in a dict. 

     

    User: "Roshan Shiveshwar"
    Altair Community Member
    OP
    Updated by Roshan Shiveshwar

    Yes, I am sorry for the mistake!

    I mean hm_attributelist mats 3 name

     

    @Roshan Shiveshwar if you want a generic way, you will have to filter tokens like E , young in attrib names

    As i see, attrib names of profiles are not same. That means you should store them in a dict. 

     

    Yes. Even I felt the same. Create a custom library of required attrib names and use them as needed.