Matrix.opBinary

Multiply two matrices.

Given a matrix of size (m, n) and a matrix of size (o, p). This operation can only work if n == o. The resulting matrix will be size (m, p).

  1. Matrix!(Number, rowCount, columnCount) opBinary(ref const(Matrix!(OtherNumber, rowCount, columnCount)) other)
  2. Matrix!(Number, rowCount, columnCount) opBinary(const(Matrix!(OtherNumber, rowCount, columnCount)) other)
  3. Matrix!(Number, rowCount, otherColumnCount) opBinary(ref const(Matrix!(OtherNumber, otherRowCount, otherColumnCount)) other)
    struct Matrix(Number, size_t _rowCount, size_t _columnCount)
    @safe pure nothrow
    Matrix!(Number, rowCount, otherColumnCount)
    opBinary
    const
    (
    string op
    OtherNumber
    size_t otherRowCount
    size_t otherColumnCount
    )
    (
    ref const(Matrix!(OtherNumber, otherRowCount, otherColumnCount)) other
    )
    if (
    (op == "*") &&
    (columnCount == otherRowCount)
    &&
    is(OtherNumber : Number)
    )
    if (
    isNumeric!Number &&
    _rowCount > 0
    &&
    _columnCount > 0
    )
  4. Matrix!(Number, rowCount, otherColumnCount) opBinary(const(Matrix!(OtherNumber, otherRowCount, otherColumnCount)) other)

Parameters

other
Type: const(Matrix!(OtherNumber, otherRowCount, otherColumnCount))

Another matrix

Return Value

Type: Matrix!(Number, rowCount, otherColumnCount)

The product of two matrices.

Meta