collocated proportional-integral-derivative (pid) control ... · collocated...
TRANSCRIPT
ABabcdfghiejkl
Collocated proportional-integral-derivative(PID) control of acoustic musical instruments
Edgar Berdahl and Julius O. Smith III
Department of Electrical EngineeringCenter for Computer Research in Music and Acoustics (CCRMA)
Stanford UniversityStanford, CA, 94305
Education in Acoustics: Tools for Teaching AcousticsThursday Morning at 10:20AM, June 7th, 2007
—Special thanks to the Wallenberg Global LearningNetwork for supporting the REALSIMPLE project
ABabcdfghiejkl
Outline
Overview
Theory
Laboratory Exercise In Pure Data
ABabcdfghiejkl
The RealSimPLE Project
◮ RealSimPLE is a web-based teacher’s resource for studentlaboratory sessions in musical acoustics.
ABabcdfghiejkl
The RealSimPLE Project
◮ RealSimPLE is a web-based teacher’s resource for studentlaboratory sessions in musical acoustics.
◮ Music is a good way to interest young people in math,science, and engineering.
ABabcdfghiejkl
The RealSimPLE Project
◮ RealSimPLE is a web-based teacher’s resource for studentlaboratory sessions in musical acoustics.
◮ Music is a good way to interest young people in math,science, and engineering.
◮ Physical experiments and pedagogical computer-basedsimulations of the same systems run in parallel andinterconnected.
ABabcdfghiejkl
The RealSimPLE Project
◮ RealSimPLE is a web-based teacher’s resource for studentlaboratory sessions in musical acoustics.
◮ Music is a good way to interest young people in math,science, and engineering.
◮ Physical experiments and pedagogical computer-basedsimulations of the same systems run in parallel andinterconnected.
◮ The traditional lab bench is enhanced rather than replaced.
ABabcdfghiejkl
The RealSimPLE Project
◮ RealSimPLE is a web-based teacher’s resource for studentlaboratory sessions in musical acoustics.
◮ Music is a good way to interest young people in math,science, and engineering.
◮ Physical experiments and pedagogical computer-basedsimulations of the same systems run in parallel andinterconnected.
◮ The traditional lab bench is enhanced rather than replaced.◮ Only standard computers and some inexpensive,
easy-to-build hardware are required.
ABabcdfghiejkl
The RealSimPLE Project
◮ RealSimPLE is a web-based teacher’s resource for studentlaboratory sessions in musical acoustics.
◮ Music is a good way to interest young people in math,science, and engineering.
◮ Physical experiments and pedagogical computer-basedsimulations of the same systems run in parallel andinterconnected.
◮ The traditional lab bench is enhanced rather than replaced.◮ Only standard computers and some inexpensive,
easy-to-build hardware are required.◮ The RealSimPLE Project is a collaboration between
Stanford University and KTH in Sweden.
RealSimPLE Laboratory Assignment Dependencies
Transfer Function
PsychoacousticsLab
Harmonic Contentof a Plucked String
ExperimentsMonochord
Monochord ActivityWeighted
ControlPID
Plucked String DigitalWaveguide Model
Traveling Waves InA Vibrating String
Auditory FilterBank Lab
Illusions LabMusical
Flute LabVirtual
Virtual AcousticTube Lab
MonochordAssembly
SoundcardSetup
START
Introduction to STKand Reverberation
Time−VaryingDelay Effects
Guitar ModelElectric
and Piano ModelsAcoustic Guitar
Measurement Toolbox
ABabcdfghiejkl
Summary Of PID Control Lab Objectives
◮ Explain the basic idea behind feedback control.
ABabcdfghiejkl
Summary Of PID Control Lab Objectives
◮ Explain the basic idea behind feedback control.◮ Describe how this discipline may be applied to a vibrating
string.
ABabcdfghiejkl
Summary Of PID Control Lab Objectives
◮ Explain the basic idea behind feedback control.◮ Describe how this discipline may be applied to a vibrating
string.◮ Describe how modifying the control parameters affects the
harmonic content.
ABabcdfghiejkl
Summary Of PID Control Lab Objectives
◮ Explain the basic idea behind feedback control.◮ Describe how this discipline may be applied to a vibrating
string.◮ Describe how modifying the control parameters affects the
harmonic content.◮ Explain what instability is and how it may arise.
ABabcdfghiejkl
Summary Of PID Control Lab Objectives
◮ Explain the basic idea behind feedback control.◮ Describe how this discipline may be applied to a vibrating
string.◮ Describe how modifying the control parameters affects the
harmonic content.◮ Explain what instability is and how it may arise.◮ Experiment with a virtual controlled string using the Pure
Data software.
ABabcdfghiejkl
Summary Of PID Control Lab Objectives
◮ Explain the basic idea behind feedback control.◮ Describe how this discipline may be applied to a vibrating
string.◮ Describe how modifying the control parameters affects the
harmonic content.◮ Explain what instability is and how it may arise.◮ Experiment with a virtual controlled string using the Pure
Data software.◮ Gain experience using Pure Data.
ABabcdfghiejkl
Feedback control
Feedback control is the discipline in which system dynamics arestudied and altered by creating feedback loops.
System+r xu
Controller
Figure: Typical block diagram for a control application
ABabcdfghiejkl
Feedback control
Feedback control is the discipline in which system dynamics arestudied and altered by creating feedback loops.
System+r xu
Controller
Figure: Typical block diagram for a control application
◮ Application to cruise control
ABabcdfghiejkl
Feedback control
Feedback control is the discipline in which system dynamics arestudied and altered by creating feedback loops.
System+r xu
Controller
Figure: Typical block diagram for a control application
◮ Application to cruise control◮ Application to a vibrating string
ABabcdfghiejkl
Outline
Overview
Theory
Laboratory Exercise In Pure Data
ABabcdfghiejkl
System Model
◮ If we collocate the sensor and actuator, then we can use thefollowing model of the lowest resonance:
Figure: Lightly-damped harmonic oscillator (R is small)
ABabcdfghiejkl
System Model
◮ If we collocate the sensor and actuator, then we can use thefollowing model of the lowest resonance:
Figure: Lightly-damped harmonic oscillator (R is small)
◮ Equivalent mass m, spring with constant K , and dampingparameter R
ABabcdfghiejkl
System Model
◮ If we collocate the sensor and actuator, then we can use thefollowing model of the lowest resonance:
Figure: Lightly-damped harmonic oscillator (R is small)
◮ Equivalent mass m, spring with constant K , and dampingparameter R
◮ mx + Rx + Kx = 0
ABabcdfghiejkl
System Model
◮ If we collocate the sensor and actuator, then we can use thefollowing model of the lowest resonance:
Figure: Lightly-damped harmonic oscillator (R is small)
◮ Equivalent mass m, spring with constant K , and dampingparameter R
◮ mx + Rx + Kx = 0
◮ Pitch f0 ≈ 12π
√
Km , and the decay time constant τ = 2m
R
ABabcdfghiejkl
Proportional-Derivative (PD) Control
◮ If we implement the feedback law F = PD x + PPx , then wearrive at the following differential equationmx + Rx + Kx = PDx + PPx
ABabcdfghiejkl
Proportional-Derivative (PD) Control
◮ If we implement the feedback law F = PD x + PPx , then wearrive at the following differential equationmx + Rx + Kx = PDx + PPx
◮ The controlled dynamics aremx + (R − PD)x + (K − PP)x = 0
ABabcdfghiejkl
Proportional-Derivative (PD) Control
◮ If we implement the feedback law F = PD x + PPx , then wearrive at the following differential equationmx + Rx + Kx = PDx + PPx
◮ The controlled dynamics aremx + (R − PD)x + (K − PP)x = 0
◮ f0 ≈ 12π
√
K−PPm and decay time τ = 2m
R−PD
ABabcdfghiejkl
Integral Control
◮ Similarly the feedback law F = PI∫
x dt
ABabcdfghiejkl
Integral Control
◮ Similarly the feedback law F = PI∫
x dt◮ The controlled dynamics are third order
mx + Rx + Kx = PI∫
x dt
ABabcdfghiejkl
Integral Control
◮ Similarly the feedback law F = PI∫
x dt◮ The controlled dynamics are third order
mx + Rx + Kx = PI∫
x dt◮ The analysis is more complicated, but for small |PI |,
τ ≈ 2m
R+PI
4π2f 2
0
ABabcdfghiejkl
Integral Control
◮ Similarly the feedback law F = PI∫
x dt◮ The controlled dynamics are third order
mx + Rx + Kx = PI∫
x dt◮ The analysis is more complicated, but for small |PI |,
τ ≈ 2m
R+PI
4π2f 2
0
◮ PID Control:◮ Can control the damping with PD and PI
ABabcdfghiejkl
Integral Control
◮ Similarly the feedback law F = PI∫
x dt◮ The controlled dynamics are third order
mx + Rx + Kx = PI∫
x dt◮ The analysis is more complicated, but for small |PI |,
τ ≈ 2m
R+PI
4π2f 2
0
◮ PID Control:◮ Can control the damping with PD and PI◮ Can control the pitch (some) with PP
ABabcdfghiejkl
Outline
Overview
Theory
Laboratory Exercise In Pure Data
ABabcdfghiejkl
Pure Data
ABabcdfghiejkl
Instability
◮ Students can choose the control parameters PP , PI , and PD
over a reasonable range.
ABabcdfghiejkl
Instability
◮ Students can choose the control parameters PP , PI , and PD
over a reasonable range.◮ Some combinations of the control parameters result in
instability.
ABabcdfghiejkl
Instability
◮ Students can choose the control parameters PP , PI , and PD
over a reasonable range.◮ Some combinations of the control parameters result in
instability.◮ The patch disables sound if the level becomes too large.
ABabcdfghiejkl
Questions For Students
After students have been given the relevant backgroundinformation, they are prodded through a series of questions toconclude the following
ABabcdfghiejkl
Questions For Students
After students have been given the relevant backgroundinformation, they are prodded through a series of questions toconclude the following
1. Sensors placed at nodes of particular harmonics will notmeasure any energy at these frequencies.
ABabcdfghiejkl
Questions For Students
After students have been given the relevant backgroundinformation, they are prodded through a series of questions toconclude the following
1. Sensors placed at nodes of particular harmonics will notmeasure any energy at these frequencies.
2. In comparison with PD, PI causes lower harmonics to bedamped more quickly than higher harmonics.
ABabcdfghiejkl
Questions For Students
After students have been given the relevant backgroundinformation, they are prodded through a series of questions toconclude the following
1. Sensors placed at nodes of particular harmonics will notmeasure any energy at these frequencies.
2. In comparison with PD, PI causes lower harmonics to bedamped more quickly than higher harmonics.
3. It is not possible to change the pitch as far as the modelpredicts before instability sets in.
ABabcdfghiejkl
Questions For Students
After students have been given the relevant backgroundinformation, they are prodded through a series of questions toconclude the following
1. Sensors placed at nodes of particular harmonics will notmeasure any energy at these frequencies.
2. In comparison with PD, PI causes lower harmonics to bedamped more quickly than higher harmonics.
3. It is not possible to change the pitch as far as the modelpredicts before instability sets in.
4. This is a weakness of the simplified model.
ABabcdfghiejkl
Challenge Problem
◮ We use Pure Data because it is easy to see how thepatches work.
ABabcdfghiejkl
Challenge Problem
◮ We use Pure Data because it is easy to see how thepatches work.
◮ We challenge advanced students to modify the patch toimplement a time-varying amplitude effect.
ABabcdfghiejkl
Challenge Problem
◮ We use Pure Data because it is easy to see how thepatches work.
◮ We challenge advanced students to modify the patch toimplement a time-varying amplitude effect.
◮ They are given the following hint:
ABabcdfghiejkl
Bibliography
E. Berdahl and J. O. Smith III,PID Control of a Plucked String, Online REALSIMPLELaboratory,http://ccrma.stanford.edu/realsimple/pidcontrol,2007.
C. Besnainou,Transforming the voice of musical instruments by activecontrol of the sound radiation,International Symposium on Active Control of Sound andVibration, Fort Lauderdale, FL, 1999.
E. Berdahl, J. O. Smith III, and A. Freed,Active damping of a vibrating string,International Symposium on Active Control of Sound andVibration, Adelaide, Australia, 2006.
ABabcdfghiejkl
Thanks
Questions?