LS Dyna

LS Dyna

Topics related to LS-DYNA, Autodyn, Explicit STR and more.

Autodyn User Subroutine – User variable issue

    • Myunghyun Shin
      Subscriber
      hi, there
      I'm a mechanical engineering student studying autodyn subroutines.
       
      While studying the subroutine, I came across the manual for user variables.
       
      According to the manual, in the case of Euler analysis, there is an 'x' symbol for user variables(VAR01).
       
       
      Does this mean that the results of the subroutine analysis in Euler analysis cannot be called as user variables?
       
      If it's not possible, could you please let me know if there is another way?
       
      thanks and best regards,
      Myunghyun Shin
    • Chris Quan
      Ansys Employee

      VAR.1 to VAR.20 are grid variables that can be defined through Autodyn GUI under User Variables. See attached picture below.

      You can change the User Variable Name from VAR.1 to any user-defined name such as Nodal.Momentum,...... etc. 

      The box "Restart" needs to be checked if you want to save this variable in restart files and plot it in Autodyn Contour Plot and Time History Plot. The box "Transport" needs to be checked if this user variable is used in multi-material Euler solver. The box "Nodal Variable" needs to be checked if this variable is used in unstructured mesh.

      The use of user variables can be found from the sample user subroutine EXEDIT3.f90 in the Section of "7.5. Subroutine EXEDIT3 – 3D" of Autodyn User Subroutine Tutorial, where it demonstrates the use of EXEDIT to store the maximum momentum over time for all Lagrange cells in a model, except Euler. The example is for Autodyn-3D.

       

      • Myunghyun Shin
        Subscriber

        Thanks for your kind response!

        As you advised, studying EXEDIT3 has been very helpful.

        As you mentioned, in the case of Euler analysis, errors occur with EXEDIT3.

        Could you please explain why the subroutine code (EXEDIT3) is not applicable to Euler analysis?

    • Chris Quan
      Ansys Employee

      A single element in Autodyn Multi-material Euler solver could contain multiple materials while a single element of Autodyn Lagrnage solver only contains one material. Thus different technique needs to be used to retrieve material variables for each Euler materials in a multi-material Euler element.

      Detailes can be found from the Section 3.6. "Accessing Multiple Material Data – All IJK Solvers" in Autodyn User Subroutine Tutorial.

      • Myunghyun Shin
        Subscriber

        Thanks a lot

        Actually, I have an additional question about user subroutine.

         

        The code below is the subroutine code I am currently using.

        I have designated variables A, B, C, and D to be stored in VAR01, VAR02, VAR03, VAR04, respectively.

        When using this code for Lagrange analysis, there is no issue with the interpretation.

         

        However, when using it for Euler analysis, an error occurs.

         

        Should VAR01, VAR02, VAR03, VAR04 be stored differently for Euler analysis?

         

        Thanks and best regards,

        Myunghyun Shin

Viewing 2 reply threads
  • The topic ‘Autodyn User Subroutine – User variable issue’ is closed to new replies.