[SciPy-Dev] Discrete-time additions to scipy.signal

Ralf Gommers ralf.gommers at googlemail.com
Thu Apr 28 17:24:50 EDT 2011


On Wed, Apr 27, 2011 at 1:28 PM, Jeffrey Armstrong <jba at sdf.lonestar.org> wrote:
> On Tue, 26 Apr 2011, Ralf Gommers wrote:
>
>> Hi Jeffrey,
>>
>> I looked through your changes and at first glance it looks pretty good
>> to me. It's not so easy to review however, because it's all in your
>> master branch, it's a lot of code, and there is quite some code added
>> that is later deleted again. It would be easier if you would create
>> separate branches for separate features (not your master branch, keep
>> that a clean mirror of the numpy master branch). There are at least
>> two, the discrete versions of features already present for the
>> continuous domain, and your additions of Riccati, Lyapunov and
>> Sylvester solvers. Perhaps the sort kw for decomp_schur is a third.
>
> Ralf,
>
> I apologize for the lack of branches.  I must confess that this is my
> first large-scale experience in a git environment so I'm still getting the
> hang of it.

Are you trying to do this? If you need any help let me know (offline perhaps).

> You've summarized the changes pretty well:
>
> 1. Duplicating most of the continuous functionality in the discrete domain
> (dltisys.py, c2d.py)

> 2. Adding Lyapunov and algebraic Riccati equation solvers (lyap.py,
> dlyap.py, dare.py, care.py, decomp_schur.py, trsyl flapack wrapper).
>
> The sort kw in decomp_schur is necessary to properly solve the algebraic
> Riccati equation.

(1) looks like a good addition, and fits in well in scipy.signal.
(2) could use some discussion, if and where it belongs in scipy. It
looks like these equations are fairly widely used in control theory
(which I don't know all that much about), but they're a bit more
exotic/inaccessible than your average scipy function.

Cheers,
Ralf


>>
>> The current names of modules are not very descriptive. They could be
>> changed to something like:
>> c2d -> cont2discrete
>> care+dare -> riccati
>> lyap+dlyap -> lyapunov
>> Or maybe put it in a "control" module.
>
> The module names could be more descriptive, I agree.  While I think the
> addition of a "control" module in scipy would perhaps be a good idea, I
> didn't have the audacity to make such a suggestion from the start.
>
>>
>> Can you explain the relation to pydare a bit? Is this code all from
>> pydare and are you relicensing it as BSD and proposing it for
>> inclusion, or is part of this new code?
>>
>
> The pydare package (http://code.google.com/p/pydare/) is a small package
> providing discrete algebraic Riccati and Lyapunov equation solvers, and I
> am the sole author.  The code was originally licensed under GPLv3 because
> the discrete Lyapunov equation solver utilized code that had been directly
> translated from some Octave code into Python, which was also GPL.  The
> pydare package can also exploit SLICOT, another GPL'd package.
>
> To contribute the code to SciPy, I do indeed relicense the entirety of my
> code as BSD-licensed, and I'll assign copyright or whatever as necessary.
> The GPL-based code in the discrete Lyapunov equation solver has been
> redacted in its entirety, replaced by original code that relies on the
> solution of a Sylvester equation instead (requiring an inversion, which is
> less than ideal).  All references to SLICOT have also been removed, and
> there is not any code present any longer that is not original.
>
> Jeff Armstrong - jba at sdf.lonestar.org
> SDF Public Access UNIX System - http://sdf.lonestar.org
> _______________________________________________
> SciPy-Dev mailing list
> SciPy-Dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-dev
>



More information about the SciPy-Dev mailing list