8000 small documentation updates · ruturajsambhusvt/python-control@0bfe921 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0bfe921

Browse files
committed
small documentation updates
1 parent 21aa0a6 commit 0bfe921

File tree

2 files changed

+24
-19
lines changed

2 files changed

+24
-19
lines changed

control/statefbk.py

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -676,17 +676,17 @@ def create_statefbk_iosystem(
676676
If a gain scheduled controller is specified, specify the indices of
677677
the controller input to use for scheduling the gain. The input to
678678
the controller is the desired state xd, the desired input ud, and
679-
either the system state x or the system output y (if an estimator is
679+
the system state x (or state estimate xhat, if an estimator is
680680
given). The indices can either be specified as integer offsets into
681681
the input vector or as strings matching the signal names of the
682682
input vector.
683683
684684
gainsched_method : str, optional
685-
The method to use for gain scheduling. Possible values include
686-
`linear` (default), `nearest`, and `cubic`. More information is
687-
available in :func:`scipy.interpolate.griddata`. For points outside
688-
of the convex hull of the scheduling points, the gain at the nearest
689-
point is used.
685+
The method to use for gain scheduling. Possible values are 'linear'
686+
(default), 'nearest', and 'cubic'. More information is available in
687+
:func:`scipy.interpolate.griddata`. For points outside of the convex
688+
hull of the scheduling points, the gain at the nearest point is
689+
used.
690690
691691
type : 'linear' or 'nonlinear', optional
692692
Set the type of controller to create. The default for a linear gain
@@ -700,20 +700,21 @@ def create_statefbk_iosystem(
700700
-------
701701
ctrl : InputOutputSystem
702702
Input/output system representing the controller. This system takes
703-
as inputs the desired state xd, the desired input ud, and either the
704-
system state x or the estimated state xhat. It outputs the
705-
controller action u according to the formula u = ud - K(x - xd). If
706-
the keyword `integral_action` is specified, then an additional set
707-
of integrators is included in the control system (with the gain
708-
matrix K having the integral gains appended after the state gains).
709-
If a gain scheduled controller is specified, the gain (proportional
710-
and integral) are evaluated using the scheduling variables specified
711-
by ``gainsched_indices``.
703+
as inputs the desired state ``xd``, the desired input ``ud``, and
704+
either the system state ``x`` or the estimated state ``xhat``. It
705+
outputs the controller action u according to the formula :math:`u =
706+
u_d - K(x - x_d)`. If the keyword ``integral_action`` is specified,
707+
then an additional set of integrators is included in the control
708+
system (with the gain matrix ``K`` having the integral gains
709+
appended after the state gains). If a gain scheduled controller is
710+
specified, the gain (proportional and integral) are evaluated using
711+
the scheduling variables specified by ``gainsched_indices``.
712712
713713
clsys : InputOutputSystem
714714
Input/output system representing the closed loop system. This
715-
systems takes as inputs the desired trajectory (xd, ud) and outputs
716-
the system state x and the applied input u (vertically stacked).
715+
systems takes as inputs the desired trajectory ``(xd, ud)`` and
716+
outputs the system state ``x`` and the applied input ``u``
717+
(vertically stacked).
717718
718719
Other Parameters
719720
----------------

doc/iosys.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,8 +308,12 @@ and the control action will be given by
308308
u = u_\text{d} - K\text{p} (x - x_\text{d}) -
309309
K_\text{i} \int C (x - x_\text{d}) dt.
310310
311-
(If an estimator is specified, :math:`\hat x` will be used in place of
312-
:math:`x`.)
311+
If `integral_action` is a function `h`, that function will be called
312+
with the signature `h(t, x, u, params)` to obtain the outputs that
313+
should be integrated. The number of outputs that are to be integrated
314+
must match the number of additional columns in the `K` matrix. If an
315+
estimator is specified, :math:`\hat x` will be used in place of
316+
:math:`x`.
313317

314318
Finally, gain scheduling on the desired state, desired input, or
315319
system state can be implemented by setting the gain to a 2-tuple

0 commit comments

Comments
 (0)
0