Polynomial f = new Polynomial(
x0 * x0 - y0 * y0 + z0 * z0,
2.0 * (x0 * x1 - y0 * y1 + z0 * z1),
x1 * x1 - y1 * y1 + z1 * z1);
double[] t = f.roots();
if (t.length == 2) {
for (int i = 0; i < 2; i++) {
if (recorder.interval().contains(t[i])) {
Point3 p = ray.pointAt(t[i]);