Fixed some mathematical details