Fixing triangle point calculation