LIBRARY
LQRGain
Static multivariable (MIMO) gain block implementing y_out = K * u_in.
Maps ny scalar inputs to nu scalar outputs via a constant matrix K. Used as the static state-feedback law inside LQRControlledRotorCraft. The block is sign-agnostic; for negative feedback (u = -L*x) pass -L as K at instantiation.
Usage
MultibodyComponents.LQRGain(K=zeros(nu, ny))
Parameters:
| Name | Description | Units | Default value |
|---|---|---|---|
ny | Number of inputs (measured signals) | – | 13 |
nu | Number of outputs (control channels) | – | 4 |
K | Feedback gain matrix (nu × ny); rows index outputs, columns index inputs | – | zeros(nu, ny) |
Connectors
u_in- This connector represents a real signal as an input to a component (RealInput)y_out- This connector represents a real signal as an output from a component (RealOutput)
Behavior
Dict{MIME{Symbol("text/plain")}, String} with 1 entry: MIME type text/plain => "Error displaying result"
Source
dyad
"""
Static multivariable (MIMO) gain block implementing `y_out = K * u_in`.
Maps `ny` scalar inputs to `nu` scalar outputs via a constant matrix `K`. Used
as the static state-feedback law inside `LQRControlledRotorCraft`. The block is
sign-agnostic; for negative feedback (`u = -L*x`) pass `-L` as `K` at
instantiation.
"""
component LQRGain
"Input signal vector (size ny, one connector per measured signal)"
u_in = [RealInput() for i in 1:ny] {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": -100, "y1": 450, "x2": 0, "y2": 550, "rot": 0}
},
"tags": []
}
}
"Output signal vector (size nu, one connector per control channel)"
y_out = [RealOutput() for i in 1:nu] {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": 1000, "y1": 450, "x2": 1100, "y2": 550, "rot": 0}
},
"tags": []
}
}
"Number of inputs (measured signals)"
structural parameter ny::Integer = 13
"Number of outputs (control channels)"
structural parameter nu::Integer = 4
"Feedback gain matrix (nu × ny); rows index outputs, columns index inputs"
parameter K::Real[nu, ny] = zeros(nu, ny)
relations
y_out = K * u_in
endFlattened Source
dyad
"""
Static multivariable (MIMO) gain block implementing `y_out = K * u_in`.
Maps `ny` scalar inputs to `nu` scalar outputs via a constant matrix `K`. Used
as the static state-feedback law inside `LQRControlledRotorCraft`. The block is
sign-agnostic; for negative feedback (`u = -L*x`) pass `-L` as `K` at
instantiation.
"""
component LQRGain
"Input signal vector (size ny, one connector per measured signal)"
u_in = [RealInput() for i in 1:ny] {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": -100, "y1": 450, "x2": 0, "y2": 550, "rot": 0}
},
"tags": []
}
}
"Output signal vector (size nu, one connector per control channel)"
y_out = [RealOutput() for i in 1:nu] {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": 1000, "y1": 450, "x2": 1100, "y2": 550, "rot": 0}
},
"tags": []
}
}
"Number of inputs (measured signals)"
structural parameter ny::Integer = 13
"Number of outputs (control channels)"
structural parameter nu::Integer = 4
"Feedback gain matrix (nu × ny); rows index outputs, columns index inputs"
parameter K::Real[nu, ny] = zeros(nu, ny)
relations
y_out = K * u_in
metadata {}
endTest Cases
No test cases defined.
Related
Examples
Experiments
Analyses