Next  |  Prev  |  Up  |  Top  |  REALSIMPLE Top

Pick-Position Comb Filter

A natural model of string excitation is an input signal summed into a virtual physical location along the length of a digital waveguide string model, as described in [14]. This model can then be factored into a pick-position comb filter in series with a filtered delay loop, as used in the EKS [4,11] and derived in [14].

The EKS pick-position comb filter has the transfer function

H_\beta(z) \;=\;1 - z^{-\lfloor\beta P\rfloor}

where $P$ is the period (total loop delay) in samples, and $\beta\in(0,1)$ denotes normalized position along the string ($0$ being at the ``bridge'' and $1$ being at the ``nut''). The notation $\lfloor x\rfloor$ means the ``greatest integer less than or equal to $x$,'' also called truncation to the next lower integer.8 This transfer-function model of pick position is easily derived by simply factoring the transfer-function of the string from the picking point to any other point along the string, such as the bridge point [14,11].

In Faust, a feedforward comb filter is readily implemented using the delay function defined in music.lib:

  ppdel = beta*P; // pick position as fraction of period
  pickpos = _ <: delay(Pmax,ppdel) : - ;
where Pmax is some power of 2 larger than ppdel (see the definition of delay in music.lib to understand why a power of 2). In Faust, we can bring out a ``continuous'' pick-position control spanning half the string as follows:
  beta = hslider("pick_position", 0.13, 0, 0.5, 0.01); // 0-1/2
The block diagram generated by ``faust -svg -simple-names'' is shown in Fig.5. Pick position accuracy is normally not critical, hence the 1% slider steps and lack of delay-line interpolation in the comb filter.

Figure 5: Faust-generated block diagram of the pick-position comb filter.
\scalebox{0.8}{\includegraphics{\figdir /pickpos.eps}}

Next  |  Prev  |  Up  |  Top  |  REALSIMPLE Top

Download faust_strings.pdf

``Making Virtual Electric Guitars and Associated Effects Using Faust'', by Julius O. Smith III,
REALSIMPLE Project — work supported in part by the Wallenberg Global Learning Network .
Released 2013-08-22 under the Creative Commons License (Attribution 2.5), by Julius O. Smith III
Center for Computer Research in Music and Acoustics (CCRMA),   Stanford University