/src/main/java/net/finmath/montecarlo/conditionalexpectation/LinearRegression.java
if( basisFunctions.length == 0 ) {
else if ( basisFunctions.length == 2 ) {
if(basisFunctions.length == 0) { return new double[] { }; } else if(basisFunctions.length == 1) { return new double[] { value.mult(basisFunctions[0]).getAverage() / basisFunctions[0].squared().getAverage() }; } <extra_id_0> final double a = basisFunctions[0].squared().getAverage(); final double b = basisFunctions[0].mult(basisFunctions[1]).average().squared().doubleValue(); final double c = b; final double d = basisFunctions[1].squared().getAverage(); final double determinant = (a * d - b * c); if(determinant != 0) {