Generating signals

SignalAnalysis.chirpFunction
chirp(freq1, freq2, duration)
chirp(freq1, freq2, duration, fs; shape, phase, window)

Generates a frequency modulated chirp signal from freq1 to freq2 and specified duration at frame rate fs. The type of frequency modulation may be controlled using shape (:linear (default) or :hyperbolic). The starting phase and window type may be optionally specified.

Examples:

julia> x = chirp(5kHz, 7kHz, 100ms, 44.1kHz)
SampledSignal @ 44100.0 Hz, 4410-element Array{Complex{Float64},1}:
  ⋮

julia> x = chirp(5kHz, 7kHz, 100ms, 44.1kHz; phase=45°, window=hamming)
SampledSignal @ 44100.0 Hz, 4410-element Array{Complex{Float64},1}:
  ⋮

julia> x = chirp(5kHz, 7kHz, 100ms, 44.1kHz; shape=:hyperbolic, window=(tukey,0.05))
SampledSignal @ 44100.0 Hz, 4410-element Array{Complex{Float64},1}:
  ⋮
source
SignalAnalysis.cwMethod
cw(freq, duration, fs; phase, window)

Generates a sinusoidal signal with specified freq and duration at frame rate fs. The starting phase and window type may be optionally specified.

Examples:

julia> x = cw(5kHz, 200ms, 44.1kHz)
SampledSignal @ 44100.0 Hz, 8820-element Array{Complex{Float64},1}:
  ⋮

julia> x = cw(5kHz, 200ms, 44.1kHz; window=hamming)
SampledSignal @ 44100.0 Hz, 8820-element Array{Complex{Float64},1}:
  ⋮

julia> x = cw(-5kHz, 200ms, 44.1kHz; phase=45°, window=(tukey, 0.05))
SampledSignal @ 44100.0 Hz, 8820-element Array{Complex{Float64},1}:
  ⋮
source