Interface ITransferFunction

Transfer function interface.

Example

const tf = new TransferFunction({
numerator: [{ re: 1, im: 1 }, { re: -2, im: 0 }],
denominator: [{ re: 1, im: 0 }, { re: -2, im: 0 }, { re: -3, im: 0 }],
});
});

Hierarchy

  • ITransferFunction

Methods

  • Calculates the frequency response of a dynamic system. Generates two objects, one for the magnitude in db and the other for the phase in degrees of the system response as a function of frequency

    Alias

    bode

    Parameters

    • Optional frequencyRange: number[]

    Returns BodeData

  • Calculates the unit impulse response of a dynamic system model. The impulse response is the response to a Dirac input δ(t). It returns a ready to input chart data, with x and y axis

    Alias

    impulse

    Parameters

    • Optional timeRange: number[]

    Returns Point<number>[]

  • Calculates the poles of a dynamic system model. Meaning, the values that will make the system go to infinite. The poles of a dynamic system determine the stability and response of the system.

    An open-loop linear time-invariant system is stable if: In continuous-time, all the poles of the transfer function have negative real parts. When the poles are visualized on the complex s-plane, then they must all lie in the left-half plane (LHP) to ensure stability. In discrete-time, all the poles must have a magnitude strictly smaller than one, that is they must all lie inside the unit circle.

    Alias

    pole

    Returns Complex[]

  • Calculates and plots the root locus of the SISO model sys. The root locus returns the closed-loop pole trajectories as a function of the feedback gain k (assuming negative feedback). Root loci are used to study the effects of varying feedback gains on closed-loop pole locations. In turn, these locations provide indirect information on the time and frequency responses.

    Alias

    rlocus

    Parameters

    • Optional k: number[]

      Feedback gain

    Returns RootLocusData

  • Return the transfer function expression in a string format

    Example

    const tf = new TransferFunction({
    numerator: [{ re: 1, im: 1 }, { re: -2, im: 0 }],
    denominator: [{ re: 1, im: 0 }, { re: -2, im: 0 }, { re: -3, im: 0 }],
    });
    console.log(tf.toString())
    // Output: -(1 + i)s - 2 / s^2 - 2s - 3

    Returns string

Generated using TypeDoc