A non-band-limited gaussian function oscillator. Output ranges from minval to 1.
LFGauss implements the formula:
where x is to vary in the range -1 to 1 over the period dur. minval is the initial value at -1.
duration of one full cycle ( for freq input: dur = 1 / freq )
relative width of the bell. Best to keep below 0.25 when used as envelope. (default: 0.1)
initial offset (default: 0)
if loop is > 0, UGen oscillates. Otherwise it calls doneAction after one cycle (default: 1)
doneAction, which is evaluated after cycle completes (2 frees the synth, default: 0). See Done for more detail.
Returns the lowest value for the given parameters, which is
exp(1.0 / (-2.0 * squared(width)))
Scales the output to the given range. This can be convenient when using LFGauss as an envelope (see example below).
assuming iphase = 0:
minval for a given width:
minval = exp(-1.0 / (2.0 * squared(width)))
width for a given minval:
width = sqrt(-1.0 / log(minval))
width at half maximum (0.5):
(2 * sqrt(2 * log(2)) * width) = ca. 2.355 * width
inf. When using it as an envelope, it has to start at some smaller value, and it has an offset for this value. You can remove this offset by explicitly setting the range, e.g. to
0..1(this is the default).