4242from . import config
4343
4444__all__ = ['InputOutputSystem' , 'LinearIOSystem' , 'NonlinearIOSystem' ,
45- 'InterconnectedSystem' , 'input_output_response ' , 'find_eqpt ' ,
46- 'linearize' , 'ss2io' , 'tf2io' , 'interconnect' ]
45+ 'InterconnectedSystem' , 'LinearICSystem ' , 'input_output_response ' ,
46+ 'find_eqpt' , ' linearize' , 'ss2io' , 'tf2io' , 'interconnect' ]
4747
4848# Define module default parameter values
4949_iosys_defaults = {
@@ -110,8 +110,8 @@ class for a set of subclasses that are used to implement specific
110110
111111 Notes
112112 -----
113- The ` InputOuputSystem` class (and its subclasses) makes use of two special
114- methods for implementing much of the work of the class:
113+ The :class:`~control. InputOuputSystem` class (and its subclasses) makes
114+ use of two special methods for implementing much of the work of the class:
115115
116116 * _rhs(t, x, u): compute the right hand side of the differential or
117117 difference equation for the system. This must be specified by the
@@ -137,8 +137,8 @@ def __init__(self, inputs=None, outputs=None, states=None, params={},
137137 The InputOutputSystem contructor is used to create an input/output
138138 object with the core information required for all input/output
139139 systems. Instances of this class are normally created by one of the
140- input/output subclasses: :class:`~control.LinearIOSystem `,
141- :class:`~control.NonlinearIOSystem`,
140+ input/output subclasses: :class:`~control.LinearICSystem `,
141+ :class:`~control.LinearIOSystem`, :class:`~control. NonlinearIOSystem`,
142142 :class:`~control.InterconnectedSystem`.
143143
144144 Parameters
@@ -242,10 +242,10 @@ def __mul__(sys2, sys1):
242242 np .zeros ((sys2 .ninputs , sys2 .noutputs ))]]
243243 ))
244244
245- # If both systems are linear, create LinearInterconnectedSystem
245+ # If both systems are linear, create LinearICSystem
246246 if isinstance (sys1 , StateSpace ) and isinstance (sys2 , StateSpace ):
247247 ss_sys = StateSpace .__mul__ (sys2 , sys1 )
248- return LinearInterconnectedSystem (newsys , ss_sys )
248+ return LinearICSystem (newsys , ss_sys )
249249
250250 # Return the newly created InterconnectedSystem
251251 return newsys
@@ -294,10 +294,10 @@ def __add__(sys1, sys2):
294294 newsys = InterconnectedSystem (
295295 (sys1 , sys2 ), inplist = inplist , outlist = outlist )
296296
297- # If both systems are linear, create LinearInterconnectedSystem
297+ # If both systems are linear, create LinearICSystem
298298 if isinstance (sys1 , StateSpace ) and isinstance (sys2 , StateSpace ):
299299 ss_sys = StateSpace .__add__ (sys2 , sys1 )
300- return LinearInterconnectedSystem (newsys , ss_sys )
300+ return LinearICSystem (newsys , ss_sys )
301301
302302 # Return the newly created InterconnectedSystem
303303 return newsys
@@ -315,10 +315,10 @@ def __neg__(sys):
315315 newsys = InterconnectedSystem (
316316 (sys ,), dt = sys .dt , inplist = inplist , outlist = outlist )
317317
318- # If the system is linear, create LinearInterconnectedSystem
318+ # If the system is linear, create LinearICSystem
319319 if isinstance (sys , StateSpace ):
320320 ss_sys = StateSpace .__neg__ (sys )
321- return LinearInterconnectedSystem (newsys , ss_sys )
321+ return LinearICSystem (newsys , ss_sys )
322322
323323 # Return the newly created system
324324 return newsys
@@ -502,7 +502,7 @@ def feedback(self, other=1, sign=-1, params={}):
502502 if isinstance (self , StateSpace ) and isinstance (other , StateSpace ):
503503 # Special case: maintain linear systems structure
504504 ss_sys = StateSpace .feedback (self , other , sign = sign )
505- return LinearInterconnectedSystem (newsys , ss_sys )
505+ return LinearICSystem (newsys , ss_sys )
506506
507507 # Return the newly created system
508508 return newsys
@@ -697,10 +697,10 @@ def __init__(self, updfcn, outfcn=None, inputs=None, outputs=None,
697697 name = None , ** kwargs ):
698698 """Create a nonlinear I/O system given update and output functions.
699699
700- Creates an ` InputOutputSystem` for a nonlinear system by specifying a
701- state update function and an output function. The new system can be a
702- continuous or discrete time system (Note: discrete-time systems not
703- yet supported by most function.)
700+ Creates an :class:`~control. InputOutputSystem` for a nonlinear system
701+ by specifying a state update function and an output function. The new
702+ system can be a continuous or discrete time system (Note:
703+ discrete-time systems not yet supported by most function.)
704704
705705 Parameters
706706 ----------
@@ -1284,15 +1284,16 @@ def set_output_map(self, output_map):
12841284 self .noutputs = output_map .shape [0 ]
12851285
12861286
1287- class LinearInterconnectedSystem (InterconnectedSystem , LinearIOSystem ):
1287+ class LinearICSystem (InterconnectedSystem , LinearIOSystem ):
12881288 """Interconnection of a set of linear input/output systems.
12891289
12901290 This class is used to implement a system that is an interconnection of
12911291 linear input/output systems. It has all of the structure of an
1292- :class:`InterconnectedSystem`, but also maintains the requirement elements
1293- of :class:`LinearIOSystem`, including the :class:`StateSpace` class
1294- structure, allowing it to be passed to functions that expect a
1295- :class:`StateSpace` system.
1292+ :class:`~control.InterconnectedSystem`, but also maintains the requirement
1293+ elements of :class:`~control.LinearIOSystem`, including the
1294+ :class:`StateSpace` class structure, allowing it to be passed to functions
1295+ that expect a :class:`StateSpace` system.
1296+
12961297 """
12971298
12981299 def __init__ (self , io_sys , ss_sys = None ):
@@ -1755,7 +1756,7 @@ def linearize(sys, xeq, ueq=[], t=0, params={}, **kw):
17551756 """Linearize an input/output system at a given state and input.
17561757
17571758 This function computes the linearization of an input/output system at a
1758- given state and input value and returns a :class:`control.StateSpace`
1759+ given state and input value and returns a :class:`~ control.StateSpace`
17591760 object. The eavaluation point need not be an equilibrium point.
17601761
17611762 Parameters
@@ -1840,10 +1841,11 @@ def interconnect(syslist, connections=[], inplist=[], outlist=[],
18401841
18411842 This function creates a new system that is an interconnection of a set of
18421843 input/output systems. If all of the input systems are linear I/O systems
1843- (type `LinearIOSystem`) then the resulting system will be a linear
1844- interconnected I/O system (type `LinearInterconnectedSystem`) with the
1845- appropriate inputs, outputs, and states. Otherwise, an interconnected I/O
1846- system (type `InterconnectedSystem`) will be created.
1844+ (type :class:`~control.LinearIOSystem`) then the resulting system will be
1845+ a linear interconnected I/O system (type :class:`~control.LinearICSystem`)
1846+ with the appropriate inputs, outputs, and states. Otherwise, an
1847+ interconnected I/O system (type :class:`~control.InterconnectedSystem`)
1848+ will be created.
18471849
18481850 Parameters
18491851 ----------
@@ -1895,8 +1897,8 @@ def interconnect(syslist, connections=[], inplist=[], outlist=[],
18951897 the system input connects to only one subsystem input, a single input
18961898 specification can be given (without the inner list).
18971899
1898- If omitted, the input map can be specified using the `set_input_map`
1899- method.
1900+ If omitted, the input map can be specified using the
1901+ :func:`~control.InterconnectedSystem.set_input_map` method.
19001902
19011903 outlist : list of output connections, optional
19021904 List of connections for how the outputs from the subsystems are mapped
@@ -1910,8 +1912,8 @@ def interconnect(syslist, connections=[], inplist=[], outlist=[],
19101912 then those signals are added together (multiplying by the any gain
19111913 term) to form the system output.
19121914
1913- If omitted, the output map can be specified using the `set_output_map`
1914- method.
1915+ If omitted, the output map can be specified using the
1916+ :func:`~control.InterconnectedSystem.set_output_map` method.
19151917
19161918 inputs : int, list of str or None, optional
19171919 Description of the system inputs. This can be given as an integer
@@ -1951,17 +1953,17 @@ def interconnect(syslist, connections=[], inplist=[], outlist=[],
19511953
19521954 Example
19531955 -------
1954- P = control.LinearIOSystem(
1955- ct.rss(2, 2, 2, strictly_proper=True), name='P')
1956- C = control.LinearIOSystem(control.rss(2, 2, 2), name='C')
1957- S = control.InterconnectedSystem(
1958- [P, C],
1959- connections = [
1960- ['P.u[0]', 'C.y[0]'], ['P.u[1]', 'C.y[0]'],
1961- ['C.u[0]', '-P.y[0]'], ['C.u[1]', '-P.y[1]']],
1962- inplist = ['C.u[0]', 'C.u[1]'],
1963- outlist = ['P.y[0]', 'P.y[1]'],
1964- )
1956+ >>> P = control.LinearIOSystem(
1957+ >>> ct.rss(2, 2, 2, strictly_proper=True), name='P')
1958+ >>> C = control.LinearIOSystem(control.rss(2, 2, 2), name='C')
1959+ >>> S = control.InterconnectedSystem(
1960+ >>> [P, C],
1961+ >>> connections = [
1962+ >>> ['P.u[0]', 'C.y[0]'], ['P.u[1]', 'C.y[0]'],
1963+ >>> ['C.u[0]', '-P.y[0]'], ['C.u[1]', '-P.y[1]']],
1964+ >>> inplist = ['C.u[0]', 'C.u[1]'],
1965+ >>> outlist = ['P.y[0]', 'P.y[1]'],
1966+ >>> )
19651967
19661968 Notes
19671969 -----
@@ -1973,10 +1975,11 @@ def interconnect(syslist, connections=[], inplist=[], outlist=[],
19731975 check your use of tuples.
19741976
19751977 In addition to its use for general nonlinear I/O systems, the
1976- `interconnect` function allows linear systems to be interconnected using
1977- named signals (compared with the `connect` function, which uses signal
1978- indicies) and to be treated as both a `StateSpace` system as well as an
1979- `InputOutputSystem`.
1978+ :func:`~control.interconnect` function allows linear systems to be
1979+ interconnected using named signals (compared with the
1980+ :func:`~control.connect` function, which uses signal indicies) and to be
1981+ treated as both a :class:`~control.StateSpace` system as well as an
1982+ :class:`~control.InputOutputSystem`.
19801983
19811984 """
19821985 newsys = InterconnectedSystem (
@@ -1986,6 +1989,6 @@ def interconnect(syslist, connections=[], inplist=[], outlist=[],
19861989
19871990 # If all subsystems are linear systems, maintain linear structure
19881991 if all ([isinstance (sys , LinearIOSystem ) for sys in syslist ]):
1989- return LinearInterconnectedSystem (newsys , None )
1992+ return LinearICSystem (newsys , None )
19901993
19911994 return newsys
0 commit comments