anchor.diff:  
               ! Set rotation
               ! NOTE: RotateZMatrixT is the rotation from local to global.
  -         RotateZMatrixT(:,1) = (/  cos(InitInp%PtfmRefztRot(ThisBodyNum)), -sin(InitInp%PtfmRefztRot(ThisBodyNum)) /)
  -         RotateZMatrixT(:,2) = (/  sin(InitInp%PtfmRefztRot(ThisBodyNum)),  cos(InitInp%PtfmRefztRot(ThisBodyNum)) /)
  +         RotateZMatrixT(:,1) = (/  cos(InitInp%PtfmRefztRot(IBody)), -sin(InitInp%PtfmRefztRot(IBody)) /)
  +         RotateZMatrixT(:,2) = (/  sin(InitInp%PtfmRefztRot(IBody)),  cos(InitInp%PtfmRefztRot(IBody)) /)
   
               ! Loop through all the frequencies
            DO J=1,InitInp%NStepWave2
  
positive.code:          RETURN
        END IF
  
        DO ThisBodyNum = 1,p%NBody
  
              ! Set orientation and position for each body in mesh
           theta       = (/ 0.0_R8Ki, 0.0_R8Ki, InitInp%PtfmRefztRot(ThisBodyNum)/)      ! angle in radians
           orientation = EulerConstruct(theta)
           XYZloc      = (/InitInp%PtfmRefxt(ThisBodyNum), InitInp%PtfmRefyt(ThisBodyNum), InitInp%PtfmRefzt(ThisBodyNum)/)
  
              ! Create the node on the mesh
           CALL MeshPositionNode (u%Mesh, ThisBodyNum, XYZloc, ErrStatTmp, ErrMsgTmp, orientation )
           CALL SetErrStat( ErrStatTmp, ErrMsgTmp, ErrStat, ErrMsg, RoutineName)
  
              ! Create the mesh element
           CALL MeshConstructElement (  u%Mesh, ELEMENT_POINT, ErrStatTmp, ErrMsgTmp, ThisBodyNum )
           CALL SetErrStat( ErrStatTmp, ErrMsgTmp, ErrStat, ErrMsg, RoutineName)
        ENDDO
  
  
negative.code:       INTEGER(IntKi)                                     :: ThisDim              !< Counter to currrent dimension
        INTEGER(IntKi)                                     :: J                    !< Generic counter
        INTEGER(IntKi)                                     :: Idx                  !< Generic counter
        REAL(R8Ki)                                         :: theta(3)             !< rotation about z for the current body (0 about x,y)
        REAL(R8Ki)                                         :: orientation(3,3)     !< Orientation matrix for orientation of the current body
        REAL(ReKi)                                         :: XYZloc(3)            !< Starting position of this WAMIT2 body
  
  
  