### Question:
ViewFrustum { public void update(Matrix4f projection, Matrix4f view, Vector3f paramPosition) { position = paramPosition; float[] clip = projection.mul(view).toArray(true); frustum[0][0] = clip[3] - clip[0]; frustum[0][1] = clip[7] - clip[4]; frustum[0][2] = clip[11] - clip[8]; frustum[0][3] = clip[15] - clip[12]; frustum[1][0] = clip[3] + clip[0]; frustum[1][1] = clip[7] + clip[4]; frustum[1][2] = clip[11] + clip[8]; frustum[1][3] = clip[15] + clip[12]; frustum[2][0] = clip[3] + clip[1]; frustum[2][1] = clip[7] + clip[5]; frustum[2][2] = clip[11] + clip[9]; frustum[2][3] = clip[15] + clip[13]; frustum[3][0] = clip[3] - clip[1]; frustum[3][1] = clip[7] - clip[5]; frustum[3][2] = clip[11] - clip[9]; frustum[3][3] = clip[15] - clip[13]; frustum[4][0] = clip[3] - clip[2]; frustum[4][1] = clip[7] - clip[6]; frustum[4][2] = clip[11] - clip[10]; frustum[4][3] = clip[15] - clip[14]; frustum[5][0] = clip[3] + clip[2]; frustum[5][1] = clip[7] + clip[6]; frustum[5][2] = clip[11] + clip[10]; frustum[5][3] = clip[15] + clip[14]; }  void update(Matrix4f projection, Matrix4f view, Vector3f paramPosition); boolean intersects(Cuboid c); boolean contains(Vector3f vec);  }### Answer:
@Test public void testUpdate() { Matrix4f projection = Matrix4f.createPerspective(70, 16 / 9.0f, 1, 2000); Matrix4f view = Matrix4f.createLookAt(new Vector3f(0, 0, 0), new Vector3f(0, 0, 1000), Vector3f.UP); frustum.update(projection, view, new Vector3f(0, 0, 0)); assertEquals(new Vector3f(0, 0, 0), frustum.position); }
@Test public void testIntersectsFalse() { Matrix4f projection = Matrix4f.createPerspective(70, 16 / 9.0f, 1, 2000); Matrix4f view = Matrix4f.createLookAt(new Vector3f(0, 0, 0), new Vector3f(0, 0, 1000), Vector3f.UP); frustum.update(projection, view, new Vector3f(0, 0, 0)); Vector3f[] vertices = new Vector3f[8]; vertices[0] = new Vector3f(-32, -32, -16); vertices[1] = new Vector3f(-16, -32, -16); vertices[2] = new Vector3f(-16, -16, -16); vertices[3] = new Vector3f(-32, -16, -16); vertices[4] = new Vector3f(-32, -32, -32); vertices[5] = new Vector3f(-16, -32, -32); vertices[6] = new Vector3f(-16, -16, -32); vertices[7] = new Vector3f(-32, -16, -32); Cuboid c = mock(Cuboid.class); when(c.getVertices()).thenReturn(vertices); }