Conference PaperPDF Available



Abstract and Figures

Physical circuit models have an inherent ability to simulate the behaviour of user controls as exhibited by, for example, potentiometers. Working to accurately model the user interface of musical circuits, this work provides potentiometer 'laws' that fit to the underlying characteristics of linear and logarithmic potentiometers. A strategy of identifying these characteristics is presented, exclusively using input/output measurements and as such avoiding device disassembly. By breaking down the identification problem into one dimensional, search spaces characteristics are successfully identified. The proposed strategy is exemplified through a case study on the tone stack of the Big Muff Pi.
Content may be subject to copyright.
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
Ben Holmes and Maarten van Walstijn
Sonic Arts Research Centre,
School of Electronics, Electrical Engineering, and Computer Science,
Queen’s University Belfast,
Belfast, UK
{, }
Physical circuit models have an inherent ability to simulate the be-
haviour of user controls as exhibited by, for example, potentiome-
ters. Working to accurately model the user interface of musical
circuits, this work provides potentiometer ‘laws’ that fit to the un-
derlying characteristics of linear and logarithmic potentiometers.
A strategy of identifying these characteristics is presented, exclu-
sively using input/output measurements and as such avoiding de-
vice disassembly. By breaking down the identification problem
into one dimensional, search spaces characteristics are success-
fully identified. The proposed strategy is exemplified through a
case study on the tone stack of the Big Muff Pi.
Virtual Analogue (VA) modelling is largely motivated by the her-
itage aim of recreating analogue effects in functional digital form.
A core component of an analogue effect is its user interface, i.e.
the controls available to the musician to design and fine-tune the
timbral qualities of the effect. To create a complete VA model of a
device, its user interface must therefore also be carefully recreated.
A ubiquitous element of the user interface is found in poten-
tiometers, which are present in countless guitar effects, synthesis-
ers, etc. These devices map a change in rotation (or other move-
ment) to a change in a specified phenomenon. Often, available
schematics omit potentiometer laws, requiring a method of deter-
mining them from the circuit. Further, ideal laws that are com-
monly used may not truly reflect the behaviour of real potentiome-
The aim of this paper is to investigate, identify, and model
such mappings with a view of incorporating the resulting poten-
tiometer laws into VA circuit models. Physical modelling is a good
match for the overall simulation in this case, as it preserves the cir-
cuit topology, meaning that potentiometer changes result in local
rather than global system changes. This does not hold for black-
and grey-box models [1, 2], which focus on deriving a model for
a single setting. A solution would require interpolation across a
large number of coefficient data sets to facilitate such potentiome-
ter control, equivalent to the strategy used to model a systems’
response to changes in input signal amplitude [3].
The main advantage of black box models is that they are de-
rived entirely from input/output (I/O) measurements, preventing
the need to disassemble a device and so avoiding any risk of dam-
age to the device under test. Previously it was found that for phys-
ical models, values of the components in a circuit can be identified
using only I/O measurements and positioning potentiometers at the
extreme ends of their travel [4]. The objective of this work is to
2: Wiper
yRT(1 y)RT
Figure 1: (a) Annotated potentiometer schematic symbol. (b) Sep-
aration of the potentiometer symbol into the inter-terminal resis-
tances as used to model its behaviour. (c) Rotary potentiometer di-
agram with labelled terminals, and the rotating shaft highlighted
and range of rotation indicated, the shaft shown at 0 .
complete a VA circuit model by identifying the underlying char-
acteristic of a potentiometer, again only using I/O measurements.
A key aspect of this challenge is to determine suitable fitting func-
The rest of this paper is organised as follows: §2 investigates a
variety of potentiometer laws and fits them to characteristics both
from literature and also measurements of individual devices. §3
presents the identification strategy used to estimate potentiometer
characterstics from I/O measurements, utilising the Big Muff Pi
tone stack as a case study. §4 then presents the results of the char-
acteristic identification from real I/O measurements, and finally §5
concludes the research and notes lines of future research. Compan-
ion material including MATLAB code and data sets are available
Potentiometers are a common component in musical circuits, used
to provide a direct user interface. Some of the most common
applications are for ‘volume’, ‘tone’, ‘gain’, etc. Illustrated in
Figure 1, the potentiometer implements control over such quan-
tities/phenomena by changing two resistances between three ter-
minals relative to the position of its wiper which is actuated by the
The focus of this work is on how those resistances change with
respect to a change in position of the wiper, referred to as its ‘law’.
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
0 0.2 0.4 0.6 0.8 1
1Linear Log ALog
Figure 2: Linear, logarithmic, and anti-logarithmic potentiometer
tapers, dB = 40 dB.
This law effectively maps the user’s control to a change in the be-
haviour of the circuit, and is an essential feature of the user inter-
face. Within the field of audio the most commonly encountered
laws are linear and logarithmic, and will be the focus of the pre-
sented modelling and identification. Out of these two, it could be
said that the logarithmic law is the most widely used, applied to
map a linear control to logarithmic quantities such as loudness and
frequency for application to volume controls and filter circuits.
2.1. Ideal laws
This section addresses ‘ideal’ potentiometer laws that are suitable
for musical expression, but may not correspond exactly with how
a physical potentiometer behaves electronically. An ideal poten-
tiometer law is defined having a maximum total resistance RT
which is the sum of resistance between terminals 1 and 3 as il-
lustrated in Figure 1. Each terminal and wiper are assumed to
be perfect conductors i.e. have no resistance. Wiper position is
defined here by the variable xwhich notes the rotation between
terminals, and can be normalised such that 0x1which
maps to a degree of total rotation usually between 0 and 300 de-
grees. The potentiometer law is defined as a function of the ro-
tation, y=f(x)which dictates the proportion of RTthat each
resistor represents: R1,2=yRTand R2,3= (1 y)RT, where
subscript indicates terminal index. To reverse the orientation of
the potentiometer the resistors change position between terminals,
modelled as y= 1 f(x).
Ideal laws are shown in Figure 2, including an antilogarithmic
law in addition to the previously mentioned linear and logarithmic
laws. An ideal linear law can be defined as flin(x) = x. A deci-
bel ranged logarithmic function can be found by placing xin the
flog(x) = 10
20 (x1),(1)
where dB is the desired range in decibels. This effectively maps
linear rotation to a logarithmic law, a mapping which is used in
other contexts for example in envelope design [5]. This law never
reaches 0, which corresponds to inf dB. Should a zero-value be
desired the law can be translated and scaled, though it would then
no longer be truly logarithmic.
The exponent operation can be computationally expensive de-
pending on the system, and often approximations are offered such
as a power law, e.g. f(x) = x4in [5]. Modern audio plug-in
frameworks typically offer a variety of options to suit the needs of
the developer [6].
An anti-logarithmic law is found by reflecting the logarithmic
curve around x= 0.5and y= 0.5, i.e. fAlog(x) = ˆ
f(x) = 1 f(1 x).
2.2. Laws from specifications
Though the ideal laws discussed in §2.1 may provide suitable con-
trol in software, these laws are unlikely to be encountered in real
devices. In this section specifications are first investigated from
a modelling perspective to determine which functions are suitable
for capturing the behaviour of a real potentiometer law. Two func-
tions are proposed to model the characteristics encountered in real
devices, a tanh based function for broadly capturing multiple laws
with a single function, and a piecewise function that aims to match
the manufactured composition of the studied devices. The piece-
wise functions are then used to model measurements from real po-
tentiometers that will then be used in the case study of the Big
Muff Pi tone stack in §3.
To utilise data of potentiometer mapping characteristics shown
in figures in the literature, online software for extracting data from
images was used [7].
2.2.1. An analytic multi-law function
An authoritative source on potentiometers, ‘The Potentiometer
Handbook’ [8] provides a reference for commonly occurring laws
as well as the underlying manufacturing techniques behind them.
The text refers to the Military Specification MIL-R-94B (now at
revision G though characteristics are unaltered [9]), reproduced
here in Figure 3. Each of these characteristics deviates from the
ideal law, shown with gentle transitions towards the extreme ends
of the functions. For the laws shown in Figure 3, a suitable non-
piecewise function is found in tanh(), parameterised with 4 free
ftanh(x) = t1tanh(t2x+t3) + t4.(2)
By introducing lower and higher limits on the potentiometer func-
tion yland yh, this function can be constrained by requiring
ftanh(0) = yland ftanh (1) = yhresulting in
t4=ylt1tanh(t3), t1=yh
leaving free parameters t2and t3. For a full-range law yl= 0
and yh= 1, though due to inherent terminal and wiper resistances
these values will never be found from measurements of a real de-
The solid lines in Figure 3 show the fit of the tanh law to
those from [8]. The tanh function with 2 free parameters in (2 -
3) were fit using the fit function from MATLAB 2018a’s Curve
Fitting toolbox, with initial parameters t2= 1 and t3=0.5. For
the anti-log characteristic the function was defined as fAlog
tanh (x) =
ftanh(x). The resultant function coefficients are shown in Table 1.
A maximum error of 4% is found in Figure 3 between the
specified characteristic and fitted function for the logarithmic law,
though most error falls between ±2%. The larger error observed in
the log law can be attributed to it reaching the ylimits prior to the
corresponding xlimits. To mitigate this error, a piecewise function
could be employed with the tanh function only fitting the central
region, and transitioning to a different sub-function in the regions
where the most error is encountered. This would however reduce
the simplicity of the implementation, and other sub-functions may
offer improved fit to real potentiometer device laws. The tanh
function maintains applicability without additional sub-functions,
offering a single function that can model each of the examined
characteristics and providing this flexibility with only 2 parame-
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
0 0.2 0.4 0.6 0.8 1
Error (%)
Linear Log Anti-Log
Figure 3: Specified linear, logarithmic, and anti-logarithmic po-
tentiometer tapers. The specified characteristic is marked by 5,
and the fit using a tanh function by the solid lines. Error is shown
in the lower plot.
Table 1: Fit parameters of the general tanh function to the po-
tentiometer laws specified in [8]. Limits are given as yl= 0 and
yh= 1.
tLinear Log ALog
t10.701 0.566 0.536
t21.790 4.400 5.113
t30.919 3.380 3.787
t40.508 0.564 0.535
2.2.2. Piecewise linear/cubic functions
The specific potentiometers investigated within this work are of
the brand Alpha, a popular brand in the building of guitar effects-
pedals. Specifications for the potentiometer laws are found on
their website [10]. Again the tanh function could be employed
to model both linear and logarithmic laws for these specifications,
however after an initial study the error peaked at 8% at the same re-
gion as observed in Figure 3, though a figure of this result is omit-
ted for brevity. To reduce this error a piece-wise function would
need to be used to capture the end-regions where the function gra-
dient is zero. In the case that a piecewise function is required, it is
a logical step to test which functions can provide the optimal fit.
The logarithmic characteristics from [10] are reproduced in
Figure 4. Each law is specified by the percentage of total resis-
tance between terminals 1 and 2 at 50 % rotation. Upon inspection
of this set of characteristics there appear distinct sections with con-
stant gradients, joined via smooth transitions. This property can be
exploited through the use of a piecewise function containing linear
sub-functions. Defining a linear sub-function with local lower and
higher limits – yll =¯
flin(xll )and ylh =¯
flin(xlh )– results in the
flin(x) = ylh yll
xlh xll
(xxll) + yll ,¯
lin(x) = ylh yll
xlh xll
The derivative of the linear sub-function is important here as there
are no apparent jumps in gradient in any of the characteristics, and
so the gradient of the sub-functions must match at the transitional
values of the piecewise function. To achieve a match in derivatives
at transitional points, 4 free parameters would be required, two for
each transitional point, matching value and derivative. One such
sub-function that offers this is found in a general cubic polynomial,
expressed as
fcub(x) = c4x3+c3x2+c2x+c1,(5)
where c1c4are the cubic coefficients used to fit the sub-function
fcub(x). To find values for c1c4the following set of equations
must be solved,
fcub(xll ) = c4x3
ll +c3x2
ll +c2xll +c1,(6)
fcub(xlh ) = c4x3
lh +c3x2
lh +c2xlh +c1,(7)
cub(xll ) = 3c4x2
ll + 2c3xll +c2,(8)
cub(xlh ) = 3c4x2
lh + 2c3xlh +c2.(9)
An explicit solution of this set of equations is available on the sup-
porting online content, but is omitted here for brevity.
The choice of the linear-cubic piecewise function aims to build-
in the specified behaviour of the manufacturer’s characteristics. By
matching the underlying structure of potentiometer characteristics,
the ability to produce an accurate law from a reduced/incomplete
set of measurements is improved, without needing a higher num-
ber of measurements to interpolate between.
From the specified or measured potentiometer characteristics a
set of xvalues can be found at which the function transitions from
linear to cubic (either through direct visual inspection or inspection
of the gradient of the law). At these points the corresponding y
values can be found by interpolating between the available data
points of the characteristic, yielding a set of points that make up
the piecewise function transitions.
In Figure 4, logarithmic characteristics from [10] are shown
with their piecewise fit. The transitional points are approximately
equal between each function, meaning that only one set of xvalues
was required to fit the full set of characteristics. These values of
xand the corresponding yvalues are shown in Table 2 where they
are marked with their respective sub-function. A total of 7 piece-
wise sections were needed to match the characteristic specified by
the manufacturer. The solid line in Figure 4 shows the fit of the
piecewise function to the specification, the error between the two
shown in the plot beneath. A peak error of 2% is found for the
15A law, with most error for each law falling within ±1%.
Figure 5 shows the characteristics as given for ‘linear’ laws
from [10]. A similar level of accuracy can be achieved using only
5 piecewise sections as opposed to the 7 used for the logarithmic
characteristics. The piecewise transitional points for each of these
laws varies significantly, necessitating an individual search for the
characteristic xvalues at which the transitions occur, found using
an optimisation algorithm.
From MATLAB’s Optimisation toolbox the Nelder-Mead al-
gorithm was selected for an easy-to-implement, derivative-free al-
gorithm to minimise the error of the function to the characteristic
by changing transitional values of x[11]. Four xvariables were
gathered into θxto use as parameters, excluding those at 0 and 1.
The corresponding estimated values of ˆ
f(x, θx)were then found
through interpolating between the available values of y, and a com-
plete piecewise function was assembled. The employed objective
ξx(θx) = 1
f(xn,θx)2, η =
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
0 0.2 0.4 0.6 0.8 1
Error (%)
Figure 4: Logarithmic Alpha characteristics (5marks), and fit us-
ing linear-cubic piecewise functions (solid lines). Characteristics
are noted by the manufacturer’s code which refer to the resistance
percentage at 50% rotation. Error is shown in the lower plot. Ver-
tical dashed lines mark the points at which the piecewise function
sections change.
enumerates the sum-squared error between the measured points of
f(xn) = ynand those found using the piecewise function with
estimated transitional points ˆ
f(xn,θx). A normalisation factor η
is applied to ensure that between data sets with different numbers
of elements, the enumerated error would be comparable, allowing
comparison between the results of the optimisation using different
data sets.
Constraints are applied directly to the objective function, re-
turning ξx= 103if the constraints are not satisfied. These con-
straints prevent xvalues from exceeding domain limitations, i.e.
0θx1, and that they are incremental in value, i.e. for the jth
element θj
x< θj+1
Convergence tolerances were set at a change in value beneath
108for both θxand ξx(θx). The resulting optimised xand cor-
responding yvalues are omitted here for brevity but can be found
on the companion webpage. The solid line in Figure 5 represents
the fitted piecewise function for each law, with the error between
fit and specification shown in the lower plot. Peak error is approx-
imately 1.2% with most contained within ±1%.
With suitable functions that match the specified potentiometer
laws to within 2% error, the following step is to apply this function
to model the characteristic of real potentiometer devices.
2.3. Measured potentiometer characteristic
Several potentiometers were purchased from a local distributor of
components for the DIY construction of guitar effects pedals. This
source was selected to ensure that the potentiometers would be
intended for the use in guitar effects pedals, and that they could
be used to determined which laws from the presented sets in Fig-
ures 4 and 5 are used in potentiometers popular among effects-
builders. The purchased potentiometers were specified to have
RT= 100 kΩ (±20%) as this is the value of the potentiometer
used in the Big Muff Pi tone stack, further discussed in §3.
0 0.2 0.4 0.6 0.8 1
Error (%)
Figure 5: Linear Alpha characteristics from (5marks), and fit us-
ing linear-cubic piecewise functions (solid lines). Characteristics
are noted by the manufacturer’s code. Error is shown in the lower
plot. Transitions are omitted for this figure as they each fall at
different values.
Table 2: Optimised transition points of the general cubic-linear
piecewise function, fit to the logarithmic potentiometer character-
istic specified in [10]. Values are rounded to 3 decimal places.
‘Law’ column is offset to indicate which law corresponds to each
set of end-points.
Law x y
05A 10A 15A 20A 25KA 30A
Lin. 0.000 0.000 0.000 0.000 0.000 0.000 0.000
Cub. 0.050 0.003 0.003 0.003 0.004 0.002 0.004
Lin. 0.300 0.015 0.028 0.063 0.084 0.123 0.151
Cub. 0.510 0.057 0.111 0.162 0.210 0.259 0.311
Lin. 0.700 0.284 0.363 0.410 0.443 0.501 0.542
Cub. 0.920 0.954 0.959 0.958 0.952 0.954 0.965
Lin. 0.970 0.999 0.999 1.000 1.000 0.999 1.000
1.000 1.000 1.000 1.000 1.000 1.000 1.000
To measure the potentiometer characteristic, a measurement
jig was designed with markers at 15 degree angles around a cen-
tral hole where the potentiometer was fixed. The markers were
placed using computer aided design/manufacturing, the jig made
from FR-4 with plated copper as used in circuit-board manufactur-
ing techniques.
Direct measurements presented here are only cursory to pro-
vide an approximate law with which to compare to those found
through the following identification from I/O measurements. The
potentiometer was rotated by hand to line the knob indicator to
each marker, while the resistance between adjacent terminals was
measured continuously with an LCR meter. Measuring the resis-
tance at 15 degree increments over a total of 300 degrees of travel
yielded 21 measurements. The obtained characteristics can be con-
sidered as suitably representative test data even in the presence
of possible measurement errors, including human error when per-
forming the manual wiper rotation and heating from continuous
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
0 0.2 0.4 0.6 0.8 1
Error (%)
Figure 6: Measured (5marks) and fit linear-cubic (solid lines)
potentiometer laws of 1 linear and 1 logarithmic potentiometer.
Error is shown in the lower plot. The laws of the two potentiome-
ters fit with that of ‘B’ from Figure 5 and ‘15A’ from Figure 4.
Table 3: Optimised transition points of the general cubic-linear
piecewise function, fit to measurements taken of a linear and log-
arithmic potentiometer. Values are rounded to 3 decimal places.
‘Law’ column is offset to indicate which law corresponds to each
set of end-points.
Linear Log
Law x y x y
Lin. 0.000 0.000 0.000 0.000
Cub. 0.050 0.000 0.071 0.005
Lin. 0.093 0.041 0.239 0.045
Cub. 0.951 1.000 0.603 0.215
Lin. 0.951 1.000 0.659 0.368
Cub. 1.000 1.000 0.850 0.939
Lin. - - 0.908 0.997
- - 1.000 1.000
driving from the LCR meter. Other physical parameters exist for
the potentiometer in addition to its law, such as terminal resistance,
but these were found to be of a magnitude that was impossible to
measure with available equipment, and therefore likely insignifi-
cant to the identification.
Figure 6 shows the measured characteristics of both a lin-
ear and a logarithmic potentiometer, and the fit of the piecewise
linear-cubic function to the measurements. A notable deviation
was found from the logarithmic tapers of Figure 4, with the tran-
sition to the zero-gradient section at the maximum of the function
occurring at a lower value of x. Therefore the optimisation ap-
proach used to fit the linear characteristics of Figure 5 was applied,
i.e. the xpositions found by optimising them and finding the cor-
responding values of ythrough interpolation of the measurement.
The result is a good fit to the measurements with a peak error just
over 1%. Final transitional values of the piecewise function are
shown in Table 3.
Having fit laws to characteristics obtained from both linear and
logarithmic potentiometers, sufficient information is available to
validate results from the law identification strategy exclusively us-
ing input/output measurements, presented in this section. The case
study chosen to demonstrate this strategy is the tone stack from
the Big Muff Pi, informed from the description in [12], with the
schematic shown in Figure 7. In simple terms, the potentiometer
in the Big Muff Pi tone stack blends between a low pass formed
between R1and C2, and a high pass filter formed by C1and R2.
Both linear and logarithmic potentiometers will be used to demon-
strate the capability of the identification strategy to succeed inde-
pendent of potentiometer law.
The tone stack was assembled on a breadboard to enable di-
rect measurement of each component prior to the measurement
of the circuit’s transfer function. Use of a breadboard also facili-
tates the measuring of both linear and logarithmic potentiometers
to demonstrate the identification procedure for the two most com-
mon laws. Specified and directly measured component values can
be found in Table 4.
Only one potentiometer is present in the circuit. The presented
method should allow for independent identification of multiple po-
tentiometers by setting all but the potentiometer of interest at a
known position, at 0 or 300 degrees rotation, resulting in N×M
independent identifications where Nis the number of positions per
potentiometer and Mthe number of potentiometers. This prop-
erty cannot be demonstrated using this circuit, but can be inferred
as only one variable, a single potentiometer position, would be
changed in between each measurement.
To begin identifying the potentiometer laws from input/output
measurements, one must start with estimates of the component
values, obtained from schematics or other identification strategies.
Should the component values be highly accurate, the input/output
measurements should theoretically be matched when the poten-
tiometer is at either extreme of its rotational travel. At these points
the values of yare assumed known. The accuracy of the fit achieved
at these limits will provide some indication of how accurately the
law can be retrieved.
The selection of a linear case study provides several desirable
traits: the circuit model can be represented using a transfer func-
tion which requires only a few data points to capture a large fre-
quency range, and issues of nonlinear behaviour such as aliasing
are avoided. The tone stack is modelled as a transfer function de-
rived using Modified Nodal Analysis [13]. The resultant function
is of the form
H() = b3()3+b2()2+b1j ω
a4()4+a3()3+a2(j ω)2+a1(jω)1+a0
Complete coefficients are omitted due to their complexity, but MAT-
LAB code for calculating the transfer function is available on the
companion webpage. Figure 8 shows the simulated amplitude re-
sponses of the Big Muff Pi’s tone stack with the potentiometer at
each end of its travel: presuming these responses to be accurate
the challenge then lies in measuring intermediate responses and
identifying the corresponding values of f(x).
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
Table 4: Component values of the Big Muff Pi tone stack: specified
values and the values directly measured from the circuit using an
LCR meter.
Unit Specified Measured
R1kΩ 39.000 39.080
R2kΩ 22.000 21.950
RTkΩ 100.000 94.940 (lin) / 98.140 (log)
RokΩ 100.000 99.978
C1nF 4.700 4.698
C2nF 10.000 9.470
C3nF 100.000 98.010
CdpF 100.000 33.227
(1 y)RT
Figure 7: Schematic of the Big Muff Pi tone stack with potentiome-
ter marked by red line. Cdis the input capacitance of the mea-
surement equipment used.
3.1. Identification strategy
The identification strategy proposed in this work identifies a po-
tentiometer’s characteristic from input/output measurements of a
circuit. A series of optimisations are performed, only operating
on a single value of xat a time. Values of y=f(x)are es-
timated at each point, thus identifying the potentiometer charac-
teristic. To perform such optimisations, an objective function is
required which compares the measurements of the circuit to the
equivalent data from the model, enumerating the error between
circuit and model.
Considering the linear case exhibited by the Big Muff Pi tone
stack, the input/output measurements can be condensed into the
form of a transfer function. Due to the limitations of the measure-
ment equipment (further discussed in Section 3.2) only the ampli-
tude response of the transfer function is used, with phase informa-
tion discarded. From this information the objective function was
constructed, for an estimated value of y=f(x),
ξio(y) = 1
n=0 |H(n)|2
|H(n)| − | ˆ
H(n, y )|2,
where the operator |· | indicates the magnitude of a complex value.
Frequencies of the transfer function are specified using ωn, where
nindicates index of the discrete frequency selected to be included
Figure 8: Amplitude responses of the Big Muff Pi tone stack with
the potentiometer at extreme ends of its rotational travel.
in the measurement data.
The optimisation algorithm chosen to minimise the value of
ξio(y)was that of fminsearch from MATLAB’s optimisation
toolbox, specifically the Nelder-Mead simplex algorithm. Conver-
gence conditions were again set to be a change in yor ξio less
than 1×108. Initial experiments using simulated I/O measure-
ments demonstrated successful identification of the potentiometer
characteristics to within 105%of the accurate value.
3.2. Measurement procedure
Among various possible valid measurement approaches to find the
transfer function of the Big Muff Pi tone stack, a multi-sine exci-
tation signal was chosen, expressed as
Adcos(2πdf0nT +φd), n = 0,...,Ns.(13)
The integer values of dare limited to contain sinusoidal compo-
nents at multiples of f0=fs/Nsbetween the lower and upper
limits dland du. Phase terms φdare specified as in [14], i.e.
(dl)Ad, d =dl, dl+ 1, ..., du.(14)
which requires that 1 = Pdu
d=dlAd. Individual amplitude com-
ponents allow a frequency-domain weighting to be applied which
can be used to maximise the signal-to-noise ratio, but in this case
were set to be Ad= 1/(dudl).
Finally the value of Vpis selected such that the peak voltage of
the resultant signal is normalised to a chosen peak voltage typically
as defined by the measurement equipment.
To produce a transfer function from the measured output of
the circuit, the input is deconvolved from the output signal by per-
forming an element-wise division in the frequency domain.
An excitation signal was designed with frequencies between
1 Hz 20.1 kHz, i.e. f0= 1,dl= 1 and dh= 20100. The
measured frequency range was measured outside of the anticipated
required range in case this information was important to the identi-
fication, though the range is later restricted to 20 Hz 20 kHz. The
limitations of the analogue input was 2 V which was used to find
the value of Vp. The signal was repeated 60 times and averaged to
one period to reduce stochastic noise.
The measurement equipment used is a National Instruments
myDAQ. Previous experiments with Data Acquisition devices and
identification have shown that any errors in the phase response can
severely effect accuracy in the identification procedure [4]. Upon
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
0 0.2 0.4 0.6 0.8 1
Error (%)
Figure 9: Potentiometer laws as directly measured (solid line) and
estimated from I/O measurements (5marks), and error between
the two sets presented beneath.
detection of phase error by testing the unloaded I/O response, it
was decided that the phase response should be omitted from the
identification data.
A notable capacitance was measured across the input to the
myDAQ, noted as Cdin Table 4. This capacitance was included
in the circuit model to incorporate any effect it may have on the
measured transfer functions. The measured value of Cdwas found
by driving a series impedance of 2 MΩ with a multi-sine signal,
and measuring the cutoff frequency of resulting RC low pass filter
at approximately 2.395 kHz.
Measurements were taken from 21 positions along the rota-
tional axis of both the linear and logarithmic potentiometers (15
degree rotations from 0-300 degrees). The amplitude response of
each of the measured transfer functions was then used to estimate
the value of yat each position. To minimise computational ex-
pense during optimisation, the transfer function data was down-
sampled from 20.1×103data points to 512 points spaced loga-
rithmically between 20 Hz and 20 kHz, each point rounded to the
nearest integer such that it corresponds to a measured value, not re-
quiring interpolation. Removing duplicate entries that occur at low
frequencies results in a unique set of 469 amplitudes/frequencies.
Optimisation was applied as described in Section 3.1, using the
Nelder-Mead algorithm and the objective function described in
(12). Convergence was achieved successfully from each optimi-
The identified potentiometer laws for both linear and logarith-
mic potentiometers are shown in Figure 9, with the solid line rep-
resenting the directly measured law and the 5marking the values
estimated using the identification strategy. Error between the sets
peak at approximately 4.5 % for the logarithmic characteristic and
3 % for the linear characteristic.
Illustrated for both potentiometer laws in Figure 10 are the
measured and identified amplitude responses of the Big Muff Pi
tone stack. This serves to provide one way of attributing error but
also as a source of validation. Inspecting the xvalues of high er-
ror in Figure 9 it is clear that there is not an anomalous amount of
error in the fit to the amplitude response at corresponding values.
Consistent accuracy from identified amplitude responses but in-
creasing error in the identified potentiometer characteristic points
towards the error being introduced by device heating/human error
during measurement.
As a form of validation, the fit to measurements demonstrated
in Figure 10 is accurate to within 1 dB across all measurements,
indicating that the tone stack filtering effect is captured over the
the full wiper range.
This work has focused on the modelling and identification of po-
tentiometer laws without device disassembly. Two functions were
proposed to model potentiometer characteristics as found in spec-
ifications and from measurements, a tanh() based function and a
piecewise linear-cubic function. The latter was used to model the
laws of Alpha potentiometers as given by both specifications and
measurements within 2% error.
Identification of the potentiometer characteristics from I/O mea-
surements of the device was tested on a linear subcircuit of the Big
Muff Pi: the tone stack. Identification exclusively using the ampli-
tude response of the subcircuit was shown to be possible, with the
results of the identification retrieving both linear and logarithmic
potentiometer characteristics to within 4.5% error.
It is likely that some of this 4.5% error has been introduced
by device heating and/or human error. Increasing the precision
and repeatability of the measurements could be achieved by the
design of an automated mechatronic system that would simultane-
ously rotate the potentiometer wiper and perform measurements.
One such solution might involve e.g. a stepper motor to control
the potentiometer and a pulsed measurement system to control the
variation in resistance caused by changes in temperature.
For those seeking a fast method of determining the orienta-
tion and approximate law of a potentiometer, a complete set of
21 points is not required. Assuming f(0) and f(1) are known,
from e.g. parameter estimation as in [4], only one additional mea-
surement at f(0.5) is sufficient to differentiate between linear and
logarithmic/anti-logarithmic. A further measurement at e.g. f(0.25)
or f(0.75) would then enable differentiation between orientations
of the potentiometer and also logarithmic and anti-logarithmic laws.
The anticipated application of this identification strategy is for
complete, nonlinear audio circuits. Elements that may cause is-
sues in the identification include nonlinear behaviour, and effects
for which potentiometers control behaviour that is difficult to mea-
sure, e.g. LFO rate in a phasor effect. The low-data point ampli-
tude response facilitates fast identification, which has significant
benefits with regard to rapid design and refinement of the identifi-
cation process. Time-based and/or nonlinear effects would prevent
this selection and therefore demand a search for a suitable, simi-
larly efficient, objective function. For example, a gain control may
use the Total Harmonic Distortion of the output waveform when
driven by a sinusoid, or for a delay length control, the time be-
tween repeats when driven by a pulse-type signal. Each control
type requires individual attention, but due to the monotonic nature
of the studied potentiometer laws, and as each potentiometer can
be identified independently, each position should yield a unique
measured value, so long as the objective function is well-chosen.
Proceedings of the 22nd International Conference on Digital Audio Effects (DAFx-19), Birmingham, UK, September 2–6, 2019
Amplitude (dB)
Linear law
20 200 2k 20k
Frequency (Hz)
Error (dB)
Log law
20 200 2k 20k
Frequency (Hz)
Figure 10: Estimated (dotted) and measured (solid) amplitude responses of the Big Muff tone stack, with error in decibels shown below.
Only 11 of the 21 measured amplitude responses are shown to improve clarity of the figure.
[1] Felix Eichas and Udo Zölzer, “Gray-Box Modeling of Guitar
Amplifiers,” Journal of the Audio Engineering Society, vol.
66, no. 12, pp. 1006–1015, Dec. 2018.
[2] Antonin Novak, Pierrick Lotton, and Laurent Simon, “Syn-
chronized Swept-Sine: Theory, Application, and Implemen-
tation,” Journal of the Audio Engineering Society, vol. 63,
no. 10, pp. 786–798, Nov. 2015.
[3] Lamberto Tronchin and Vanna Lisa Coli, “Further Investi-
gations in the Emulation of Nonlinear Systems with Volterra
Series,” Journal of the Audio Engineering Society, vol. 63,
no. 9, pp. 671–683, Oct. 2015.
[4] Ben Holmes, Guitar Effects-Pedal Emulation and Identifica-
tion, Ph.D. thesis, Queen’s University Belfast, June 2019.
[5] Miller Puckette, The Theory and Technique of Electronic
Music, World Scientific Publishing Co. Pte. Ltd., 2007.
[6] Oliver Larkin, Alex Harker, and Jari Kleimola, “iPlug 2:
Desktop Plug-in Framework Meets Web Audio Modules,” in
Proceedings of the 4th Web Audio Conference, Sept. 2018.
[7] Ankit Rohatgi, “WebPlotDigitizer,, Apr. 2019.
[8] Carl David Todd, The Potentiometer Handbook: Users’
Guide to Cost-Effective Applications, McGraw-Hill, New
York, 1975.
[9] U.S.A. Department of Defense, “Military specification MIL-
PRF-94G: Resistors, variable, composition general specifi-
cation for, Tech. Rep., Aug. 2011.
[10] Alpha Products, “Taper Curves for our Potentiometers,,
[11] Jeffrey C. Lagarias, James A. Reeds, Margaret H. Wright,
and Paul E. Wright, “Convergence properties of the
Nelder–Mead simplex method in low dimensions, SIAM
Journal on Optimization, vol. 9, no. 1, pp. 112–147, 1998.
[12] Electrosmash, “Big Muff Pi Analysis,
[13] Chung-Wen Ho, Albert E. Ruehli, and Pierce A. Brennan,
“The Modified Nodal Approach to Network Analysis,” IEEE
Transactions on Circuits and Systems, vol. 22, no. 6, pp.
504–509, 1975.
[14] Manfred Schroeder, “Synthesis of low-peak-factor signals
and binary sequences with low autocorrelation (Corresp.),
Information Theory, IEEE transactions on, vol. 16, no. 1, pp.
85–89, 1970.
Full-text available
The emulation of nonlinearities of audio devices can be achieved by means of a nonlinear convolution method, which is based on a particular case of the Volterra series, called the Diagonal Volterra series. The Volterra kernels characterize the nonlinear audio device being tested, dependent upon the level of the signal that passes through the device. In this paper, a method is presented that approximates Volterra kernels in a "continuous" range of levels by means of an interpolation procedure of an achieved number of measurements. In order to obtain the best emulation for real signals, several parameters were tested. An extension of the previous Diagonal Volterra model is also developed to an arbitrary order of nonlinearities in order to allow better emulation of harmonics of low and medium frequencies; a particular case for the experiments is presented.
Full-text available
This is the first book to develop both the theory and the practice of synthesizing musical sounds using computers. Each chapter starts with a theoretical description of one technique or problem area and ends with a series of working examples (over 100 in all), covering a wide range of applications. A unifying approach is taken throughout; chapter two, for example, treats both sampling and wavetable synthesis as special cases of one underlying technique. Although the theory is presented quantitatively, the mathematics used goes no further than trigonometry and complex numbers. The examples and supported software - along with a machine-readable version of the text - are available on the web and maintained by a large online community. The Theory and Techniques of Electronic Music is valuable both as a textbook and as professional reading for electronic musicians and computer music researchers. © 2007 by World Scientific Publishing Co. Pte. Ltd. All rights reserved.
Full-text available
The Nelder{Mead simplex algorithm, rst published in 1965, is an enormously pop- ular direct search method,for multidimensional unconstrained minimization. Despite its widespread use, essentially no theoretical results have been proved explicitly for the Nelder{Mead algorithm. This paper presents convergence properties of the Nelder{Mead algorithm applied to strictly convex functions in dimensions 1 and 2. We prove convergence to a minimizer for dimension 1, and various limited convergence results for dimension 2. A counterexample of McKinnon gives a family of strictly convex functions in two dimensions and a set of initial conditions for which the Nelder{Mead algo- rithm converges to a nonminimizer. It is not yet known,whether the Nelder{Mead method,can be proved to converge to a minimizer for a more specialized class of convex functions in two dimensions. Key words. direct search methods, Nelder{Mead simplex methods, nonderivative optimization AMS subject classications. 49D30, 65K05 PII. S1052623496303470
Full-text available
The nodal method has been widely used for formulating circuit equations in computer-aided network analysis and design programs. However, several limitations exist in this method including the inability to process voltage sources and current-dependent circuit elements in a simple and efficient manner. A modified nodal analysis (MNA) method is proposed here which retains the simplicity and other advantages of nodal analysis while removing its limitations. A simple and effective pivoting scheme is also given. Numerical examples are used to compare the MNA method with the tableau method. Favorable results are observed for the MNA method in terms of the dimension, number of nonzeros, and fill-ins for comparable circuit matrices.
In this work analog guitar amplifiers are modeled with an automated procedure using input/output measurements and iterative optimization. The digital model is an extended Wiener-Hammerstein model consisting of a linear time-invariant (LTI) block, a nonlinear block with a nonlinear mapping function, and another LTI block connected in series. The model is adapted in two steps. First the filters are measured and afterwards the parameters for the nonlinear part of the digital model are optimized with the Levenberg–Marquardt method to minimize a cost-function describing the error between the digital model and the analog reference system. A small number of guitar amplifiers are modeled, the adapted model is evaluated with objective scores, and a listening test is performed to rate its quality.
Exponential, or sometimes called logarithmic, swept-sine signal is very often used to analyze nonlinear audio systems. In this paper, the theory of exponential swept-sine measurements of nonlinear systems is reexamined. The synchronization procedure necessary for a proper analysis of higher harmonics is detailed leading to an improvement of the formula for the exponential swept-sine signal generation. Moreover, an analytical expression of spectra of the swept-sine signal is derived and used in the deconvolution of the impulse response. A Matlab code for generation of the synchronized swept-sine, deconvolution, and separation of the impulse responses is given with discussion of some application issues and an illustrative example of harmonic analysis of current distortion of a woofer is provided.
This correspondence considers the problem of how to adjust the phase angles of a periodic signal with a given power spectrum to minimize its peak-to-peak amplitude. This "peak-factor problem" arises in radar, sonar, and numerous other applications. However, in spite of the wide-spread interest it has evoked, the peak-factor problem has so far defied solution except in cases where the number of spectral components is small enough to permit an effectively exhaustive search of all phase angle combinations. In this correspondence, a formula for the phase angles is derived that yields generally low peak factors, often comparable to that of a sinusoidal signal of equal power. A formula is also derived for the case in which the phase angles are restricted to 0 and pi . The latter formula is applicable to the problem of constructing binary sequences of arbitrary length with Iow autocorrelation coefficients for nonzero shifts.
Guitar Effects-Pedal Emulation and Identification
  • Ben Holmes
Ben Holmes, Guitar Effects-Pedal Emulation and Identification, Ph.D. thesis, Queen's University Belfast, June 2019.
The Potentiometer Handbook: Users' Guide to Cost-Effective Applications
  • Carl David
Carl David Todd, The Potentiometer Handbook: Users' Guide to Cost-Effective Applications, McGraw-Hill, New York, 1975.
Big Muff Pi Analysis
  • Electrosmash
Electrosmash, "Big Muff Pi Analysis,"