AN-348(1) OBTAINING SINUSOIDAL WAVEFORMS

Similar documents
ELECTRONOTES APPLICATION NOTE NO Hanshaw Road Ithaca, NY Sept 13, 2013

(Refer Slide Time: 00:03:22)

Positive Feedback and Oscillators

Optimization of an OTA Based Sine Waveshaper

Communication Engineering Prof. Surendra Prasad Department of Electrical Engineering Indian Institute of Technology, Delhi

Experiment No. 3 Pre-Lab Phase Locked Loops and Frequency Modulation

EE 42/100: Lecture 8. 1 st -Order RC Transient Example, Introduction to 2 nd -Order Transients. EE 42/100 Summer 2012, UC Berkeley T.

LM13600 Dual Operational Transconductance Amplifiers with Linearizing Diodes and Buffers

C H A P T E R 02. Operational Amplifiers

T.J.Moir AUT University Auckland. The Ph ase Lock ed Loop.

Circuit Applications of Multiplying CMOS D to A Converters

Analog Circuits and Systems

Experiment 1: Amplifier Characterization Spring 2019

UNIT III ANALOG MULTIPLIER AND PLL

Basic Electronics Learning by doing Prof. T.S. Natarajan Department of Physics Indian Institute of Technology, Madras

11. Chapter: Amplitude stabilization of the harmonic oscillator

Lauren Gresko, Elliott Williams, Elaine McVay Final Project Proposal 9. April Analog Synthesizer. Motivation

Audio Applications of Linear Integrated Circuits

The Design of A Reaktor Core Model of the Korg MS-20 VCF James J. Clark Sept. 2005

AC phase. Resources and methods for learning about these subjects (list a few here, in preparation for your research):

XR-2206 Monolithic Function Generator

New Techniques for Testing Power Factor Correction Circuits

Lecture 18 Stability of Feedback Control Systems

Poles and Zeros of H(s), Analog Computers and Active Filters

A SAWTOOTH-DRIVEN MULTI-PHASE WAVEFORM ANIMATOR: THE SYNTHESIS OF "ANIMATED" SOUNDS - PART 1;


RFID Systems: Radio Architecture

ELEC3242 Communications Engineering Laboratory Frequency Shift Keying (FSK)

BASIC ELECTRONICS PROF. T.S. NATARAJAN DEPT OF PHYSICS IIT MADRAS

Module 5. DC to AC Converters. Version 2 EE IIT, Kharagpur 1

Laboratory 8 Operational Amplifiers and Analog Computers

MKII. Tipt p + + Z3000. FREQUENCY Smart VC-Oscillator PULSE WIDTH PWM PWM FM 1. Linear FM FM 2 FREQUENCY/NOTE/OCTAVE WAVE SHAPER INPUT.

PHYS 536 The Golden Rules of Op Amps. Characteristics of an Ideal Op Amp

BSNL TTA Question Paper Control Systems Specialization 2007

UNIT 2. Q.1) Describe the functioning of standard signal generator. Ans. Electronic Measurements & Instrumentation

Testing Power Factor Correction Circuits For Stability

Spectrum analyzer for frequency bands of 8-12, and MHz

Thursday, 1/23/19 Automatic Gain Control As previously shown, 1 0 is a nonlinear system that produces a limit cycle with a distorted sinusoid for

Physics 303 Fall Module 4: The Operational Amplifier

Experiment 18: Driven RLC Circuit

Physics 123: Homework 4: Op Amps II

Chapter 8. Natural and Step Responses of RLC Circuits

User Guide V

Summer 2015 Examination

2.2 FILTERING. New Spectrum New Spectrum as Prod ct of Sawtooth Spectrum and the

Experiment VI: The LRC Circuit and Resonance

LM13700 Dual Operational Transconductance Amplifiers with Linearizing Diodes and Buffers

THE SINUSOIDAL WAVEFORM

Experiment 7: Frequency Modulation and Phase Locked Loops

The steeper the phase shift as a function of frequency φ(ω) the more stable the frequency of oscillation

D102. Damped Mechanical Oscillator

A-110 VCO. 1. Introduction. doepfer System A VCO A-110. Module A-110 (VCO) is a voltage-controlled oscillator.

Operational Amplifiers

Spectrum Analysis: The FFT Display

Communication Engineering Prof. Surendra Prasad Department of Electrical Engineering Indian Institute of Technology, Delhi

Lab 4: Transmission Line

multiplier input Env. Det. LPF Y (Vertical) VCO X (Horizontal)

Laboratory 9. Required Components: Objectives. Optional Components: Operational Amplifier Circuits (modified from lab text by Alciatore)

Non-linear Control. Part III. Chapter 8

THE TREND toward implementing systems with low

Signals, systems, acoustics and the ear. Week 3. Frequency characterisations of systems & signals

Sine-wave oscillator

NEGATIVE FREQUENCIES AND THROUGH-ZERO FREQUENCY MODULATION

9 Feedback and Control

LM565/LM565C Phase Locked Loop

Laboratory 6. Lab 6. Operational Amplifier Circuits. Required Components: op amp 2 1k resistor 4 10k resistors 1 100k resistor 1 0.

Acoustics, signals & systems for audiology. Week 3. Frequency characterisations of systems & signals

Active Filter Design Techniques

LM13700 Dual Operational Transconductance Amplifiers with Linearizing Diodes and Buffers

User Guide. Ring Modulator - Dual Sub Bass - Mixer

Analog Synthesizer: Functional Description

The G4EGQ RAE COURSE Lesson 9 Transmitters Lesson 8 looked at a simple transmitter exciter comprising of oscillator, buffer and multiplier stages.

THE DESIGN OF WIDEBAND ANALOG 90 PHASE DIFFERENCING NETWORKS WITHOUT /\ LARGE SPREAD OF CAPACITOR VALUES;

Oscillators. An oscillator may be described as a source of alternating voltage. It is different than amplifier.

Microelectronic Circuits II. Ch 9 : Feedback

ECEN 325 Lab 5: Operational Amplifiers Part III

System on a Chip. Prof. Dr. Michael Kraft

Table of Contents Lesson One Lesson Two Lesson Three Lesson Four Lesson Five PREVIEW COPY

Basics of Digital Filtering

USER. manual. Falco Systems WMA-100. High Voltage Amplifier DC - 500kHz

Synthesizer. Team Members- Abhinav Prakash Avinash Prem Kumar Koyya Neeraj Kulkarni

Exercise MM About the Multimeter

BMC011. Wave Animator Written April 8, 2013 Last Editted April 8, 2013

EE 368 Electronics Lab. Experiment 10 Operational Amplifier Applications (2)

OCS-2 User Documentation

LM565 LM565C Phase Locked Loop

Chapter 13 Oscillators and Data Converters

Amplifier Classes. nothing! Let us compare this to if the amplifier ONLY had to drive a 4 ohm load the dissipation

An Analog Phase-Locked Loop

Introductory Electronics for Scientists and Engineers

Communication Circuit Lab Manual

= knd 1/ 2 m 2 / 3 t 1/ 6 c

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Physics 8.02 Spring Experiment 11: Driven RLC Circuit

Operational Amplifiers

Instruction Manual for Concept Simulators. Signals and Systems. M. J. Roberts

Modeling Amplifiers as Analog Filters Increases SPICE Simulation Speed

DEPARTMENT OF ELECTRICAL ENGINEERING AND COMPUTER SCIENCE MASSACHUSETTS INSTITUTE OF TECHNOLOGY CAMBRIDGE, MASSACHUSETTS 02139

250 MHz, Voltage Output 4-Quadrant Multiplier AD835

UNIT I. Operational Amplifiers

tyuiopasdfghjklzxcvbnmqwertyuiopas dfghjklzxcvbnmqwertyuiopasdfghjklzx cvbnmqwertyuiopasdfghjklzxcvbnmq

Transcription:

ELECTRONOTES APPLICATION NOTE NO. 348 1016 HanshawRd. Ithaca, NY 14850 July 1998 (607)-257-8010 CONTRASTING SINEWAVE GENERATION IN THE ANALOG AND DIGITAL CASES OBTAINING SINUSOIDAL WAVEFORMS Nothing is more fundamental to true (non-sampling) music sound synthesis than oscillators. Very early electronic music studios had banks of sinewave oscillators in an additive arrangement. The so-called "subtractive" or voltagecontrolled synthesis techniques pioneered by Robert Moog and others used oscillators that produced more complex waveforms that were then filtered down (subtracted) to produce desired, time varying spectra. Digital synthesis often involves digital sinewave oscillators which can be both trivial and subtle. Probably the most familiar oscillator visible in everyday life is the pendulum (Fig. 1). A pendulum swings back and forth periodically. It is a familiar problem in elementary physics to show that the motion is the solution to a second-order differential equation. (Even this simple system requires an interesting approximation). The pendulum (or better still, a mass and spring system) provides sinusoidal or "simple harmonic motion." But, we may well protest, a pendulum does not keep oscillating. It slows down and then eventually stops. That is, unless you supply additional energy at appropriate times. This is because there is friction in real cases and this dissipates energy. The oscillator is kept going by making up for the lost energy, usually by replacing the energy lost once each cycle. This is how a pendulum clock is kept going, by providing energy from a wound spring, the potential energy of a weight, or perhaps a battery. It is the same way that a child on a swing is kept contented by a gentle push upon each return to the parent. Accordingly, obtaining sinusoidal waveforms as the natural response of second-order systems (supplied with a little extra energy) offers a relatively simple approach for both analog and digital synthesis. Surprisingly, this is very seldom used in analog synthesis, and only sparingly in digital synthesis. One reason for this in the analog case is the problem of obtaining a stable oscillation. Another is that the sine wave, used by itself rather than in combinations of different frequencies, is not a particularly useful musical waveform (lacking harmonics, it doesn't have anything to filter, and is somewhat flute-like by itself). A third reason is that a sinewave is extremely difficult to waveshape into either a sawtooth or a triangle (a square wave is trivially obtained with a comparator). AN-348(1)

Fig. 1 A Simple Pendulum as a Simple Harmonic Oscillator lower amplitude limit turn around Fig. 2 Sawtooth and Triangle Obtained from Samps

More common is a "computational" approach. Here time advances and we compute the waveform as a function of time. In analog synthesis however, it is not the usual practice to compute sinusoidal functions of advancing time. Instead, we compute linear functions of advancing time - voltage proportional to time itself. These are ramps. Linear ramps are generated by driving constant currents into capacitors. Ramps are nice; but they run off scale and are not periodic. To make them periodic, they must either be reset when they try to exceed a certain limit (a sawtooth based oscillator), or turned around when they try to exceed certain amplitude limits (a triangle based oscillator)(fig. 2). The triangle and sawtooth waveforms are fairly easily shaped, either one into the other. A square wave is obtained from either the saw or the triangle, and a sinewave approximation is obtained by shaping the triangle with a non-linear device (Fig. 3). NETWORKS AND COMPLEX PLANES While a pendulum or similar mechanical device provides a very useful intuitive grasp of analog sinewave oscillators, we need to get somewhat closer to electronic versions of these oscillators. There are a good number of analog sinewave oscillator networks (circuits), but few are used in synthesizers. Perhaps the closest circuit that is commonly found in a synthesizer that resembles a sinewave oscillator is a state-variable filter. Fortuitously, this same network also models the generic form of a sinewave oscillator. Fig. 4A shows an interconnection of two analog integrators and a summer, which many will recognize as a state-variable filter (the exact arrangement and notation has been changed slightly to better emphasize the strong resemblance to a second order digital network). The particular input/output arrangement shown is for a bandpass response. The transfer function is: TB(s) = VB(s)/Vin(s) = s / [s2 + (1/Q)S + 1] (1) From this, it is clear that if Q -><x>the poles of the network will occur when: s 2 + 1 = 0 (2) which has solutions s = ±j, that is, poles on the jo-axis (Fig. 4B), and accordingly, a sinewave oscillator results. In an ideal case, making this network oscillate would seem to be just a matter of removing the middle feedback link (-1/Q). Accordingly, when this link is non-zero, it is seen to provide damping. AN-348 (3)

NON-LINEAR TRANSFER FUNCTION (e.g. overdriven CA3080) Fig. 3A Non-Linear Transfer Function Shapes Triangle to Sine Symmetry Adjust Fig. 3B Overdriving the CA3080 Input to a Level of ±78mv Shapes Triangle to Sine AN-348 (4)

Impuli -i*. *, Output Output ANALOG SINEWAVE OSCILLATOR DIGITAL SISEWAVE OSCILLATOR ANALOG OSCILLATOR IN s-plahe AN-348 (5)

{ Persons familiar with analog VCF's are perhaps familiar with the Q of some early versions of the state-variable filter (multi-mode) going to infinity at high frequencies, resulting in filter oscillation (although not with a waveform as nice as a sine wave). In an ordinary, non-voltage controlled state-variable filter, pulling out the 1/Q path generally did not result in instability, but just a very high-q filter. With the control elements in there (usually an OTA of the CA3080 type), there was enough additional phase shift to de-stabilize the filter, and this phase shift increases with higher frequencies. This is why you will often see small capacitors, say about 10 pf, across the input resistors to these control stages (Fig. 5). This adds a zeros to the loop which compensates for the excess phase. Reference [1]} The digital oscillator network [2,3] shown in Fig. 4C is drawn pretty much as a standard second-order digital filter with two feedbacks. It resembles the analog oscillator quite closely. Here we have two delays and a summer. Note that the feedback from the bottom of both networks is a -1. For the analog sinewave oscillator, the upper feedback is -1/Q=0 while for the digital oscillator, it is Ai=2 cos(ant) where cop is the desired frequency of oscillation and T = 1/fs is the sampling period, with fs being the sampling frequency. This network has a transfer function: H(z) = z' 1 / (1 - A-iz' 1 - A0z- 2 ) (3) which has poles (for the complex conjugate case of interest) at: Zp1,Zp2 = Al/2±j(-Ai2-4A0) 1/2 /2 (4) which, for A0=-1, are easily seen to be at: zp1,zp2 = cos(ont) ± jsin(q0t) (5) So the poles are on the unit circle at an angle corresponding to the desired oscillation frequency (Fig 4D). For example, if the sampling frequency is 8000 Hz and the poles are at an angle of 45 with respect to the positive real axis, the frequency of oscillation (in Hz) would be 1000. A CONUNDRUM? As mentioned, it is extremely difficult, with analog components, to put poles exactly on the jtd-axis and keep them there. With the digital sinewave oscillator, we need to put poles exactly on the unit circle and keep them there. Is this possible? AN-348 (6)

lop Capacitor Compensates VCF Stage to Prevent Oscillation Voltage-Controlled Integrator Cosj^j) Cos(ne) Sin(6) ;os(6) Cos(e) Sin(ne) Fig. 6 "Coupled Form" of Digital Sinewave Oscillator has Implementation Problems AN-348 (7)

Well, keeping them there is not a problem, as there is no drift of any sort associated with numbers. Further, equation (5), coming from equation (3) with Ao=-1 seems to indicate that the pole radius is exactly one. Thus we understand the successful oscillation as a consequence of being able to set the bottom multiplier, AQ, to exactly -1. Now for the problem. While it is possible to multiply by -1 with no roundoff (changing a sign bit), it is not possible to multiply by the general values of the coefficient AI without roundoff. While it seems that A^ only changes the frequency of oscillation, and has nothing to do with whether the oscillation is stable, we need to note that the roundoff error following A-j is summed with the feedback through An and is then placed in the top of the delay line. How does the oscillator "know" that the roundoff came from the AI multiplier and not from the Ag multiplier! Clearly, the oscillator does not "know" so we are led to suppose that somehow, the roundoff must average out. But, this is probably not a correct view, since we have the empirical result that these oscillators always work, and we would expect averaging to be inexact in at least some cases. It would seem that some type of subtle negative feedback is operating here. COUPLED FORM DIGITAL OSCILLATOR So it might seem that digital sinewave oscillators just "decide" to work despite some questions about roundoff. But, if we next consider the so-called "coupled form" for the digital oscillator (Fig. 6), we find this refusing to work. Realized with floating point arithmetic, it either dies or blows up. This we can understand in terms of our inability to put the poles exactly on the unit circle [specifying cos(o) and sin{9)] with a finite number of bits. Realized with fixed point arithmetic for the signal, we find to our surprise that the oscillator may stabilize, but not with an amplitude corresponding to the initial state. Not untypically, it may decay to only 10% of the initial amplitude before locking on. All of this suggests a limit-cycle behavior [4]. COMPUTING SINEWAVES WITH LOOK-UP TABLES In an analog function generator or VCO, we saw that a computational approach rather than a second-order system approach was used to obtain sinewaves. A similar procedure in the digital case involves the look-up table. Here, time advances (driven by the digital system's clock) and in pace with it, we know the appropriate phase for a given frequency. This allows us to simply look up the corresponding samples from a table stored in memory. The same table (often only a single quadrant is used) can be used for as many sinewaves as we care to consider. AN-348 (8)

SOME SUMMARY COMMENTS While sinewaves are clearly fundamental to music synthesis, analog sinewave oscillators are not especially easy to generate directly, or to work with; nor are they especially useful in isolation. Digital generation of sinewaves from a second-order network can be, however, very reliable. Yet one must still be very careful to choose an appropriate network, and to be prepared for subtle quirks in their performance. These isolated sinewaves are not especially useful either, but the potential for simultaneous generation of multiple sinewaves (by cutting and pasting lines of code) should not be overlooked. REFERENCES [1] B. Hutchins, "Compensation of Linear Circuit Blocks for the Effects of Real Operational Amplifiers," Electronotes. Vol. 15, No. 164-167 (Special Issue F), July 1986, pp 47-65 [2] B. Hutchins, "Design Considerations for Digital Sinewave Oscillators," Electronotes Application Note No. 299, Sept/Oct. 1987 [3] B. Hutchins, "A View of a Digital Sinewave Oscillator," Electronotes Application Note No. 309, Sept. 1990 [4] B. Hutchins, "Frequency Errors and Distortion in Digital Sinewave Oscillators," Electronotes. Vol. 18, No. 186, Sept. 1995, pp 3-50