Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

handle empty pole vector for timevector calculation#485

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
murrayrm merged 1 commit intopython-control:masterfrombnavigator:timevector-fix
Dec 30, 2020
Merged
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletionscontrol/timeresp.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -846,8 +846,8 @@ def _ideal_tfinal_and_dt(sys, is_step=True):
The system whose time response is to be computed
is_step : bool
Scales the dc value by the magnitude of the nonzero mode since
integrating the impulse response gives
:math:`\int e^{-\lambda t} = -e^{-\lambda t}/ \lambda`
integrating the impulse response gives
:math:`\\int e^{-\\lambda t} = -e^{-\\lambda t}/\\lambda`
Default is True.

Returns
Expand DownExpand Up@@ -900,8 +900,10 @@ def _ideal_tfinal_and_dt(sys, is_step=True):
p_u, p = p[m_u], p[~m_u]
if p_u.size > 0:
m_u = (p_u.real < 0) & (np.abs(p_u.imag) < sqrt_eps)
t_emp = np.max(log_decay_percent / np.abs(np.log(p_u[~m_u])/dt))
tfinal = max(tfinal, t_emp)
if np.any(~m_u):
t_emp = np.max(
log_decay_percent / np.abs(np.log(p_u[~m_u]) / dt))
tfinal = max(tfinal, t_emp)

# zero - negligible effect on tfinal
m_z = np.abs(p) < sqrt_eps
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp