harold.State¶
-
class
harold.State(a, b=None, c=None, d=None, dt=None)¶ A class for creating State space models.
-
__init__(a, b=None, c=None, d=None, dt=None)¶ A State object can be instantiated in a straightforward manner by entering arraylikes.:
>>> G = State([[0, 1], [-4, -5]], [[0], [1]], [1, 0], 1)
For zero feedthrough (strictly proper) models, “d” matrix can be skipped and will be replaced with the zeros array whose shape is inferred from the rows/columns of “c”/”b” arrays.
Setting
SamplingPeriodproperty to'None'will make the system continuous time again and relevant properties are reset to continuous-time properties. However the numerical data will still be the same.
Methods
__init__(a[, b, c, d, dt])A State object can be instantiated in a straightforward manner by entering arraylikes.. pole_properties([output_data])The resulting array holds the poles in the first column, natural frequencies in the second and damping ratios in the third. to_array()If a State representation is a static gain, this method returns a regular 2D-ndarray. validate_arguments(a, b, c, d[, verbose])An internal command to validate whether given arguments to a State() instance are valid and compatible. Attributes
DiscretizationMatrixThis matrix denoted with \(Q\) is internally used to represent the upper linear fractional transformation of the operation \(\frac{1}{s} I = \frac{1}{z} I \star Q\). DiscretizedWithThis property is used internally to keep track of (if applicable) the original method used for discretization. NumberOfInputsA read only property that holds the number of inputs. NumberOfOutputsA read only property that holds the number of outputs. NumberOfStatesA read only property that holds the number of states. PrewarpFrequencyIf the discretization method is tustinthen a frequency warping correction might be required the match of the discrete time system response at the frequency band of interest.SamplingPeriodIf this property is called G.SamplingPeriodthen returns the sampling period data.SamplingSetIf this property is called G.SamplingSetthen returns the setZorRfor discrete and continuous models respectively.aIf this property is called G.athen returns the matrix data.bIf this property is called G.bthen returns the matrix data.cIf this property is called G.cthen returns the matrix data.dIf this property is called G.athen returns the matrix data.matricesA read only property that returns the model matrices. shapeA read only property that holds the shape of the system as a tuple such that the result is (# of inputs , # of outputs).-