public void testCentroid() {
Vec2D a = new Vec2D(-100, 0);
Vec2D b = new Vec2D(0, 100);
Vec2D c = new Vec2D(100, 0);
Triangle2D t = new Triangle2D(a, b, c);
ReadonlyVec2D centroid = t.computeCentroid();
assertTrue("incorrect centroid",
centroid.equals(new Vec2D(0, 100).scaleSelf(1f / 3)));
}
public void testClockwise() {