SystemLevelControl.AbstractFeedbackStructure
— TypeAbstractFeedbackStructure
An abstract type for specifying feedback structures. Its main usage is to specialize type annotations of AbstractGeneralizedPlant
's.
SystemLevelControl.AbstractGeneralizedPlant
— TypeAbstractGeneralizedPlant{T<:Number,Ts<:AbstractFeedbackStructure}
An abstract type for subtyping generalized plant models.
SystemLevelControl.DualGeneralizedPlant
— TypeDualGeneralizedPlant{T,Ts} <: AbstractGeneralizedPlant{T<:Number,Ts<:AbstractFeedbackStructure}
A type representing an adjoint (or dual) state-space
\[P^* = \left[\begin{array}{c | c c} A^* & C_1^* & C_2^* \\ \hline B_1^* & D_{11}^* & D_{21}^* \\ B_2^* & D_{12}^* & D_{22}^* \end{array}\right]\]
Avoid directly constructing objects of this type. Instead, create a P::GeneralizedPlant
and use adjoint(P)
function or P'
.
SystemLevelControl.GeneralizedPlant
— TypeGeneralizedPlant{T,Ts} <: AbstractGeneralizedPlant{T<:Number,Ts<:AbstractFeedbackStructure}
A type representing a generalized state-space model
\[P = \left[\begin{array}{c | c c} A & B_1 & B_2 \\ \hline C_1 & D_{11} & D_{12} \\ C_2 & D_{21} & D_{22} \end{array}\right]\]
See the function Plant
for a user-friendly constructor of generalized plants. For detailed instructions check the documentation on Plants and controllers.
Fields
A::SparseMatrixCSC{T,Int}
B₁::SparseMatrixCSC{T,Int}
B₂::SparseMatrixCSC{T,Int}
C₁::SparseMatrixCSC{T,Int}
D₁₁::SparseMatrixCSC{T,Int}
D₁₂::SparseMatrixCSC{T,Int}
C₂::SparseMatrixCSC{T,Int}
D₂₁::SparseMatrixCSC{T,Int}
D₂₂::SparseMatrixCSC{T,Int}
SystemLevelControl.GeneralizedSubPlant
— TypeGeneralizedSubPlant{T,Ts} <: AbstractGeneralizedPlant{T<:Number,Ts<:AbstractFeedbackStructure}
A type representing a partition of a state-space
\[\tilde{P} = \left[\begin{array}{c | c c} [A]_{I_1,J_1} & [B_1]_{I_1,J_2} & [B_2]_{I_1,J_3} \\ \hline [C_1]_{I_2,J_1} & [D_{11}]_{I_2,J_2} & [D_{12}]_{I_2,J_3} \\ [C_2]_{I_3,J_1} & [D_{21}]_{I_3,J_2} & [D_{22}]_{I_3,J_3} \end{array}\right]\]
where $I = (I_1,I_2,I_3)$ and $J=(J_1,J_2,J_3)$ are the desired partition index sets.
Avoid directly constructing objects of this type. Instead, create a P::GeneralizedPlant
and use view(P, I, J)
with tuples I = (I₁,I₂,I₃)
and J = (J₁,J₂,J₃)
describing the desired paritioning. To materialize the subsystem into a new GeneralizedPlant
, use copy
.
SystemLevelControl.OutputFeedback
— TypeOutputFeedback
A wrapper type to specify output-feedback structures.
SystemLevelControl.StateFeedback
— TypeStateFeedback
A wrapper type to specify state-feedback structures.
SystemLevelControl.Plant
— MethodP = Plant(A, B₁, B₂[, C₁, D₁₁, D₁₁, C₂, D₂₁, D₂₂])
Creates a generalized plant model P::GeneralizedPlant{T,Ts}
with matrices of type T<:Number
and feedback structure Ts<:AbstractFeedback
.
If the matrices C₂
, D₂₁
, and D₂₂
are unspecified, the function automatically sets C₂ = I
and returns a state-feedback plant (Ts<:StateFeedback
). If the matrices C₂
, D₁₁
, and D₁₂
are unspecified, the function assumes the standard LQR-type reference signal $z^Tz = x^Tx + u^Tu$ with C₁ = [I; 0]
and D₁₂ = [0; I]
.
In case D₁₁ = 0
and/or D₂₂ = 0
, a matrix of appropriate dimensions is created. Similarly, if C₂ = I
then the output matrix of appropriate dimension is created.
Examples
julia> A = randn(100,100); B₁ = randn(100,100); B₂ = randn(100,50);
julia> C₁ = randn(150,100); D₁₂ = randn(150,50);
julia> D₂₁ = randn(100,100);
julia> P = Plant(A, B₁, B₂, C₁, 0, D₁₂, I, D₂₁, 0)
350×250 GeneralizedPlant{Float64, OutputFeedback} w/ 100 states, 100 outputs, 50 controls.
julia> P = Plant(A, B₁, B₂)
350×250 GeneralizedPlant{Float64, StateFeedback} w/ 100 states, 100 outputs, 50 controls.
P = Plant(Σ, DIMS)
Creates a generalized plant model P::GeneralizedPlant{T,Ts}
based on a single matrix representation Σ::AbstractMatrix
to be partitioned according to dimensions DIMS = [Nx, Nz, Ny, Nw, Nu]
.
If length(DIMS) = 4
, then a state-feedback plant is constructed by slicing Σ
with DIMS = [Nx, Nz, Nw, Nu]
.
Examples
julia> A = randn(100,100); B₁ = randn(100,100); B₂ = randn(100,50);
julia> C₁ = randn(150,100); D₁₂ = randn(150,50);
julia> D₂₁ = randn(100,100);
julia> P = Plant([A B₁ B₂; C₁ zeros(150,100) D₁₂; I D₂₁ zeros(100,50)], [100, 150, 100, 100, 50])
350×250 GeneralizedPlant{Float64, OutputFeedback} w/ 100 states, 100 outputs, 50 controls.
julia> P = Plant([A B₁ B₂; C₁ zeros(150,100) D₁₂], [100, 150, 100, 50])
350×250 GeneralizedPlant{Float64, StateFeedback} w/ 100 states, 100 outputs, 50 controls.