### Question:
DefaultEllipsoid extends AbstractShape3D implements Ellipsoid { @Override public Vector3d getTangent(Vector3d normal) { return localToModel(normalToLocal(normal).getNormalized()); } DefaultEllipsoid();  DefaultEllipsoid(double radius, double radius2, double radius3);  DefaultEllipsoid(Vector3d center, double radius, double radius2, double radius3);  DefaultEllipsoid(Vector3d center, Vector3d xAxis, Vector3d yAxis, Vector3d zAxis); @Override Vector3d directionToLocal(Vector3d direction); @Override Vector3d directionToModel(Vector3d direction); @Override double getBoundingRadius(); @Override Vector3d getCenter(); @Override double getHeading(Vector3d location, Vector3d direction); @Override Vector3d getIntersection(Ray3d ray); @Override long getSizeBytes(); @Override Vector3d getTangent(Vector3d normal); @Override Vector3d getXAxis(); @Override Vector3d getYAxis(); @Override Vector3d getZAxis(); @Override boolean isSphere(); @Override Vector3d localToModel(Vector3d position); @Override Vector3d modelToLocal(Vector3d position); @Override Vector3d normalToLocal(Vector3d normal); @Override String toString();  }### Answer:
@Test public void testGetTangent() { double sqrt2 = Math.sqrt(2.); double sqrt3 = Math.sqrt(3.); Vector3d center = new Vector3d(3., 4., 13.); Vector3d xAxis = new Vector3d(.5, -sqrt3 * .5, 0.); Vector3d yAxis = new Vector3d(sqrt3 / sqrt2, 1. / sqrt2, sqrt2); Vector3d zAxis = new Vector3d(-sqrt3, -1., 2.); Ellipsoid ell = new DefaultEllipsoid(center, xAxis, yAxis, zAxis); double x = .5; double y = .5; double z = Math.sqrt(5.5); double normalX = 4. * x / y; double normalY = 1.; double normalZ = .5 * z / y; double x2 = x * .5 + (y - z) * sqrt2 * sqrt3 * .25; double y2 = -x * sqrt3 * .5 + (y - z) * sqrt2 * .25; double z2 = (y + z) * sqrt2 * .5; double normalX2 = normalX * .5 + (normalY - normalZ) * sqrt2 * sqrt3 * .25; double normalY2 = -normalX * sqrt3 * .5 + (normalY - normalZ) * sqrt2 * .25; double normalZ2 = (normalY + normalZ) * sqrt2 * .5; Vector3d targetPoint = new Vector3d(x2, y2, z2).add(center); Vector3d planeNormal = new Vector3d(normalX2, normalY2, normalZ2).getNormalized(); Vector3d tangentPoint = ell.getTangent(planeNormal); Assert.assertEquals(targetPoint, tangentPoint); Vector3d reversedNormal = planeNormal.multiply(-1.); Vector3d tangentPoint2 = ell.getTangent(reversedNormal); Vector3d targetPoint2 = new Vector3d(-x2, -y2, -z2).add(center); Assert.assertEquals(targetPoint2, tangentPoint2); }