ss2tf(A, B, C, D, input=0)
A, B, C, D defines a linear state-space system with p
inputs, :None:None:`q`
outputs, and n
state variables.
State (or system) matrix of shape (n, n)
Input matrix of shape (n, p)
Output matrix of shape (q, n)
Feedthrough (or feedforward) matrix of shape (q, p)
For multiple-input systems, the index of the input to use.
Numerator(s) of the resulting transfer function(s). :None:None:`num`
has one row for each of the system's outputs. Each row is a sequence representation of the numerator polynomial.
Denominator of the resulting transfer function(s). :None:None:`den`
is a sequence representation of the denominator polynomial.
State-space to transfer function.
Convert the state-space representation:
$$$$\dot{\textbf{x}}(t) = \begin{bmatrix} -2 & -1 \\ 1 & 0 \end{bmatrix} \textbf{x}(t) + \begin{bmatrix} 1 \\ 0 \end{bmatrix} \textbf{u}(t) \\
\textbf{y}(t) = \begin{bmatrix} 1 & 2 \end{bmatrix} \textbf{x}(t) + \begin{bmatrix} 1 \end{bmatrix} \textbf{u}(t)
>>> A = [[-2, -1], [1, 0]]
... B = [[1], [0]] # 2-D column vector
... C = [[1, 2]] # 2-D row vector
... D = 1
to the transfer function:
$$H(s) = \frac{s^2 + 3s + 3}{s^2 + 2s + 1}$$>>> from scipy.signal import ss2tfSee :
... ss2tf(A, B, C, D) (array([[1., 3., 3.]]), array([ 1., 2., 1.]))
The following pages refer to to this document either explicitly or contain code examples using this.
scipy.signal._ltisys.StateSpace
scipy.signal._lti_conversion.abcd_normalize
scipy.signal._ltisys.StateSpaceContinuous
scipy.signal._lti_conversion.ss2tf
scipy.signal._ltisys.StateSpaceDiscrete
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them