@@ 219-223 (lines=5) @@ | ||
216 | */ |
|
217 | public function isNonsingular(): bool |
|
218 | { |
|
219 | for ($j = 0; $j < $this->n; ++$j) { |
|
220 | if ($this->LU[$j][$j] == 0) { |
|
221 | return false; |
|
222 | } |
|
223 | } |
|
224 | ||
225 | return true; |
|
226 | } |
|
@@ 242-244 (lines=3) @@ | ||
239 | } |
|
240 | ||
241 | $d = $this->pivsign; |
|
242 | for ($j = 0; $j < $this->n; ++$j) { |
|
243 | $d *= $this->LU[$j][$j]; |
|
244 | } |
|
245 | ||
246 | return $d; |
|
247 | } |