You are here

private function EigenvalueDecomposition::cdiv in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/JAMA/EigenvalueDecomposition.php \EigenvalueDecomposition::cdiv()

* Performs complex division. * * @access private

1 call to EigenvalueDecomposition::cdiv()
EigenvalueDecomposition::hqr2 in vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/JAMA/EigenvalueDecomposition.php
* Nonsymmetric reduction from Hessenberg to real Schur form. * * Code is derived from the Algol procedure hqr2, * by Martin and Wilkinson, Handbook for Auto. Comp., * Vol.ii-Linear Algebra, and the corresponding * Fortran subroutine in…

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/JAMA/EigenvalueDecomposition.php, line 373

Class

EigenvalueDecomposition
@package JAMA

Code

private function cdiv($xr, $xi, $yr, $yi) {
  if (abs($yr) > abs($yi)) {
    $r = $yi / $yr;
    $d = $yr + $r * $yi;
    $this->cdivr = ($xr + $r * $xi) / $d;
    $this->cdivi = ($xi - $r * $xr) / $d;
  }
  else {
    $r = $yr / $yi;
    $d = $yi + $r * $yr;
    $this->cdivr = ($r * $xr + $xi) / $d;
    $this->cdivi = ($r * $xi - $xr) / $d;
  }
}