@@ -723,26 +723,26 @@ def test_time_series_data_convention_2D(self, siso_ss1):
723
723
assert y .ndim == 1 # SISO returns "scalar" output
724
724
assert t .shape == y .shape # Allows direct plotting of output
725
725
726
- @pytest .mark .usefixtures ("editsdefaults" )
727
726
@pytest .mark .parametrize ("fcn" , [ct .ss , ct .tf , ct .ss2io ])
728
727
@pytest .mark .parametrize ("nstate, nout, ninp, squeeze, shape" , [
729
728
[1 , 1 , 1 , None , (8 ,)],
730
729
[2 , 1 , 1 , True , (8 ,)],
731
730
[3 , 1 , 1 , False , (1 , 8 )],
732
731
# [4, 1, 1, 'siso', (8,)], # Use for later 'siso' implementation
733
- [1 , 2 , 1 , None , (2 , 8 )],
734
- [2 , 2 , 1 , True , (2 , 8 )],
735
- [3 , 2 , 1 , False , (2 , 8 )],
736
- # [4 , 2, 1, 'siso', (2, 8)], # Use for later 'siso' implementation
737
- [1 , 1 , 2 , None , (8 ,)],
738
- [2 , 1 , 2 , True , (8 ,)],
739
- [3 , 1 , 2 , False , (1 , 8 )],
740
- # [4 , 1, 2, 'siso', (1, 8)], # Use for later 'siso' implementation
741
- [1 , 2 , 2 , None , (2 , 8 )],
742
- [2 , 2 , 2 , True , (2 , 8 )],
743
- [3 , 2 , 2 , False , (2 , 8 )],
744
- # [4 , 2, 2, 'siso', (2, 8)], # Use for later 'siso' implementation
732
+ [3 , 2 , 1 , None , (2 , 8 )],
733
+ [4 , 2 , 1 , True , (2 , 8 )],
734
+ [5 , 2 , 1 , False , (2 , 8 )],
735
+ # [6 , 2, 1, 'siso', (2, 8)], # Use for later 'siso' implementation
736
+ [3 , 1 , 2 , None , (8 ,)],
737
+ [4 , 1 , 2 , True , (8 ,)],
738
+ [5 , 1 , 2 , False , (1 , 8 )],
739
+ # [6 , 1, 2, 'siso', (1, 8)], # Use for later 'siso' implementation
740
+ [4 , 2 , 2 , None , (2 , 8 )],
741
+ [5 , 2 , 2 , True , (2 , 8 )],
742
+ [6 , 2 , 2 , False , (2 , 8 )],
743
+ # [7 , 2, 2, 'siso', (2, 8)], # Use for later 'siso' implementation
745
744
])
745
+ @pytest .mark .usefixtures ("editsdefaults" )
746
746
def test_squeeze (self , fcn , nstate , nout , ninp , squeeze , shape ):
747
747
# Figure out if we have SciPy 1+
748
748
scipy0 = StrictVersion (sp .__version__ ) < '1.0'
@@ -818,13 +818,13 @@ def test_squeeze(self, fcn, nstate, nout, ninp, squeeze, shape):
818
818
_ , yvec = ct .step_response (sys , tvec )
819
819
assert yvec .shape == (sys .outputs , 8 )
820
820
821
- _ , yvec , xvec = ct .forced_response (
822
- sys , tvec , uvec , 0 , return_x = True )
823
- assert yvec .shape == (sys .outputs , 8 )
824
821
if isinstance (sys , ct .StateSpace ):
822
+ _ , yvec , xvec = ct .forced_response (
823
+ sys , tvec , uvec , 0 , return_x = True )
825
824
assert xvec .shape == (sys .states , 8 )
826
825
else :
827
- assert xvec .shape [1 ] == 8
826
+ _ , yvec = ct .forced_response (sys , tvec , uvec , 0 )
827
+ assert yvec .shape == (sys .outputs , 8 )
828
828
829
829
# For InputOutputSystems, also test input_output_response
830
830
if isinstance (sys , ct .InputOutputSystem ) and not scipy0 :
0 commit comments