@@ -22,13 +22,13 @@ def test_reachable_form(self):
22
22
D_true = 42.0
23
23
24
24
# Perform a coordinate transform with a random invertible matrix
25
- T_true = np .matrix ([[- 0.27144004 , - 0.39933167 , 0.75634684 , 0.44135471 ],
25
+ T_true = np .array ([[- 0.27144004 , - 0.39933167 , 0.75634684 , 0.44135471 ],
26
26
[- 0.74855725 , - 0.39136285 , - 0.18142339 , - 0.50356997 ],
27
27
[- 0.40688007 , 0.81416369 , 0.38002113 , - 0.16483334 ],
28
28
[- 0.44769516 , 0.15654653 , - 0.50060858 , 0.72419146 ]])
29
- A = np .linalg .solve (T_true , A_true )* T_true
29
+ A = np .linalg .solve (T_true , A_true ). dot ( T_true )
30
30
B = np .linalg .solve (T_true , B_true )
31
- C = C_true * T_true
31
+ C = C_true . dot ( T_true )
32
32
D = D_true
33
33
34
34
# Create a state space system and convert it to the reachable canonical form
@@ -69,11 +69,11 @@ def test_modal_form(self):
69
69
D_true = 42.0
70
70
71
71
# Perform a coordinate transform with a random invertible matrix
72
- T_true = np .matrix ([[- 0.27144004 , - 0.39933167 , 0.75634684 , 0.44135471 ],
72
+ T_true = np .array ([[- 0.27144004 , - 0.39933167 , 0.75634684 , 0.44135471 ],
73
73
[- 0.74855725 , - 0.39136285 , - 0.18142339 , - 0.50356997 ],
74
74
[- 0.40688007 , 0.81416369 , 0.38002113 , - 0.16483334 ],
75
75
[- 0.44769516 , 0.15654653 , - 0.50060858 , 0.72419146 ]])
76
- A = np .linalg .solve (T_true , A_true )* T_true
76
+ A = np .linalg .solve (T_true , A_true ). dot ( T_true )
77
77
B = np .linalg .solve (T_true , B_true )
78
78
C = C_true * T_true
79
79
D = D_true
@@ -98,9 +98,9 @@ def test_modal_form(self):
98
98
C_true = np .array ([[1 , 0 , 0 , 1 ]])
99
99
D_true = np .array ([[0 ]])
100
100
101
- A = np .linalg .solve (T_true , A_true ) * T_true
101
+ A = np .linalg .solve (T_true , A_true ). dot ( T_true )
102
102
B = np .linalg .solve (T_true , B_true )
103
- C = C_true * T_true
103
+ C = C_true . dot ( T_true )
104
104
D = D_true
105
105
106
106
# Create state space system and convert to modal canonical form
@@ -132,9 +132,9 @@ def test_modal_form(self):
132
132
C_true = np .array ([[0 , 1 , 0 , 1 ]])
133
133
D_true = np .array ([[0 ]])
134
134
135
- A = np .linalg .solve (T_true , A_true ) * T_true
135
+ A = np .linalg .solve (T_true , A_true ). dot ( T_true )
136
136
B = np .linalg .solve (T_true , B_true )
137
- C = C_true * T_true
137
+ C = C_true . dot ( T_true )
138
138
D = D_true
139
139
140
140
# Create state space system and convert to modal canonical form
@@ -173,13 +173,13 @@ def test_observable_form(self):
173
173
D_true = 42.0
174
174
175
175
# Perform a coordinate transform with a random invertible matrix
176
- T_true = np .matrix ([[- 0.27144004 , - 0.39933167 , 0.75634684 , 0.44135471 ],
176
+ T_true = np .array ([[- 0.27144004 , - 0.39933167 , 0.75634684 , 0.44135471 ],
177
177
[- 0.74855725 , - 0.39136285 , - 0.18142339 , - 0.50356997 ],
178
178
[- 0.40688007 , 0.81416369 , 0.38002113 , - 0.16483334 ],
179
179
[- 0.44769516 , 0.15654653 , - 0.50060858 , 0.72419146 ]])
180
- A = np .linalg .solve (T_true , A_true )* T_true
180
+ A = np .linalg .solve (T_true , A_true ). dot ( T_true )
181
181
B = np .linalg .solve (T_true , B_true )
182
- C = C_true * T_true
182
+ C = C_true . dot ( T_true )
183
183
D = D_true
184
184
185
185
# Create a state space system and convert it to the observable canonical form
0 commit comments