General Mechanical

General Mechanical

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

How to Retrieve Contact Area as Elemental Values in Ansys Mechanical?

    • hugo.hennion
      Subscriber

      Hello everyone,

      I'm currently studying contact behavior in Ansys Mechanical and have set up my models using the following parameters:

      • Contact Formulation: Augmented Lagrange
      • Detection Method: Nodal - Projected Normal From Contact

      My objective is to retrieve the contact area for each element in contact, and I’m specifically looking for a way to obtain this data as elemental values. I am already familiar with:

      • Solution Information Tracker: Contact - Force Convergence 
      • Commands: CONTNMISC58, CONTNMISC59, CONTNMISC60, CONTNMISC61, and CONTNMISC184

      However, I was unsuccessfull with thoses methodologies. I'm not certain if there is a direct method to extract the contact area as elemental data rather than as a whole contact region. Does anyone have experience with this or know of a workaround to access the contact area on an element-by-element basis? Any scripts, command recommendations, or insights into post-processing techniques would be greatly appreciated!

      Thank you!

    • Deepak
      Ansys Employee

       

      Hi, 

      If you are looking for contact area calculation, please feel free to this forum discussion: Contact Area Calculation in Mechanical

      or if you are looking at contact areas by individual elements, please try this scprit:

       

      Allsel,all
      /SOLU
      SOLVE

      /POST1
      SET,LAST
      cmsel,s,contact_side            !Define the name selection of contact side
      ESLN,,

      ESEL,R,TYPE,,3                     !selects contact elements (target elements would be 4, see solver information)
      ETABLE,ELSTAT,CONT,STAT             !stores contact status
      ESEL,S,ETAB,ELSTAT,2,3             !selects element in contact (stat=2 sliding,stat=3 sticking)
      ETABLE,CONT_AREA,VOLU                 !selects contact element area (volume is calculated for unite thickness for 2D elements)
      SSUM                             !sum area
      *GET,TOT_AREA,SSUM,0,ITEM,CONT_AREA     !store result in parameter
      MY_AREA=TOT_AREA                 !print area as result

      /output,res_sp,txt                !Opens results file stores the Contact area and Status
      PRETAB,ELSTAT,CONT_AREA,
      /out

       

      Regards,

      Deepak K.

      Guidelines for Posting on Ansys Learning Forum

       

      How to access the ANSYS Online Help
      • Deepak
        Ansys Employee

         

        Results file:

         

    • hugo.hennion
      Subscriber

      Hello Deepak,

      Thank you so much for providing the script! I tried it, and it works well in terms of retrieving an area value for each contact element.

      However, I noticed that when I sum up all the values from the script, the total doesn’t match the overall contact area shown in the Contact Area Tracker. This makes me wonder if the script is providing the area of the contact elements rather than the actual contact area per element.

      Could you clarify if that’s the case, or if there’s a way to retreive to reflect the true contact area?

      Thanks again for your help!

      • Deepak
        Ansys Employee
        Here I included only sliding and sticking element, 
        ESEL,S,ETAB,ELSTAT,2,3             !selects element in contact (stat=2 sliding,stat=3 sticking)

        To include all types of contact elements (far,near,sliding,sticking), you can change the ESEL to:
        ESEL,S,ETAB,ELSTAT,0,3             !selects element in contact.

        Thanks,
        Deepak
    • hugo.hennion
      Subscriber

      Hello Deepak,

       

      Thank you for your response and the updated version of the script! I really appreciate the time you took to help me refine this.

       

      Apologies for the delay in getting back to you; I wanted to ensure I had a thorough understanding before replying. I conducted a detailed investigation to isolate the behavior, and I set up a simplified model with just two CONTA174 elements and two TARGE170 elements that are not fully overlapping. This way, the contact area is intentionally not equal to the combined area of the CONTA174 elements. (in the screenshot below there is only the element faces of 2 TET10 elements that are selected for the Contact and Target Bodies)

      Using the latest version of your script, I summed up all the CONT_AREA values in the ETABLE. Interestingly, this total doesn't match the Tracker Contacting Area value. Instead, it almost exactly matches the combined area of the CONTA174 elements when calculated directly from the LOC_DEF User Defined Results.

       

      This has led me to believe that CONT_AREA from ETABLE might represent the area attributed to CONTA174 elements specifically, rather than the actual area of contact as shown by the Tracker.

       

      Thanks again for the support, and I’d be very interested in hearing any further insights you might have on this!

      • Deepak
        Ansys Employee

        Yes, that's true, the script calculates the area associated with contact elements by their contact status as a selection criteria. In your case, refining the mesh size helps the script to calculate the area accurately.

        Thanks,

        Deepak

    • hugo.hennion
      Subscriber

      Thank you for your answer. It makes more sense now. 

      Is there any other way of recovering the contact area as an elemental value? Or is using this script on a very fine mesh is the only way? 

      Thanks, 

      Hugo

       

       

      • Deepak
        Ansys Employee

        It's difficult to find data, as the area will be associated with the key points (vertices) of the element. But I was thinking of finding the area by multiplying the elemental area by the elemental contact area for overlapping areas.

        In the end, Elemental Area  = Contact area (same as the script). Whereas for overlapping Element's Area = Contact area * Status value.

Viewing 4 reply threads
  • You must be logged in to reply to this topic.