Skip to content

rlocus with kvect argument doesn't compute good limits #787

Closed

Description

@roryyorke

Example:

import control as ct
g = ct.tf([1,2], [1,2,10])
kvect = ct.rlocus(g)[1]
plt.figure()
ct.rlocus(g, kvect=kvect);

result:

image

image

I'd expect these two to look the same.

This is because axis limits are only calculated when argument kvect is None:

    if kvect is None:
        start_mat = _RLFindRoots(nump, denp, [1])
        kvect, mymat, xlim, ylim = _default_gains(nump, denp, xlim, ylim)
    else:
        start_mat = _RLFindRoots(nump, denp, [kvect[0]])
        mymat = _RLFindRoots(nump, denp, kvect)
        mymat = _RLSortRoots(mymat)

Activity

  1. linked a pull request that will close this issuefix gain handling in rlocus and sisotool #809on Dec 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions