comments and cleanup
correction in calculation of failure time
test added