GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gangof4_plot(response) rejects precomputed responses with default options · Issue #1264 · python-control/python-control

gangof4_plot(response) rejects precomputed responses with default options #1264

New issue
Copy link
New issue
Copy link
Open
Open
gangof4_plot(response) rejects precomputed responses with default options#1264
Copy link

Description

@huxiaoyi-ovo
huxiaoyi-ovo
opened on Oct 28, 2026
Issue body actions

Title: gangof4_plot(response) rejects precomputed responses with default options

Problem

The documented gangof4_plot(response) call appears to fail when passed a precomputed Gang of Four response.

Minimal reproducer:

import control as ct

P = ct.tf([1], [1, 1])
C = ct.tf([2], [1])

response = ct.gangof4_response(P, C)
ct.gangof4_plot(response)

Expected: Plot the precomputed 2×2 frequency response.

Problem in current main: The frequency-option check treats the default Hz=False as an invalid override because False is not None evaluates to True. This forces a ValueError even when no frequency options were supplied.

There is also a separate argument-forwarding issue: the same branch calls response.plot(kwargs) instead of response.plot(**kwargs), passing the options dictionary as a positional argument.

Both issues are visible in control/freqplot.py. The control-flow condition has been checked independently; I have not executed the complete unmodified package locally.

Would you consider these bugs in the documented response-first API? If so, I can provide a focused fix and regression tests.

Related: #1261, following the request to discuss the behavior in an issue before submitting a PR.

Activity

  1. slivingston commented on Oct 28, 2026

    @slivingston
    slivingston
    on Oct 28, 2026
    Member
    More actions

    @huxiaoyi-ovo Please add the AI disclosure if you used it to write this issue etc.

  2. huxiaoyi-ovo commented on Oct 29, 2026

    @huxiaoyi-ovo
    huxiaoyi-ovo
    on Oct 29, 2026
    Author
    More actions

    AI disclosure: ChatGPT-6 astra ultra assisted with code analysis and drafting this issue.

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

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.