public function testTranslateWillEventuallyReturnAMatrix() { $mA = new Matrix([[1, 2], [3, 4]]); $f = function ($x, $y, $v) { return [$x + 1, $y + 1, $v + 1]; }; $vS = $this->object->fromMatrix($mA)->translate($f); $rebasedM = $vS->toMatrix(); $this->assertEquals([[2, 3], [4, 5]], $rebasedM->toArray()); $notRebasedM = $vS->toMatrix(false); $this->assertEquals([1 => [1 => 2, 2 => 3], 2 => [1 => 4, 2 => 5]], $notRebasedM->toArray()); }