You are here

public function PHPExcel_Shared_JAMA_LUDecomposition::getU in Loft Data Grids 7.2

Same name and namespace in other branches
  1. 6.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/JAMA/LUDecomposition.php \PHPExcel_Shared_JAMA_LUDecomposition::getU()

* Get upper triangular factor. * *

Return value

array Upper triangular factor

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/JAMA/LUDecomposition.php, line 149

Class

PHPExcel_Shared_JAMA_LUDecomposition
@package JAMA

Code

public function getU() {
  for ($i = 0; $i < $this->n; ++$i) {
    for ($j = 0; $j < $this->n; ++$j) {
      if ($i <= $j) {
        $U[$i][$j] = $this->LU[$i][$j];
      }
      else {
        $U[$i][$j] = 0.0;
      }
    }
  }
  return new PHPExcel_Shared_JAMA_Matrix($U);
}