## 7.3. Subroutine EXALE

The listing below shows the contents of the file EXALE.F90, used to define the ALE motion of a part whereby each I-column remains parallel to the Y-axis and the nodes are equally spaced along the column.

    SUBROUTINE EXALE (IREZ,JREZ,NREZ,XREZ,YREZ)

           USE mdgrid
           USE kindef
           USE locsub
           USE wrapup

           IMPLICIT NONE

           INTEGER (INT4) ::   IREZ,   JREZ,   NREZ
           REAL (REAL8)   ::   XREZ,   YREZ

           INTEGER (INT4) ::  IJMAX,     IJ
           REAL (REAL8)   ::    DYB

    !      ******************************************************************
    !
    !      THIS SUBROUTINE COMPUTES THE CONSTRAINED GRID VELOCITIES FOR
    !      VERTICES ASSIGNED THE "USER" MOTION CONSTRAINT
    !
    !      INPUT PARAMETERS:
    !
    !         IREZ - I INDEX FOR VERTEX TO BE CONSTRAINED
    !         JREZ - J INDEX FOR VERTEX TO BE CONSTRAINED
    !         NREZ - PART # FOR VERTEX TO BE CONSTRAINED
    !         XREZ - CURRENT X-COORDINATE OF VERTEX
    !         YREZ - CURRENT Y-COORDINATE OF VERTEX
    !
    !      OUTPUT PARAMETERS:
    !
    !         XREZ - CONSTRAINED X-COORDINATE OF VERTEX
    !         YREZ - CONSTRAINED Y-COORDINATE OF VERTEX
    !
    !      ******************************************************************
    !
    !      THIS LOGIC SETS THE X-COORDINATE OF EACH VERTEX (I,J) TO THE
    !      X-VALUE AT VERTEX (I,JMAX) AND EQUALLY SPACES THE Y-COORDINATES
    !      BETWEEN (I,1) AND (I,JMAX)
    !
           IJMAX = IJSET(IREZ,JMAX)
           IJ    = IJSET(IREZ,JREZ)
           XREZ  = XN(IJMAX)
           DYB   = YN(IJMAX)/FLOAT(JMAX-1)
           YREZ  = DYB*FLOAT(JREZ-1)
    !
    !      TERMINATION OF SUBROUTINE EXALE
           RETURN
           END SUBROUTINE EXALE

Release 18.2 - © ANSYS, Inc. All rights reserved.