docs: public double[] solve(double[] b) {
      if(b.length != m) {
        throw new IllegalArgumentException(ERR_MATRIX_DIMENSIONS);
      }
      if(!this.isNonsingular()) {
        throw new ArithmeticException(ERR_SINGULAR);
      }
      double[] bc = new double[piv.length];
      for(int i = 0; i < piv.length; i++) {
        bc[i] = b[piv[i]];
      }
      solveInplace(bc);
      return n < bc.length ? Arrays.copyOf(bc, n) : bc;
    }