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 — Some way of stepping a system? · Issue #83 · python-control/python-control

Some way of stepping a system? #83

New issue
Copy link
New issue
Copy link
Closed
#558
Closed
Some way of stepping a system?#83
#558
Copy link
Labels
enhancement

Description

@tomkcook
tomkcook
opened on Apr 14, 2016
Issue body actions

I'm not sure if I'm missing something really obvious here.

I can simulate a system given a complete input time series using control.lsim().

But how can I simulate a system where I get the samples one at a time and want to know the output after each one? For instance, if I'm using it to control something or process audio or whatever?

The best I've come up with so far is to convert it to a state-space representation (if it isn't already), discretise it using the sample() function (again, if it isn't already) and manually run the system equations. Is there not some way of doing this built in?

Activity

  1. cwrowley commented on Apr 19, 2016

    @cwrowley
    cwrowley
    on Apr 19, 2016
    Contributor
    More actions

    I don't believe there is a ready-made function to do what you are looking for, but I am curious why you want to simulate the system one sample at a time. One reason could be that you're determining the input from some sort of feedback law; in that case, one would normally make a new closed-loop system, for instance using control.feedback, and simulate that, for instance with control.lsim. Another reason could be that you'd like to do something in real time, with actual hardware, and then I think you'd be better off just manually running the system equations, as you describe.

  2. tomkcook commented on Apr 19, 2016

    @tomkcook
    tomkcook
    on Apr 19, 2016
    Author
    More actions

    I'm not working in realtime as such, but I am trying to integrate a python.control system into a larger simulation where it forms part of a feedback loop where the rest is non-python and so the samples come one at a time.

    It'd be very useful to have a way of 'stepping' a continuous system like this, but I realise there's potentially a lot of work involved - everyone will have their own ideas about which integrator to use and as soon as you get into Runge-Kutta and related methods then you have to think about tolerances, steps backwards in time etc.

  3. murrayrm
    added
    enhancement
    on Dec 30, 2017
  4. sawyerbfuller
    linked a pull request that will close this issuenew dynamics and output functions for statespace and iosystems #558on Mar 19, 2021
  5. sawyerbfuller
    closed this as completedon Jun 5, 2023
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

    enhancement

    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.