Skip to content

modal canonical form does not work with repeated eigenvalues #318

Description

@murrayrm

The modal_form() function appears to assume that all eigenvalues are distinct. The following example gives strange results:

import control as ct
sys_repeat = ct.StateSpace([[-1, 1], [0, -1]], [[0], [1]], [[1, 0]], [[0]])
sys_modal, T = ct.modal_form(sys_repeat)
print(sys_modal)

which yields

A = [[-1.00000000e+00  0.00000000e+00]
 [ 2.22044605e-16 -1.00000000e+00]]

B = [[4.50359963e+15]
 [4.50359963e+15]]

C = [[-1.  1.]]

D = [[0.]]

The problem is that the transformation T as computed in modal_form is singular:

[[-1.00000000e+00  1.00000000e+00]
 [ 2.22044605e-16  0.00000000e+00]]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions