complexMultiply method

void complexMultiply(
  1. Float64x2List other
)

Complex multiplies each element of other onto each element of this list.

This method modifies this array, rather than allocating a new array. The other array must have the same length as this one.

Implementation

void complexMultiply(Float64x2List other) {
  if (other.length != length) {
    throw ArgumentError('Input is the wrong length.', 'other');
  }
  for (int i = 0; i < length; ++i) {
    final a = this[i];
    final b = other[i];
    this[i] = a.scale(b.x) + Float64x2(-a.y, a.x).scale(b.y);
  }
}