if ((toColumn - fromColumn) != matrix.rows()) {
fail("Wrong matrix dimensions: " + matrix.rows() + "x" + matrix.columns() +
". Should be: " + (toColumn - fromColumn) + "x_.");
}
ByteVector result = factory.createVector(matrix.columns());
for (int j = 0; j < matrix.columns(); j++) {
byte acc = 0;
ByteVectorIterator it = rowIterator(i, fromColumn, toColumn);
while (it.hasNext()) {
it.next();
final byte prod = aTimesB(it.get(), matrix.get(it.index() - fromColumn, j));
acc = aPlusB(acc, prod);
}
result.set(j, acc);
}
return result;
}