Version:

Last Modified: March 15, 2017

Computes the partial fraction expansion of two polynomials, or transforms a given partial fraction expansion into the original polynomial representation.

[b, a] = residue(r, p, k)

[r2, p2, k2] = residue(b2, a2)

Residues of the partial fraction expansion. r is a real or complex vector.

Poles of the partial fraction expansion. p is a real or complex vector.

Coefficients in descending order of power of the quotient polynomial of a and b. k is a real or complex vector.

Coefficients in descending order of power of the numerator polynomial. b2 is an array of any dimension. If necessary, MathScript flattens b2 before the calculation.

Coefficients in descending order of power of the denominator polynomial. a2 is an array of any dimension. If necessary, MathScript flattens a2 before the calculation.

Coefficients in descending order of power of the numerator polynomial.

Coefficients in descending order of power of the denominator polynomial.

Residues of the partial fraction expansion. r2 is a real or complex vector.

Poles of the partial fraction expansion. p2 is a real or complex vector.

Coefficients in descending order of power of the quotient polynomial of a2 and b2.

MathScript computes a and b using the following equation if no multiple roots exist:

b _{ s }/a _{ s } = (r _{1}/(*s*-p _{1})) + (r _{2}/(*s*-p _{2})) + ... + (r _{ n }/(*s*-p _{ n })) + k _{ s }, where *s* is the power and *n* is the number of elements in the partial fraction expansion.

If multiple poles exist, that is, if p _{ j } = ... = p _{ j } _{+} _{ m } _{-} _{1}, where *j* is the element index and *m* is the multiple, then the partial fraction expansion includes the following terms: (r _{ j }/(*s*-p _{ j })) + (r _{ j } _{+1}/(*s*-p _{ j }))^{2} + ... + (r _{ j } _{+} _{ m } _{-1}/(*s*-p _{ j }))^{ m }.

B = [1, 2, 3, 4]; A = [1, 1]; [R, P, K] = residue(B, A)

**Where This Node Can Run: **

Desktop OS: Windows

FPGA: This product does not support FPGA devices