Skip to content

Commit 316945d

Browse files
committed
use super() for LTI functions
1 parent effd6b6 commit 316945d

File tree

4 files changed

+4
-6
lines changed

4 files changed

+4
-6
lines changed

control/frdata.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def __init__(self, *args, **kwargs):
204204
w=1.0/(absolute(self.fresp[i, j, :]) + 0.001), s=0.0)
205205
else:
206206
self.ifunc = None
207-
LTI.__init__(self, self.fresp.shape[1], self.fresp.shape[0])
207+
super().__init__(self.fresp.shape[1], self.fresp.shape[0])
208208

209209
def __str__(self):
210210
"""String representation of the transfer function."""

control/namedio.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,7 @@ class _NamedIOStateSystem(_NamedIOSystem):
131131
def __init__(
132132
self, inputs=None, outputs=None, states=None, name=None):
133133
# Parse and store the system name, inputs, and outputs
134-
_NamedIOSystem.__init__(
135-
self, inputs=inputs, outputs=outputs, name=name)
134+
super().__init__(inputs=inputs, outputs=outputs, name=name)
136135

137136
# Parse and store the number of states
138137
self.set_states(states)

control/statesp.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -309,8 +309,7 @@ def __init__(self, *args, keywords=None, **kwargs):
309309
D = np.zeros((C.shape[0], B.shape[1]))
310310
D = _ssmatrix(D)
311311

312-
# TODO: use super here?
313-
LTI.__init__(self, inputs=D.shape[1], outputs=D.shape[0])
312+
super().__init__(inputs=D.shape[1], outputs=D.shape[0])
314313
self.A = A
315314
self.B = B
316315
self.C = C

control/xferfcn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ def __init__(self, *args, **kwargs):
233233
if zeronum:
234234
den[i][j] = ones(1)
235235

236-
LTI.__init__(self, inputs, outputs)
236+
super().__init__(inputs, outputs)
237237
self.num = num
238238
self.den = den
239239

0 commit comments

Comments
 (0)