anchor.diff:  !! ! when a consensus on the definition of "average velocity" is determined, this function will be
   !! ! removed.  InpPosition(2) should be the rotor radius; InpPosition(3) should be hub height
   !! !----------------------------------------------------------------------------------------------------
  -!! 
  +!!
   !!       ! Passed variables
  -!! 
  +!!
   !!    REAL(ReKi), INTENT(IN)     :: Time
   !!    REAL(ReKi), INTENT(IN)     :: InpPosition(3)
   !!    INTEGER, INTENT(OUT)       :: ErrStat
  -!! 
  +!!
   !!       ! Function definition
   !!    REAL(ReKi)                 :: InflowWind_ADhack_diskVel(3)
  -!! 
  +!!
   !!       ! Local variables
   !!    TYPE(InflIntrpOut)         :: NewVelocity             ! U, V, W velocities
   !!    REAL(ReKi)                 :: Position(3)
   !!    INTEGER                    :: IY
   !!    INTEGER                    :: IZ
  -!! 
  -!! 
  +!!
  +!!
   !!    ErrStat = 0
  -!! 
  +!!
   !!    SELECT CASE ( ParamData%WindFileType )
   !!       CASE (HH_Wind)
  -!! 
  +!!
   !! !      VXGBAR =  V * COS( DELTA )
   !! !      VYGBAR = -V * SIN( DELTA )
   !! !      VZGBAR =  VZ
  -!! 
  +!!
   !!          Position    = (/ REAL(0.0, ReKi), REAL(0.0, ReKi), InpPosition(3) /)
   !!          NewVelocity = HH_Get_ADHack_WindSpeed(Time, Position, ErrStat)
  -!! 
  +!!
   !!          InflowWind_ADhack_diskVel(:) = NewVelocity%Velocity(:)
  -!! 
  -!! 
  +!!
  +!!
   !!       CASE (FF_Wind)
   !! !      VXGBAR = MeanFFWS
   !! !      VYGBAR = 0.0
   !! !      VZGBAR = 0.0
  -!! 
  +!!
   !!          InflowWind_ADhack_diskVel(1)   = FF_GetValue('MEANFFWS', ErrStat)
   !!          InflowWind_ADhack_diskVel(2:3) = 0.0
  -!! 
  +!!
   !!       CASE (UD_Wind)
   !! !      VXGBAR = UWmeanU
   !! !      VYGBAR = UWmeanV
   !! !      VZGBAR = UWmeanW
  -!! 
  +!!
   !!          InflowWind_ADhack_diskVel(1)   = UsrWnd_GetValue('MEANU', ErrStat)
   !!          IF (ErrStat /= 0) RETURN
   !!          InflowWind_ADhack_diskVel(2)   = UsrWnd_GetValue('MEANV', ErrStat)
   !!          IF (ErrStat /= 0) RETURN
   !!          InflowWind_ADhack_diskVel(3)   = UsrWnd_GetValue('MEANW', ErrStat)
  -!! 
  +!!
   !!       CASE (FD_Wind)
   !! !      XGrnd = 0.0
   !! !      YGrnd = 0.5*RotDiam
  
positive.code: !  1 Aug 2012    v1.01.00a-bjj                              B. Jonkman
  ! 10 Aug 2012    v1.01.00b-bjj                              B. Jonkman
  !----------------------------------------------------------------------------------------------------
  !  
  !..................................................................................................................................
  ! LICENSING
  ! Copyright (C) 2012  National Renewable Energy Laboratory
  !
  !    This file is part of InflowWind.
  !
  !    InflowWind is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as 
  !    published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
  !
  !    This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty
  !    of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
  !    
  !    You should have received a copy of the GNU General Public License along with InflowWind.  
  !    If not, see <http://www.gnu.org/licenses/>.
  !    
  !**********************************************************************************************************************************
  
     USE                              NWTC_Library
  
negative.code:    SELECT CASE ( ParamData%WindFileType )
        CASE (HH_Wind)
  
           CALL HH_SetLinearizeDels( LinPerturbations, ErrStat, ErrMsg )
  
        CASE ( FF_Wind, UD_Wind, FD_Wind, HAWC_Wind )
  
  