From help-request at octave dot org Thu Jul 15 15:04:54 2004 Subject: Re: qz From: Quentin Spencer To: Stefan van der Walt CC: help at octave dot org Date: Thu, 15 Jul 2004 15:02:50 -0500 Stefan van der Walt wrote: >I am trying to solve the generalised eigenvalue problem using qz, but >the following behaviour looks suspicious: > >octave:5> a = rand(3,3); b = rand(3,3); [AA, BB, Q, Z, V, W] = >qz(a,b); Q*a*Z - AA, Q*b*Z - BB >ans = > > -0.506316 0.133307 1.509299 > -0.425943 -0.168888 -1.856508 > 0.203352 -0.028521 -0.327870 > >ans = > > -0.377653 -0.108805 1.424638 > 0.274852 -0.178300 -0.189498 > 0.098925 0.051424 -0.448613 > >If I understand correctly, the answers should be much closer to >zero(3,3)? > > You are close. Replace Q with Q', and I get matrices with values on the order of 1E-16. -Quentin ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------