for (int i = 0; i < n - 2; i++) {
tStrikes = Arrays.copyOfRange(strikes, i, i + 3);
tVols = Arrays.copyOfRange(impliedVols, i, i + 3);
final Function1D<DoubleMatrix1D, DoubleMatrix1D> func = getVolDiffFunc(forward, tStrikes, expiry, tVols);
final Function1D<DoubleMatrix1D, DoubleMatrix2D> jac = getVolJacFunc(forward, tStrikes, expiry, beta);
final NonLinearTransformFunction tf = new NonLinearTransformFunction(func, jac, TRANSFORM);
final DoubleMatrix1D res = rootFinder.getRoot(tf.getFittingFunction(), tf.getFittingJacobian(), start);
final double[] root = TRANSFORM.inverseTransform(res).getData();
modelParams[i] = new SABRFormulaData(new double[] {root[0], beta, root[1], root[2] });
}
}