7272_statesp_defaults = {
7373 'statesp.use_numpy_matrix' : True ,
7474 'statesp.default_dt' : None ,
75- 'statesp.remove_useless_states' : True ,
75+ 'statesp.remove_useless_states' : True ,
7676 }
7777
7878
@@ -149,7 +149,7 @@ class StateSpace(LTI):
149149 Setting dt = 0 specifies a continuous system, while leaving dt = None
150150 means the system timebase is not specified. If 'dt' is set to True, the
151151 system will be treated as a discrete time system with unspecified sampling
152- time. The default value of 'dt' is None and can be changed by changing the
152+ time. The default value of 'dt' is None and can be changed by changing the
153153 value of ``control.config.defaults['statesp.default_dt']``.
154154
155155 """
@@ -788,15 +788,15 @@ def minreal(self, tol=0.0):
788788
789789 # TODO: add discrete time check
790790 def returnScipySignalLTI (self ):
791- """Return a list of a list of scipy.signal.lti objects.
791+ """Return a list of a list of :class:` scipy.signal.lti` objects.
792792
793793 For instance,
794794
795795 >>> out = ssobject.returnScipySignalLTI()
796796 >>> out[3][5]
797797
798- is a signal. scipy.lti object corresponding to the transfer function from
799- the 6th input to the 4th output."""
798+ is a :class:` scipy.signal. lti` object corresponding to the transfer
799+ function from the 6th input to the 4th output."""
800800
801801 # Preallocate the output.
802802 out = [[[] for _ in range (self .inputs )] for _ in range (self .outputs )]
@@ -809,8 +809,9 @@ def returnScipySignalLTI(self):
809809 return out
810810
811811 def append (self , other ):
812- """Append a second model to the present model. The second
813- model is converted to state-space if necessary, inputs and
812+ """Append a second model to the present model.
813+
814+ The second model is converted to state-space if necessary, inputs and
814815 outputs are appended and their order is preserved"""
815816 if not isinstance (other , StateSpace ):
816817 other = _convertToStateSpace (other )
@@ -870,8 +871,8 @@ def sample(self, Ts, method='zoh', alpha=None, prewarp_frequency=None):
870871
871872 prewarp_frequency : float within [0, infinity)
872873 The frequency [rad/s] at which to match with the input continuous-
873- time system's magnitude and phase (the gain=1 crossover frequency,
874- for example). Should only be specified with method='bilinear' or
874+ time system's magnitude and phase (the gain=1 crossover frequency,
875+ for example). Should only be specified with method='bilinear' or
875876 'gbt' with alpha=0.5 and ignored otherwise.
876877
877878 Returns
@@ -881,7 +882,7 @@ def sample(self, Ts, method='zoh', alpha=None, prewarp_frequency=None):
881882
882883 Notes
883884 -----
884- Uses the command 'cont2discrete' from scipy.signal
885+ Uses :func:` scipy.signal.cont2discrete`
885886
886887 Examples
887888 --------
@@ -896,7 +897,7 @@ def sample(self, Ts, method='zoh', alpha=None, prewarp_frequency=None):
896897 if (method == 'bilinear' or (method == 'gbt' and alpha == 0.5 )) and \
897898 prewarp_frequency is not None :
898899 Twarp = 2 * np .tan (prewarp_frequency * Ts / 2 )/ prewarp_frequency
899- else :
900+ else :
900901 Twarp = Ts
901902 Ad , Bd , C , D , _ = cont2discrete (sys , Twarp , method , alpha )
902903 return StateSpace (Ad , Bd , C , D , Ts )
0 commit comments