General Mechanical

General Mechanical

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

Extracting K, U and F from ansys

    • Jacopo Bardiani
      Subscriber

      I desire to extract the stiffness matrix, the boundary conditions and the vector of loads from a simple static analysis in ANSYS Mechanical. How I can do that?

    • mrife
      Ansys Employee

      Hi Jacopo

      Well the answer depends on what you want to do with that matrix and two vectors.  And what format do you need these in?

      Mike  

    • Tasos Zacharakis
      Ansys Employee

      Hello Jacopo,

      1.Regarding the stiffness matrix, you can check these links:

      How to extract Stiffness and Mass Matrix in Workbench

      Export the ANSYS Stiffness and Mass Matrix to Text Files

      A modal analysis is required.

      2.Regarding the force vector, you can use a User-Defined result under Solution, with Expression = FVECTORS. After the calculation, you can right click the result -> Export.

      3.Regarding the displacement vector, you can use a User-Defined result under Solution, with Expression = UVECTORS. After the calculation, you can right click the result -> Export.

      These guidelines will provide you all the tools that you need.

      Thank you,

      Tasos

    • mrife
      Ansys Employee

      Hi Jacopo & Tasos

      FVECTORS are the reaction force vectors and not applied loads, which I think Jacopo is asking for but should verify please.  Also take care as the DOF terms in the stiffness matrix have an internal order that does not necessarily match the external oder.  So usually when someone wants the stiffness matrix implied is that they need the order mapping vector as well.  Mike

    • Jacopo Bardiani
      Subscriber

      Hi Mike and Tasos,

      thank you very much for the support and the replies! Absolutely, I need the applied loads! My idea is to extract data (K, U and F) and then being able to solve U = K^(-1) * F with the same results provided by the software. After that, I'm going to create reduced order model.

      For the second doubts of Mike, yes! I need something that "matches" the numbers of nodes I see in ANSYS, in order to control what I'm done. For instance, for node 1 in the model, the first raws and columns of K are corresponding to the dofs of the node 1. Same for F!

      Let me know,

      Jacopo

    • mrife
      Ansys Employee

      Hi Jacopo

      What are you using to solve?  I ask as the PyAnsys Math application can dump out the matrices into Numpy and SciPy formats easily.  (It is using Mechanical APDL behind the scenes.)  

      Otherwise see the pdf attached to the first link Tasos supplied.  And see the *DMAT, *SMAT, and WRFULL commands in the Mechancial APDL help.  WRFULL allows us to stop an analysis after assembling the full file if a actual solve is not necessary...though if you are comparing you'll need to do the solve anyway.

      Mike

Viewing 5 reply threads
  • The topic ‘Extracting K, U and F from ansys’ is closed to new replies.