User-defined nonlinear equations

This user subroutine allows the user to insert his/her own nonlinear equations (also called Multiple Point Constraints or MPC's). The driver routine is “nonlinmpc.f”. For each new type of equation the user can define a name, e.g. FUN (maximum length 80 characters). To be consistent, the user subroutine should be called umpc_fun and stored in “umpc_fun.f”. In file “nonlinmpc.f” the lines

            elseif(labmpc(ii)(1:4).eq.'USER') then
               call umpc_user(aux,aux(3*maxlenmpc+1),const,
     &            aux(6*maxlenmpc+1),iaux,n,fmpc(ii),iit,idiscon)

should be duplicated and user (USER) replaced by fun (FUN).

It is assumed that the nonlinear equation is a function of the displacements only. Then it can generally be written as

$\displaystyle f(u_1,u_2,u_3,....,u_n)=0$ (649)

where $ u_i$ represents the displacement in node $ n_i$ in direction $ l_i$. Nonlinear equations are solved by approximating them linearly and using an iterative procedure. It is the linearization which must be provided by the user in the subroutine. Assume we arrived at an intermediate solution $ u^0_1,u^0_2,....u^0_n$. Then the above equation can be linearly approximated by:

$\displaystyle f(u^0_1,u^0_2,....,u^0_n)+\sum_{i=1}^{i=n}\left. \frac{\partial f}{\partial u_i} \right\vert _0 (u_i-u^0_i)=0$ (650)

For more details the user is referred to [19]. To use a user-defined equation its name must be specified on the line beneath the keyword *MPC, followed by a list of all the nodes involved in the MPC. This list of nodes is transferred to the user routine, as specified by the following header and input/output variables of the umpc_user routine:

      subroutine umpc_user(x,u,f,a,jdof,n,force,iit,idiscon)
!     updates the coefficients in a user mpc
!     INPUT:
!     x(3,n)             Carthesian coordinates of the nodes in the
!                        user mpc.
!     u(3,n)             Actual displacements of the nodes in the
!                        user mpc.     
!     jdof               Actual degrees of freedom of the mpc terms
!     n                  number of terms in the user mpc
!     force              Actual value of the mpc force
!     iit                iteration number
!     OUTPUT:
!     f                  Actual value of the mpc. If the mpc is
!                        exactly satisfied, this value is zero
!     a(n)               coefficients of the linearized mpc
!     jdof               Corrected degrees of freedom of the mpc terms
!     idiscon            0: no discontinuity
!                        1: discontinuity
!                        If a discontinuity arises the previous
!                        results are not extrapolated at the start of
!                        a new increment

The subroutine returns the value of f ( $ f(u^0_1,u^0_2,....,u^0_n)$), the coefficients of the linearization ( $ \left. \frac{df}{du_i}
\right\vert _0$) and the degrees of freedom involved.

The parameter idiscon can be used to specify whether a discontinuity took place. This usually means that the degrees of freedom in the MPC changed from the previous call. An example of this is a gap MPC. If a discontinuity occurred in an increment, the results (displacements..) in this increment are NOT extrapolated to serve as an initial guess in the next increment.

An example is given next.