anchor.diff:     TYPE(ExtPtfm_InputType),             INTENT(INOUT) :: u(:)        !< Inputs at t
      REAL(DbKi),                          INTENT(IN   ) :: utimes(:)   !< times of input
      TYPE(ExtPtfm_ParameterType),         INTENT(IN   ) :: p           !< Parameters
  -   TYPE(ExtPtfm_ContinuousStateType),   INTENT(INOUT) :: x           !< Continuous states at t on input at t + dt on output
  +   TYPE(ExtPtfm_ContinuousStateType),   INTENT(INOUT) :: x           !< Continuous states at t on input at t + dt on output ! TODO TODO TODO IN
      TYPE(ExtPtfm_DiscreteStateType),     INTENT(IN   ) :: xd          !< Discrete states at t
      TYPE(ExtPtfm_ConstraintStateType),   INTENT(IN   ) :: z           !< Constraint states at t (possibly a guess)
      TYPE(ExtPtfm_OtherStateType),        INTENT(INOUT) :: OtherState  !< Other states at t on input at t + dt on output
  
positive.code:    m%uFlat(10:12) = u%PtfmMesh%RotationVel   (:,1)
     m%uFlat(13:15) = u%PtfmMesh%TranslationAcc(:,1)
     m%uFlat(16:18) = u%PtfmMesh%RotationAcc   (:,1)
     !write(*,*)'x%qm',x%qm
     !write(*,*)'x%qmdot',x%qmdot
     !write(*,*)'m%uFlat',m%uFlat
     !write(*,*)'m%F_at_t',m%F_at_t(6+1:6+p%nCB)
     !write(*,*)'K22',p%K22
     !write(*,*)'C22',p%C22
     !write(*,*)'M21',p%M21
     !write(*,*)'C21',p%C21
  
  
     dxdt%qm= x%qmdot
     ! \ddot{x2} = -K22 x2 - C22 \dot{x2}  - C21 \dot{x1} - M21 \ddot{x1} + fr2
     dxdt%qmdot = - matmul(p%K22,x%qm) - matmul(p%C22,x%qmdot) &
                  - matmul(p%C21,m%uFlat(7:12)) - matmul(p%M21, m%uFlat(13:18)) + m%F_at_t(6+1:6+p%nCB)
  CONTAINS
      logical function Failed()
          CALL SetErrStatSimple(ErrStat, ErrMsg, 'ExtPtfm_CalcContStateDeriv')
  
negative.code:       enddo
        ! LinNames_x
        do I=1,p%nCB; 
            InitOut%LinNames_x(I)       = 'Mode '//trim(Num2LStr(p%ActiveCBDOF(I)))//' displacement, -';
            InitOut%LinNames_x(I+p%nCB) = 'Mode '//trim(Num2LStr(p%ActiveCBDOF(I)))//' velocity, -';
        enddo
        ! 
  