EqualizationLUT { double[] getCoefficients(int bandIndex, int detectorIndex) { final Map<Integer, double[]> coefMap = coefficientsMapList.get(bandIndex); return coefMap.get(detectorIndex); } EqualizationLUT(Reader[] bandCoefficientReaders);   }
@Test public void testGetCoefficients() throws IOException { Reader[] readers = new Reader[2]; readers[0] = new StringReader("1.0 2.0 3.0\n4.0 5.0 6.0"); readers[1] = new StringReader("0.1 0.2 0.3\n0.4 0.5 0.6"); final EqualizationLUT lut = new EqualizationLUT(readers); double[] expected = {1.0, 2.0, 3.0}; compare(expected, lut.getCoefficients(0, 0)); expected = new double[]{4.0, 5.0, 6.0}; compare(expected, lut.getCoefficients(0, 1)); expected = new double[]{0.1, 0.2, 0.3}; compare(expected, lut.getCoefficients(1, 0)); expected = new double[]{0.4, 0.5, 0.6}; compare(expected, lut.getCoefficients(1, 1)); }