Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: ss2tf error with double integrator #17405

Open
roryyorke opened this issue Nov 12, 2022 · 0 comments
Open

BUG: ss2tf error with double integrator #17405

roryyorke opened this issue Nov 12, 2022 · 0 comments
Labels
defect A clear bug or issue that prevents SciPy from being installed or used as expected scipy.signal

Comments

@roryyorke
Copy link
Contributor

Describe your issue.

Initially from python-control/python-control#715 (comment)

ss2tf adds an extra, very fast stable zero for double integrator systems.

Reproducing Code Example

import numpy as np
from scipy import signal
p = np.array([ -2, 0, 0])
z = np.array([ -1])
k = 1
bb, a = signal.ss2tf(*signal.zpk2ss(z,p,k))
print(np.roots(bb[0]), np.roots(a))

Error message

# not an error message, but the output; expect [-1], [-2, 0, 0], but get:
[-7.50599938e+14 -1.00000000e+00] [-2.  0.  0.]

SciPy/NumPy/Python version information

1.9.1 1.23.1 sys.version_info(major=3, minor=10, micro=0, releaselevel='final', serial=0)

@roryyorke roryyorke added the defect A clear bug or issue that prevents SciPy from being installed or used as expected label Nov 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect A clear bug or issue that prevents SciPy from being installed or used as expected scipy.signal
Projects
None yet
Development

No branches or pull requests

2 participants