anchor.diff:     INTEGER(IntKi):: j ! Index counter
      INTEGER(IntKi):: temp_id ! Index counter
      INTEGER(IntKi):: allo_stat ! Allows for an error code return
  +   INTEGER(IntKi)          :: ErrStat2                     ! Temporary Error status
  +   CHARACTER(ErrMsgLen)    :: ErrMsg2                      ! Temporary Error message
  +   CHARACTER(*), PARAMETER :: RoutineName = 'BD_GenerateStaticElementForce'
   
      dof_elem = dof_node * node_elem
      rot_elem = (dof_node/2) * node_elem
  
positive.code:    INTEGER(IntKi)                  :: j
     INTEGER(IntKi)                  :: temp_id
     INTEGER(IntKi)                  :: allo_stat
  
     dof_elem = dof_node * node_elem
     rot_elem = (dof_node/2) * node_elem
  
negative.code:                temp6(:) = 0.0D0
                 temp6(1:3) = y%BldMotion%TranslationAcc(1:3,temp_id2)
                 temp6(4:6) = y%BldMotion%RotationAcc(1:3,temp_id2)
                 temp6(1:3) = MATMUL(TRANSPOSE(p%GlbRot),temp6(1:3))
                 temp6(4:6) = MATMUL(TRANSPOSE(p%GlbRot),temp6(4:6))
             ENDIF
             OtherState%Acc(temp_id+1:temp_id+6) = temp6(1:6)
         ENDDO
  