Right implements Degrees<T> { @Override public Number resolve(final InnerProduct<T> product) { return Math.PI / 2; }  @Override Number resolve(final InnerProduct<T> product);  }
@Test public void resolvesRightAngle() { final double error = 1.e-6; final MkField<Object> field = new MkField<>(new Object(), new Object()); MatcherAssert.assertThat( new Right<>().resolve(field.product()).doubleValue(), Matchers.closeTo(Math.PI / 2, error) ); MatcherAssert.assertThat( new IsRight<>(new Right<>()).resolve(field), Matchers.is(true) ); MatcherAssert.assertThat( new IsFlat<>(new Right<>()).resolve(field), Matchers.is(false) ); }