| @@ 613-621 (lines=9) @@ | ||
| 610 | $q = $q / $p; |
|
| 611 | $r = $r / $p; |
|
| 612 | // Row modification |
|
| 613 | for ($j = $k; $j < $nn; ++$j) { |
|
| 614 | $p = $this->H[$k][$j] + $q * $this->H[$k+1][$j]; |
|
| 615 | if ($notlast) { |
|
| 616 | $p = $p + $r * $this->H[$k+2][$j]; |
|
| 617 | $this->H[$k+2][$j] = $this->H[$k+2][$j] - $p * $z; |
|
| 618 | } |
|
| 619 | $this->H[$k][$j] = $this->H[$k][$j] - $p * $x; |
|
| 620 | $this->H[$k+1][$j] = $this->H[$k+1][$j] - $p * $y; |
|
| 621 | } |
|
| 622 | // Column modification |
|
| 623 | for ($i = 0; $i <= min($n, $k+3); ++$i) { |
|
| 624 | $p = $x * $this->H[$i][$k] + $y * $this->H[$i][$k+1]; |
|
| @@ 623-631 (lines=9) @@ | ||
| 620 | $this->H[$k+1][$j] = $this->H[$k+1][$j] - $p * $y; |
|
| 621 | } |
|
| 622 | // Column modification |
|
| 623 | for ($i = 0; $i <= min($n, $k+3); ++$i) { |
|
| 624 | $p = $x * $this->H[$i][$k] + $y * $this->H[$i][$k+1]; |
|
| 625 | if ($notlast) { |
|
| 626 | $p = $p + $z * $this->H[$i][$k+2]; |
|
| 627 | $this->H[$i][$k+2] = $this->H[$i][$k+2] - $p * $r; |
|
| 628 | } |
|
| 629 | $this->H[$i][$k] = $this->H[$i][$k] - $p; |
|
| 630 | $this->H[$i][$k+1] = $this->H[$i][$k+1] - $p * $q; |
|
| 631 | } |
|
| 632 | // Accumulate transformations |
|
| 633 | for ($i = $low; $i <= $high; ++$i) { |
|
| 634 | $p = $x * $this->V[$i][$k] + $y * $this->V[$i][$k+1]; |
|
| @@ 633-641 (lines=9) @@ | ||
| 630 | $this->H[$i][$k+1] = $this->H[$i][$k+1] - $p * $q; |
|
| 631 | } |
|
| 632 | // Accumulate transformations |
|
| 633 | for ($i = $low; $i <= $high; ++$i) { |
|
| 634 | $p = $x * $this->V[$i][$k] + $y * $this->V[$i][$k+1]; |
|
| 635 | if ($notlast) { |
|
| 636 | $p = $p + $z * $this->V[$i][$k+2]; |
|
| 637 | $this->V[$i][$k+2] = $this->V[$i][$k+2] - $p * $r; |
|
| 638 | } |
|
| 639 | $this->V[$i][$k] = $this->V[$i][$k] - $p; |
|
| 640 | $this->V[$i][$k+1] = $this->V[$i][$k+1] - $p * $q; |
|
| 641 | } |
|
| 642 | } // ($s != 0) |
|
| 643 | } // k loop |
|
| 644 | } // check convergence |
|