double B = Math.log(getTopP() / getBotP())
/ Math.log((radiusOfEarth - getTopDepth())
/ (radiusOfEarth - getBotDepth()));
double sqrtTopTopMpp = Math.sqrt(getTopP() * getTopP() - p * p);
double sqrtBotBotMpp = Math.sqrt(getBotP() * getBotP() - p * p);
<BUG>timedist.distRadian = (Math.atan2(p, sqrtBotBotMpp) - Math.atan2(p,
</BUG>
sqrtTopTopMpp))
/ B;
<BUG>timedist.time = (sqrtTopTopMpp - sqrtBotBotMpp) / B;

if(timedist.distRadian < 0.0 || timedist.time < 0.0
|| Double.isNaN(timedist.time) || Double.isNaN(timedist.distRadian)) {
throw new SlownessModelException("timedist <0.0 or NaN: "</BUG>
+ "\n RayParam= " + p + "\n topDepth = " + getTopDepth()

double B = Math.log(getTopP() / getBotP())
/ Math.log((radiusOfEarth - getTopDepth())
/ (radiusOfEarth - getBotDepth()));
double sqrtTopTopMpp = Math.sqrt(getTopP() * getTopP() - p * p);
double sqrtBotBotMpp = Math.sqrt(getBotP() * getBotP() - p * p);
double distRadian = (Math.atan2(p, sqrtBotBotMpp) - Math.atan2(p,
sqrtTopTopMpp))
/ B;
double time = (sqrtTopTopMpp - sqrtBotBotMpp) / B;
if(distRadian < 0.0 || time < 0.0
|| Double.isNaN(time) || Double.isNaN(distRadian)) {
throw new SlownessModelException("timedist <0.0 or NaN: "
+ "\n RayParam= " + p + "\n topDepth = " + getTopDepth()
