test.php 248 B

12345678910111213141516171819
  1. <?php
  2. include __DIR__ . '/../classes/Bootstrap.php';
  3. $grid1 = [
  4. [1, 3, 2],
  5. [2, 3, 1],
  6. ];
  7. $grid2 = [
  8. [1, 6],
  9. [0, 1],
  10. ];
  11. $matrix = new Matrix\Matrix($grid1);
  12. $new = $matrix->directsum(new Matrix\Matrix($grid2));
  13. var_dump($new);