Formula to calculate the volume of a triangular pyramid