Zero issueshttps://git.ligo.org/sean-leavey/zero/-/issues2018-06-01T10:11:13Zhttps://git.ligo.org/sean-leavey/zero/-/issues/6Allow varying of parameters other than frequency2018-06-01T10:11:13ZSean LeaveyAllow varying of parameters other than frequencyAllow the user to set a particular frequency and then vary e.g. resistor values and plot the results, instead of always having to vary frequency.
Could take this a step further and allow multiple parameters to be varied at once.
Could ...Allow the user to set a particular frequency and then vary e.g. resistor values and plot the results, instead of always having to vary frequency.
Could take this a step further and allow multiple parameters to be varied at once.
Could also allow the user to specify a generator for the x-axis, to allow for adaptive simulations, i.e. ones where the next frequency is calculated based on the gradient between the last two, to allow more points to be simulated near where interesting features occur. Could maybe provide such adaptive generators in the toolbox.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/7Implement SPARSE matrix solver via Cython2018-06-01T10:16:13ZSean LeaveyImplement SPARSE matrix solver via CythonLISO uses the SPARSE library for circuit simulation. It should be possible to use Cython code to interface with the library. Now that the solver has been split off from the `Circuit` object (e774a0d0) this should be quite straightforward...LISO uses the SPARSE library for circuit simulation. It should be possible to use Cython code to interface with the library. Now that the solver has been split off from the `Circuit` object (e774a0d0) this should be quite straightforward to do. With the same library it should be possible to produce identical results to LISO.
Note that this will probably need a Makefile to run during `setup.py`.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/8Implement symbolic solver2018-06-01T10:16:13ZSean LeaveyImplement symbolic solverAs with #7, it should be possible to implement a symbolic solver using e.g. Sympy. This probably won't work for large circuits, but for small one it surely will.
Related: for displaying the results, adapt the LaTeX equation code in `dis...As with #7, it should be possible to implement a symbolic solver using e.g. Sympy. This probably won't work for large circuits, but for small one it surely will.
Related: for displaying the results, adapt the LaTeX equation code in `display.py`.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/9Support not loaded/not connected components2020-01-28T15:06:09ZSean LeaveySupport not loaded/not connected componentsWhen the value of a component is "NL" or "NC", add the component to the circuit but have the solver exclude such components from the calculations. This means that the component will still show up in the graph or representation of the cir...When the value of a component is "NL" or "NC", add the component to the circuit but have the solver exclude such components from the calculations. This means that the component will still show up in the graph or representation of the circuit, and can still have its value assigned interactively, or from within a loop.Node graphsSean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/10Support equivalent series resistance/inductance in components2018-06-01T10:24:24ZSean LeaveySupport equivalent series resistance/inductance in componentsPassive components should probably all just inherit from some component that has a complex impedance. `Resistors` would therefore just be a convenient way to represent such a component with a real impedance. It should be straightforward ...Passive components should probably all just inherit from some component that has a complex impedance. `Resistors` would therefore just be a convenient way to represent such a component with a real impedance. It should be straightforward to calculate a complex impedance given a real resistance and equivalent series or parallel inductance or capacitance. The same is true for inductors and capacitors.
Related: investigate the `c0805` component in LISO.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/11Allow config files (e.g. op-amp libraries) to be loaded in context2018-11-22T22:00:49ZSean LeaveyAllow config files (e.g. op-amp libraries) to be loaded in context```python
with ConfigParser("my-library.txt"):
# run simulation using my-library.txt
analysis.calculate_tfs(...)
``````python
with ConfigParser("my-library.txt"):
# run simulation using my-library.txt
analysis.calculate_tfs(...)
```Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/13Allow arbitrary noise spectra/functions to be defined for op-amps, resistors,...2018-11-22T22:01:13ZSean LeaveyAllow arbitrary noise spectra/functions to be defined for op-amps, resistors, etc.There is nothing stopping op-amps, resistors, etc. from having arbitrary noise spectra. The config file could support the standard white noise + 1/f noise parameters, or alternatively support noise spectra loaded from user files (perhaps...There is nothing stopping op-amps, resistors, etc. from having arbitrary noise spectra. The config file could support the standard white noise + 1/f noise parameters, or alternatively support noise spectra loaded from user files (perhaps overridden using a context manager - see #11). Such loaded files would either need to have the same frequency axis as the analysis, or be interpolated, with suitable warnings where the ranges do not overlap.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/14Allow op-amp output impedance to be defined in parameter file2018-11-19T16:30:19ZSean LeaveyAllow op-amp output impedance to be defined in parameter fileThe LISO op-amp library doesn't let one define op-amp output impedance, but it does potentially matter to correctly simulate certain op-amp behaviours. Investigate how tricky it would be to add this.The LISO op-amp library doesn't let one define op-amp output impedance, but it does potentially matter to correctly simulate certain op-amp behaviours. Investigate how tricky it would be to add this.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/15Allow all applicable op-amp parameters to be set as a function of frequency2018-06-04T10:30:22ZSean LeaveyAllow all applicable op-amp parameters to be set as a function of frequencyRelated to #14. Allow the specification of gain vs frequency instead of a0 and GBW, and any other applicable frequency-dependent behaviour.Related to #14. Allow the specification of gain vs frequency instead of a0 and GBW, and any other applicable frequency-dependent behaviour.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/17Detect unconnected nodes in input file and warn user2019-07-03T08:32:34ZSean LeaveyDetect unconnected nodes in input file and warn userNodes that aren't connected to anything can result in outputs that may confuse the user. The simulation currently runs anyway but gets a singular matrix with no results. For example, this circuit without a grounded negative input:
```py...Nodes that aren't connected to anything can result in outputs that may confuse the user. The simulation currently runs anyway but gets a singular matrix with no results. For example, this circuit without a grounded negative input:
```python
from circuit.liso import LisoInputParser
p = LisoInputParser()
p.parse("r r1 1k n1 ninp")
p.parse("op op1 op27 ninp ninm nout")
p.parse("r r2 100k nout ninp")
p.parse("uinput n1")
p.parse("uoutput nout")
p.parse("freq log 1 100k 1000")
p.show()
```
This prints...
```
usr/local/lib/python3.5/dist-packages/scipy/sparse/linalg/dsolve/linsolve.py:192: MatrixRankWarning: Matrix is exactly singular
warn("Matrix is exactly singular", MatrixRankWarning)
```
...but still attempts to plot the (empty) results.
The solver should check that the nodes are all connected to something.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/22Set up integration testing on different platforms2018-06-22T07:17:51ZSean LeaveySet up integration testing on different platforms#21 highlights the need for testing on different versions of Python and different systems. Use Gitlab's CI feature to test on different platforms.#21 highlights the need for testing on different versions of Python and different systems. Use Gitlab's CI feature to test on different platforms.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/23Display matrix and table elements using `Quantity`2018-06-22T21:26:51ZSean LeaveyDisplay matrix and table elements using `Quantity``MatrixDisplay` and `TableDisplay` have a lot of complexity in order to display quantities properly. Change these to use the new `Quantities` class to handle display.`MatrixDisplay` and `TableDisplay` have a lot of complexity in order to display quantities properly. Change these to use the new `Quantities` class to handle display.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/24Use an object to represent noise in op-amps and other components2019-07-12T07:36:23ZSean LeaveyUse an object to represent noise in op-amps and other componentsLISO uses a white noise and 1/f corner frequency to represent op-amp noise. Resistors have only flat Johnson noise. Instead of specifying noise with single numbers, allow components to accept a `NoiseModel` object that allows the user to...LISO uses a white noise and 1/f corner frequency to represent op-amp noise. Resistors have only flat Johnson noise. Instead of specifying noise with single numbers, allow components to accept a `NoiseModel` object that allows the user to specify more complex noise spectra. Such a model could provide a constructor for building a standard LISO-style noise spectrum, but also allow complex data either specified from a file (interpolated to new frequency vector) or using e.g. a `zpk` model.
Examples of noise that LISO can't represent:
- Resistor excess noise
- Noise in chopper-stabilised op-amps, like [LTC2057](http://www.analog.com/en/products/amplifiers/operational-amplifiers/high-voltage-op-amps-greaterthanequalto-12v/ltc2057.html), where there is a bump at the chopping frequencySean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/26Show line with syntax error2018-09-16T14:47:51ZSean LeaveyShow line with syntax errorWhen a syntax error is encountered, show the affected line contents as well as its line number. For example, with the `m` command before it was supported (in e.g. fc5ddd90878987d1fb650340c04479f755b026c1):
```
r r1 1k n1 n2
l l1 10u n2 g...When a syntax error is encountered, show the affected line contents as well as its line number. For example, with the `m` command before it was supported (in e.g. fc5ddd90878987d1fb650340c04479f755b026c1):
```
r r1 1k n1 n2
l l1 10u n2 gnd
l l2 40u n3 gnd # winding ratio 1:2
m m1 .95 l1 l2
r r2 1k n3 gnd
freq log 1 1M 1000
uinput n1
uoutput n3
```
`circuit.liso.base.LisoParserError: LISO syntax error: unexpected parameter count (4) (line 1013)`
This should instead say something like
`circuit.liso.base.LisoParserError: LISO syntax error: unexpected parameter count (4) near "..." (line 1013)`
Not sure if this affects existing tests which look for specific patterns of error message - best check first before making this change.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/28Detect floating secondary circuits when mutual inductance is used2019-07-03T08:35:49ZSean LeaveyDetect floating secondary circuits when mutual inductance is usedSecondary circuits used in conjunction with `m` cannot be floating. Prior to simulating a circuit with mutual inductances, use a graph algorithm to detect if the secondary circuit is grounded at some point and warn the user if not.Secondary circuits used in conjunction with `m` cannot be floating. Prior to simulating a circuit with mutual inductances, use a graph algorithm to detect if the secondary circuit is grounded at some point and warn the user if not.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/29Handle mutual inductances where one component has been deleted2019-08-08T06:14:46ZSean LeaveyHandle mutual inductances where one component has been deletedMutual inductances are stored in `Inductor` objects, but they have no way of knowing if the other inductor has since been deleted from the circuit. Perhaps use `weakref` to check, or have the `Circuit` object deal with cleaning up induc...Mutual inductances are stored in `Inductor` objects, but they have no way of knowing if the other inductor has since been deleted from the circuit. Perhaps use `weakref` to check, or have the `Circuit` object deal with cleaning up inductor references.Node graphsSean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/32Respect LISO's plot ordering when plotting a LISO input or output file.2019-05-07T15:03:13ZSean LeaveyRespect LISO's plot ordering when plotting a LISO input or output file.Since solution merging was introduced in 623a9034, colour wheels on plots are no longer reset when plotting LISO equivalents, so colours for equivalent functions are different. Since now the plotting tool doesn't know the difference betw...Since solution merging was introduced in 623a9034, colour wheels on plots are no longer reset when plotting LISO equivalents, so colours for equivalent functions are different. Since now the plotting tool doesn't know the difference between functions merged from different solutions, add a new plot spec to functions store a "colour wheel group".
UPDATE 2019/05/07: colours now match when comparing LISO to Zero, but absolute order when running a Zero on its own with a LISO input file still differs from what LISO produces.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/35Add solution data dump functions2019-01-28T20:11:30ZSean LeaveyAdd solution data dump functionsSave to CSV, tab separated value, etc...
Eventually it'd be nice to have a standard data container to hold results alongside their plotting logic, and allow further manipulations (e.g. +, -, /, *, etc.) with data provenance stored in th...Save to CSV, tab separated value, etc...
Eventually it'd be nice to have a standard data container to hold results alongside their plotting logic, and allow further manipulations (e.g. +, -, /, *, etc.) with data provenance stored in the object.Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/39Support vinput/voutput in addition to uinput/uoutput?2019-02-04T19:23:27ZSebastian SteinlechnerSupport vinput/voutput in addition to uinput/uoutput?Just a quick thought, maybe it would be helpful for the international audience if the parser would understand `vinput`/`voutput` as an alias of `uinput`/`uoutput`?Just a quick thought, maybe it would be helpful for the international audience if the parser would understand `vinput`/`voutput` as an alias of `uinput`/`uoutput`?Sean LeaveySean Leaveyhttps://git.ligo.org/sean-leavey/zero/-/issues/43Allow individual noise or response functions to be plotted on their own2019-06-13T20:27:53ZSean LeaveyAllow individual noise or response functions to be plotted on their ownCurrently `NoiseDensity` and `Response` functions can `draw` their data to an existing `axis` provided by a `Solution`, but they can't just plot themselves on their own. Furthermore, if you provide the `axis` of a figure you made yoursel...Currently `NoiseDensity` and `Response` functions can `draw` their data to an existing `axis` provided by a `Solution`, but they can't just plot themselves on their own. Furthermore, if you provide the `axis` of a figure you made yourself (e.g. with `Solution.noise_figure()`), the function doesn't add axis labels or grids etc.
The functions should be able to access the same plotting tools that `Solution` uses. Maybe split the plotting stuff out of `Solution` and into somewhere else where it can be used by the functions separately.Sean LeaveySean Leavey