We have an exciting announcement about badges coming in May 2025. Until then, we will temporarily stop issuing new badges for course completions and certifications. However, all completions will be recorded and fulfilled after May 2025.
General Mechanical

General Mechanical

Topics related to Mechanical Enterprise, Motion, Additive Print and more.

Assigning 1 matid to Multiple Solid Bodies

    • jmwarre2
      Subscriber
      Hello all,I am working with a model that contains many solid bodies connected in various ways. I am using EKILL and EALIVE to activate and deactivate the elements in certain bodies at various load steps. Is there a way to assign many solid bodies to the same matid with a command snippet? I am using the following command snippets under each solid body. n solid_1=matid (under body 1)n solid_2=matid (under body 2)n etc. etc.nnI then use following command snippets in the Static Structural (A5) branch of the Project tree.n esel,s,matid,,solid_1n ekill,alln allseln esel,s,matid,,solid_2n ekill,alln allseln etc. etc.nnIs there a way to assign multiple solid bodies to the same matid? Meaning, can I use the same command snippet --> solid_1=matid for multiple solid bodies? I've tried to do this, to reduce the labor involved with typing individual command snippets, but ANSYS seems to only recognize the first command snippet in the tree, and the rest are ignored.nThis is an issue for me because my model has hundreds of solid bodies and I'd like to make this more efficient.nThank you very much!nnJustin Warre NCSU Graduate Studentn
    • Govindan Nagappan
      Ansys Employee
      Hi Array nUnder the first body, use the command to store the matid:nsolid_1=matid (under body 1)nCreate a named selection with all the bodies that should have the same material. For example: named selection is called my_bodies. You can insert this under analysis branch(static structural, modal etc)n n /prep7 n cmsel,s,my_bodies,elem           ! Select the elements in named selection called my_bodiesn emodif,all,mat,solid_1           ! Modify the Material for all selected bodies(elements) to solid_1n allseln /Solun n Let me know if this answers your questionn n
Viewing 1 reply thread
  • The topic ‘Assigning 1 matid to Multiple Solid Bodies’ is closed to new replies.