01-25-2006 08:23 AM
01-25-2006 09:49 AM
01-31-2006 05:15 PM
>>bb = [6 -8 0];
>>aa = [1 -1 -6 0];
>>[r,p,k] = residue(bb, aa)
the problem arises when the parameters bb and aa describe polynomials that are multiples of 'z' and have a nontrivial greatest common divisor:
bb represents 6z^2-8*z
aa represents z^3-z^2-6z
As you noted, the problem occurs due to an underlying problem in Partial Fraction Expansion, a VI from the LabVIEW function palette (Mathematics->Polynomial->Rational Polynomial) that is being called "under-the-hood" when you invoke the LabVIEW MathScript 'residue' command.
One way to avoid this problem is to do pole-zero cancellation before applying 'residue'
Alternatively, you can perturb aa or bb slightly by adding some small constant terms, for instance:
>>bb=[6 -8 1e-6]
The problems described here are something that our engineers are aware of and are planning to fix in a future release.
--Sam