BurgAlgorithm { public boolean solve(IReadDataBlock x, int m) { this.x = new double[x.getLength()]; x.copyTo(this.x, 0); return calc(m); }  boolean solve(IReadDataBlock x, int m); IReadDataBlock getCoefficients(); double[] residuals();  }
@Test public void test() { ArimaModelBuilder builder = new ArimaModelBuilder(); int n = 240, m = 10; for (int i = 0; i < m; ++i) { double[] x = builder.generate(builder.createModel(Polynomial.of(new double[]{1, -.7, .5}), Polynomial.ONE, 1), n); BurgAlgorithm burg = new BurgAlgorithm(); assertTrue(burg.solve(new ReadDataBlock(x), 30)); } }