dot method

Value dot(
  1. ValueVector other
)

Implementation

Value dot(ValueVector other) {
  assert(values.length == other.values.length);
  Value result = Value(0.0);
  for (int i = 0; i < values.length; i++) {
    result += values[i] * other.values[i];
  }
  return result;
}