Manual
van Ties

# Funs

### a rational function oscillator

## The short story

Funs’ outputs two related waves. The wave shapes is determined by three parameters: a, b and c.

On the display on the panel the wave shapes are shown (wave 1 in yellow, wave 2 in red). On each wave 7 points are marked. The left- and rightmost points are fixed: these are a zero-point of the wave.

Parameter c determines the other zero-point.

Parameter a takes values between 0 and c and determines the position of the maximum of the wave.

Parameter b takes values between a and c determines the position where the wave equals ½√2 (in proportion to the maximum).

If the knobs for these three parameters are all at noon, the resulting waves are a good approximation of a sine.

## Other features

The FM jack provides linear through-0 FM.

The pitch knob can be quantized in octaves or semitones via the context menu. This only affects the knob, not the V/octave input.

Funs can work with polyphonically. The number of channels is determined be the number of channels coming in at the V/oct jack. (The two waves are flipped for even numbered channels.)

## The long story

We start with a function g : [0, ½] → [0, 1]. This is going to be half a wave. We impose the following five conditions on it:

g(0) = 0
g(½) = 0
g(a) = 1
g’(a) = 0
g(b) = ½√2

where a and b are parameters which are going to determine the shape of out wave. In particular, a determines the maximum of the wave. Note that g(x) = sin(2πx) is a solution for the case a = ¼ and b = ⅜.

We take g to be a rational function though, namely one of numerator and denominator degree 2, i.e. it’s of the form

g(x) =
p0 + p1x + p2x2
q0 + q1x + q2x2

The solution is the function

g(x) =
x(2x – 1)(a – b)2
a2[2(√2 – 1)b2 – (√2 – 1)b + x(2x – 1)] + b x[–2a(2(√2 – 1)b + 2x – √2) + b(2√2x – 1) – (√2 – 1)x]

To make this into a full wave function g̅, we combine two half waves:

g̅(x) =

g(x) | for 0 ≤ x < ½
– g(1 – x) | for ½ ≤ x < 1

Then we introduce a second function, h : [0, 1] → [0, 1]. This one is going to be our phase distortion, i.e.: the final wave is going to be something like f(x) = g̅(h(x)). We impose the following four conditions on this one:

h(0) = 0
h(1) = 1
h’(0) = g’(1)
h(c) = ½

The third condition makes sure there are no cusps in h. The parameter c determines the shape the distortion. Since g̅ crosses 0 at x = ½, c determines the zero-crossing of our final wave f. For c = ½ we are going to have no distortion, i.e. h(x) = x.

We take h to be a rational function as well, namely of the form

h(x) =
p0 + p1x
q0 + q1x + q2x2

Then we get two solutions:

h±(x) =
2(c3 – 2c2 + c)x
x(2c3 – c(x – 3)) + c2(2x2 – 7x + 1) ± √[c(4c3 – 12c2 + 13c – 4)] (x – 1)(c – x)

This is why we end up with two wave outputs on our module. The final wave forms are then

f±(x) = g̅(h±(x))