## Week 01

*
The upcoming Chimaera firmware release 0.6.0 will ship with support for velocity signals. This patch-a-week covers the digital filtering technique involved.
*

### Velocity signal filtering

Although the raw interpolated positional signals are very smooth, the derived velocity signals can be quite noisy. For the velocity signal to be of use as a direct mapping to musical parameters, the velocity signal needs to be smoothed, aka filtered.

*Raw x-dimension and corresponding x-velocity of arbitrary sensor array sweeps.*

We use a variable cutoff/phase, first-order Infinite Impulse Response (IIR) filter to smooth the velocity signal over time. The equation is rather simple and the filter successfully blocks high-frequency signals. The filters performance can be configured by the variable stiffness \(s\) which represents the filter sample window (e.g. 1, 2, 4, 8, 16, 32 or 64 samples). The current filter value \(f_n\) thus depends on previous filter value \(f_{n-1}\), current and last raw values \(v_n\) and \(v_{n-1}\), respectively.

$$\begin{eqnarray} f_n &=& \frac{s}{2} \cdot (v_{n-1} + v_n) + (1-s) \cdot f_{n-1} \end{eqnarray}$$

*Raw (red) and filtered (black) x-velocity with stiffness=1 and stiffness=4.*

*Raw (red) and filtered (black) x-velocity with stiffness=16 and stiffness=64.*