Overload List
| # | Signature | Description |
|---|---|---|
| 1 | procedure RationalSubstitution(const Num: TVec; const Den: TVec; const nz: TVec; const Dz: TVec); | Replace the variable of a rational polynomial with another rational polyniomial. |
| 2 | procedure RationalSubstitution(const z: TVec; const p: TVec; var k: Double; const nz: TVec; const Dz: TVec); | Zeroes of the original polynomial are stored in z and poles in p vector. |
Overload 1: procedure RationalSubstitution(const Num: TVec; const Den: TVec; const nz: TVec; const Dz: TVec);
Replace the variable of a rational polynomial with another rational polyniomial.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Num | TVec | |
| 2 | Den | TVec | |
| 3 | nz | TVec | |
| 4 | Dz | TVec |
Result: stored in self (calling object)
Num is the nominator and den is the denominator of the original polynomial. Nz is the nominator and Dz is the denominator of the polynom to substitude the variable with in the original polynomial. The function returns modified num and den. Num and den must have the same length. Nz and Dz must have the same length. The advantage of this method is that rooting of the polynomials is not required. The resulting polynomial is normalized to have the coefficient for the highest power in the polynomial equal to 1.
uses MtxExpr, Math387, MtxVec, MtxVecTee, MtxVecEdit,
LinearSystems, IirFilters, SignalUtils;
procedure TForm.Button1Click(Sender: TObject);
var num,den,den1,num1: Vector;
begin
num.SetIt(false,[1,-2, 1]);
den.SetIt(false,[1,-4, 1]);
num1.SetIt(false,[1,-1]);
den1.SetIt(false,[1,-2]);
RationalSubstitution(num,den,num1,den1);
ViewValues(num,'Num',true);
ViewValues(den,'Den',true);
// num = [ 0, 0, -0.5]
// den = [ 1,-3, 1.5]
end;
Overload 2: procedure RationalSubstitution(const z: TVec; const p: TVec; var k: Double; const nz: TVec; const Dz: TVec);
Zeroes of the original polynomial are stored in z and poles in p vector.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | z | TVec | |
| 2 | p | TVec | |
| 3 | k | Double | |
| 4 | nz | TVec | |
| 5 | Dz | TVec |
Result: stored in self (calling object)
Nz is the nominator and Dz is the denominator of the polynom to substitude the variable with in the original polynomial. The function returns modified z and p. Nz and Dz must have the same length. k is the gain factor (not modified).