Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

signal.chirp(method='hyp') disallows hyperbolic upsweep #3285

Closed
pijyoi opened this issue Feb 5, 2014 · 1 comment · Fixed by #3293
Closed

signal.chirp(method='hyp') disallows hyperbolic upsweep #3285

pijyoi opened this issue Feb 5, 2014 · 1 comment · Fixed by #3293
Milestone

Comments

@pijyoi
Copy link
Contributor

pijyoi commented Feb 5, 2014

The phase formula used in fact works for both cases:

  1. downsweep: f0 > f1 > 0.0
  2. upsweep: f1 > f0 > 0.0
    However the code (and comments) enforces the downsweep case.
@WarrenWeckesser
Copy link
Member

You are right, it should be able to handle both cases. I'll create a pull request to fix this in the next day or so.

WarrenWeckesser added a commit to WarrenWeckesser/scipy that referenced this issue Feb 6, 2014
The restriction that f0 > f1 > 0 has been removed.  The only requirement
is that f0 and f1 are not zero.  Negative frequencies can be given.
(Even f0 and f1 with opposite signs are allowed, but this is not expected
to be a useful case.)  The degenerate case with f0 == f1 is now also
handled.

Two small changes not directly related to the above change:
* Changed "geometric" to "logarithmic" in the argument of the ValueError
  that can be raised when method="logaithmic".
* Added `t = asarray(t)` in the function _chirp_phase, so the 't' argument
  of `chirp` is now `array_like`.

Closes scipygh-3285.
WarrenWeckesser added a commit to WarrenWeckesser/scipy that referenced this issue Feb 6, 2014
The restriction that f0 > f1 > 0 has been removed.  The only requirement
is that f0 and f1 are not zero.  Negative frequencies can be given.
(Even f0 and f1 with opposite signs are allowed, but this is not expected
to be a useful case.)  The degenerate case with f0 == f1 is now also
handled.

Two small changes not directly related to the above change:
* Changed "geometric" to "logarithmic" in the argument of the ValueError
  that can be raised when method="logaithmic".
* Added `t = asarray(t)` in the function _chirp_phase, so the 't' argument
  of `chirp` is now `array_like`.

Closes scipygh-3285.
@rgommers rgommers added this to the 0.14.0 milestone Feb 23, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants