added dinvgamma source and updated dinvgamma in code