octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #47095] Wrong generalized eigenvalue solutions


From: anonymous
Subject: [Octave-bug-tracker] [bug #47095] Wrong generalized eigenvalue solutions for hermitian matrices
Date: Tue, 09 Feb 2016 00:13:39 +0000
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0

URL:
  <http://savannah.gnu.org/bugs/?47095>

                 Summary: Wrong generalized eigenvalue solutions for hermitian
matrices
                 Project: GNU Octave
            Submitted by: None
            Submitted on: Tue 09 Feb 2016 12:13:37 AM UTC
                Category: Octave Function
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Incorrect Result
                  Status: None
             Assigned to: None
         Originator Name: Mohammad Elahi
        Originator Email: address@hidden
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.0.0
        Operating System: Any

    _______________________________________________________

Details:

The results of generalized eigenvalue problem solved by 'eig' function are
incorrect when the input matrices are hermitian.
A=hermitian matrix
B=hermitian matrix
eig(A,B).

The bug exists in 'libinterp/corefcn/EIG.cc':

octave_idx_type
SEIG::init (const ComplexMatrix& a, const ComplexMatrix& b, bool calc_ev)
{
...
  if (a.is_hermitian () && b.is_hermitian () && info == 0)
    return hermitian_init (a, calc_ev);
...
}

So the hermitian_init is called without 'b' which is incorrect. The trivial
fix is the following:

octave_idx_type
SEIG::init (const ComplexMatrix& a, const ComplexMatrix& b, bool calc_ev)
{
...
  if (a.is_hermitian () && b.is_hermitian () && info == 0)
    return hermitian_init (a, b, calc_ev);
...
}





    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?47095>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]