!        Generated by TAPENADE     (INRIA, Ecuador team)
!  tapenade 3.x
!
!  Differentiation of lin_interpol in reverse (adjoint) mode (with options noISIZE i8):
!   gradient     of useful results: lin_interpol
!   with respect to varying inputs: da db
!>    @brief linear interpolation
!>    @param[in] da value A
!>    @param[in] db value B
!>    @param[in] dp relative position
!>    @param[in] dd (delta) cell size
!>    @return linear interpolated value
SUBROUTINE LIN_INTERPOL_AD0(da, da_ad, db, db_ad, dp, dd, &
& lin_interpol_ad)
  IMPLICIT NONE
!       da: value A; db: value B; dp: relative position; dd: (delta) cell size
  DOUBLE PRECISION :: da, db, dp, dd
  DOUBLE PRECISION :: da_ad, db_ad
  DOUBLE PRECISION :: lin_interpol
  DOUBLE PRECISION :: lin_interpol_ad
  da_ad = (dd-dp)*lin_interpol_ad/dd
  db_ad = dp*lin_interpol_ad/dd
END SUBROUTINE LIN_INTERPOL_AD0

