MCordingley\LinearAlgebra\Matrix::concatenateBottom PHP Method

concatenateBottom() public method

public concatenateBottom ( self $other ) : self
$other self
return self
    public function concatenateBottom(self $other) : self
    {
        return $this->spliceRows($this->getRowCount(), 0, $other->toArray());
    }

Usage Example

Example #1
0
 public function testConcatenateBottomWrongSizes()
 {
     $matrixA = new Matrix([[1, 2, 3]]);
     $matrixB = new Matrix([[4], [5], [6]]);
     static::expectException(MatrixException::class);
     $matrixA->concatenateBottom($matrixB);
 }