8000 bring back 'Other parameters' in docstrings, alphabetize TOC · python-control/python-control@2311a4d · GitHub
[go: up one dir, main page]

Skip to content

Commit 2311a4d

Browse files
committed
bring back 'Other parameters' in docstrings, alphabetize TOC
1 parent bf50ded commit 2311a4d

File tree

5 files changed

+41
-30
lines changed

5 files changed

+41
-30
lines changed

control/dtime.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,14 @@ def sample_system(sysc, Ts, method='zoh', alpha=None, prewarp_frequency=None,
8484
copy_names : bool, Optional
8585
If True, copy the names of the input signals, output
8686
signals, and states to the sampled system.
87+
88+
Returns
89+
-------
90+
sysd : linsys
91+
Discrete time system, with sampling rate Ts
92+
93+
Other Parameters
94+
----------------
8795
inputs : int, list of str or None, optional
8896
Description of the system inputs. If not specified, the origional
8997
system inputs are used. See :class:`InputOutputSystem` for more
@@ -94,11 +102,6 @@ def sample_system(sysc, Ts, method='zoh', alpha=None, prewarp_frequency=None,
94102
Description of the system states. Same format as `inputs`. Only
95103
available if the system is :class:`StateSpace`.
96104
97-
Returns
98-
-------
99-
sysd : linsys
100-
Discrete time system, with sampling rate Ts
101-
102105
Notes
103106
-----
104107
See :meth:`StateSpace.sample` or :meth:`TransferFunction.sample` for

control/iosys.py

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2203,6 +2203,15 @@ def linearize(sys, xeq, ueq=None, t=0, params=None, **kw):
22032203
copy_names : bool, Optional
22042204
If True, Copy the names of the input signals, output signals, and
22052205
states to the linearized system.
2206+
2207+
Returns
2208+
-------
2209+
ss_sys : LinearIOSystem
2210+
The linearization of the system, as a :class:`~control.LinearIOSystem`
2211+
object (which is also a :class:`~control.StateSpace` object.
2212+
2213+
Other Parameters
2214+
----------------
22062215
inputs : int, list of str or None, optional
22072216
Description of the system inputs. If not specified, the origional
22082217
system inputs are used. See :class:`InputOutputSystem` for more
@@ -2211,13 +2220,6 @@ def linearize(sys, xeq, ueq=None, t=0, params=None, **kw):
22112220
Description of the system outputs. Same format as `inputs`.
22122221
states : int, list of str, or None, optional
22132222
Description of the system states. Same format as `inputs`.
2214-
2215-
Returns
2216-
-------
2217-
ss_sys : LinearIOSystem
2218-
The linearization of the system, as a :class:`~control.LinearIOSystem`
2219-
object (which is also a :class:`~control.StateSpace` object.
2220-
22212223
"""
22222224
if not isinstance(sys, InputOutputSystem):
22232225
raise TypeError("Can only linearize InputOutputSystem types")

control/statesp.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1338,6 +1338,14 @@ def sample(self, Ts, method='zoh', alpha=None, prewarp_frequency=None,
13381338
copy_names : bool, Optional
13391339
If True, copy the names of the input signals, output
13401340
signals, and states to the sampled system.
1341+
1342+
Returns
1343+
-------
1344+
sysd : StateSpace
1345+
Discrete-time system, with sampling rate Ts
1346+
1347+
Other Parameters
1348+
----------------
13411349
inputs : int, list of str or None, optional
13421350
Description of the system inputs. If not specified, the origional
13431351
system inputs are used. See :class:`InputOutputSystem` for more
@@ -1347,11 +1355,6 @@ def sample(self, Ts, method='zoh', alpha=None, prewarp_frequency=None,
13471355
states : int, list of str, or None, optional
13481356
Description of the system states. Same format as `inputs`.
13491357
1350-
Returns
1351-
-------
1352-
sysd : StateSpace
1353-
Discrete-time system, with sampling rate Ts
1354-
13551358
Notes
13561359
-----
13571360
Uses :func:`scipy.signal.cont2discrete`

control/xferfcn.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1130,18 +1130,21 @@ def sample(self, Ts, method='zoh', alpha=None, prewarp_frequency=None,
11301130
copy_names : bool, Optional
11311131
If True, copy the names of the input signals, output
11321132
signals, and states to the sampled system.
1133+
1134+
Returns
1135+
-------
1136+
sysd : TransferFunction system
1137+
Discrete-time system, with sample period Ts
1138+
1139+
Other Parameters
1140+
----------------
11331141
inputs : int, list of str or None, optional
11341142
Description of the system inputs. If not specified, the origional
11351143
system inputs are used. See :class:`InputOutputSystem` for more
11361144
information.
11371145
outputs : int, list of str or None, optional
11381146
Description of the system outputs. Same format as `inputs`.
11391147
1140-
Returns
1141-
-------
1142-
sysd : TransferFunction system
1143-
Discrete-time system, with sample period Ts
1144-
11451148
Notes
11461149
-----
11471150
1. Available only for SISO systems
@@ -1582,7 +1585,7 @@ def tf(*args, **kwargs):
15821585
else:
15831586
raise ValueError("Needs 1 or 2 arguments; received %i." % len(args))
15841587

1585-
1588+
# TODO: copy signal names
15861589
def ss2tf(*args, **kwargs):
15871590
"""ss2tf(sys)
15881591

doc/control.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ System interconnections
3131
append
3232
connect
3333
feedback
34+
interconnect
3435
negate
3536
parallel
3637
series
37-
interconnect
3838

3939

4040
Frequency domain plotting
@@ -80,8 +80,6 @@ Control system analysis
8080
dcgain
8181
describing_function
8282
frequency_response
83-
TransferFunction.__call__
84-
StateSpace.__call__
8583
get_input_ff_index
8684
get_output_fb_index
8785
ispassive
@@ -93,6 +91,8 @@ Control system analysis
9391
pzmap
9492
root_locus
9593
sisotool
94+
StateSpace.__call__
95+
TransferFunction.__call__
9696

9797

9898

@@ -102,10 +102,10 @@ Matrix computations
102102
:toctree: generated/
103103

104104
care
105+
ctrb
105106
dare
106-
lyap
107107
dlyap
108-
ctrb
108+
lyap
109109
obsv
110110
gram
111111

@@ -116,10 +116,10 @@ Control system synthesis
116116

117117
acker
118118
create_statefbk_iosystem
119+
dlqr
119120
h2syn
120121
hinfsyn
121122
lqr
122-
dlqr
123123
mixsyn
124124
place
125125
rootlocus_pid_designer
@@ -157,8 +157,8 @@ Stochastic system support
157157

158158
correlation
159159
create_estimator_iosystem
160-
lqe
161160
dlqe
161+
lqe
162162
white_noise
163163

164164
.. _utility-and-conversions:

0 commit comments

Comments
 (0)
0