User Tools

Site Tools


analog_computers

Analog Computers

Computing systems maybe divided into two main classifications, analog and digital. Analog computers use physical systems that mimic or model the problem that you want to solve(hence one system is said to be analogous to the other). Typical analog computers do not use discrete values like digital computers but continuously varying values. A digital computer counts and obeys logic rules exactly. The major draw back to analog computers is that the accuracy is limited by the accuracy of the individual components and the measuring devices. This is in contrast to the digital computer where more accuracy can be obtained by carrying more significant figures.

A slide rule is a simple example of an analog computer. Typically today when people talk about analog computers, they mean the electronic differential analyzer, an electronic system that can solve or mimic arbitrary differential equations. Our focus is on the electronic differential analyzer.

Building blocks

There are two ways that one can go about building a system for solving differential equations. The first way is to use devices that can perform repeated differentiation. The second way is to use a system which is based upon repeated integration. From a purely mathematical point of view, both methods are perfectly valid. From an engineering perspective, the process of differentiation causes problems. Differentiation is a noise amplifying process, and electronic devices produce noise. The accuracy of an analog computer built from differentiators would suffer a loss of accuracy due to excessive noise. By contrast, the second method of repeated integration, actually smooths out the noise and does not suffer from the problem of excess noise.

What kind of devices or building blocks would one need to build an analog computer capable of solving linear differential equations with constant coefficients?

  • Devices that can perform integration
  • Devices that can sum several quantities
  • Devices that can multiply by a constant value

Integrator

How does one go about building an electronic integrator? The electronics wizards out there say, “This is easy, let's just use a capacitor to perform integration”.

The equation that governs the capacitor is

\[i=C\frac{dv_{OUT}}{dt}\]

or

\[v_{OUT}=\int_{t=0}^t \frac{i}{C}dt +v_o\]

where $v_o$ is the initial value on the capacitor.

OK we're done. Well not so fast. This is a great circuit, but most of the time the input signal is in the form of a voltage and not a current. If one wanted to cascade two integrators to solve a second order equation, they would need a way to convert a voltage (output of the capacitor) to a current (input to the capacitor).

The electronics wizards again chime in saying, “Just use a resistor, whose governing equation is $v=iR$, to convert a voltage to a current. Why don't you try a simple RC circuit?” The resistor does indeed convert the voltage to current, but it doesn't solve all of the problems.

Using Kirchhoff's current law at the output, we come up with the following equation for the RC circuit.

\[C\frac{dv_{OUT}}{dt}=\frac{v_{in}-v_{OUT}}{R}\]

or

\[\int^{v_{OUT}}_{v_o}{dv_{OUT}}=\frac{1}{RC}\int^t_{t_o}{v_{in}dt} -\frac{1}{RC}\int^t_{t_o}{v_{OUT}}dt\]

So, if the output voltage $v_{OUT}$ is small, the second term goes to zero and we get the equation that we want.

\[v_{OUT}=\int^{v_{OUT}}_{v_o}{dv_{OUT}}=\frac{1}{RC}\int^t_{t_o}{v_{in}dt} +v_o\]

In the real world, it is hard to keep the output voltage small. So this will not work. There are other problems with this approach even in the limit of small output voltages. Connecting the output of one RC circuit to the input of another is not straight forward since some of the input to the first RC circuit is coupled to the second RC circuit. One would need to put a buffer between the stages to eliminate this problem.

The solution is to use an operational amplifier or op-amp in conjunction with the resistor and capacitor. The low frequency behavior of an op-amp is given by $v_{out}=A*(v_+-v_-$) where A is the gain and taken to be very large. If the output voltage of the op-amp is required to fit between the power supply voltages, then the difference between $v_+$ and $v_-$ has to be very small. In general, we can say that $v_+=v_-$ to simplify the analysis. Now let's take a look at the integrator circuit with the op-amp.

Notice that $v_+$ is grounded. That means that $v_-$ is also grounded, and the current through the resistor is:

\[i=\frac{v_{IN}}{R}\]

Because one side of the resistor is always at ground, the problem with the RC circuit is eliminated. Remember that in the simple RC circuit without the op-amp, the resistor current was given by:

\[\frac{v_{in}-v_{OUT}}{R}\]

now the second term,$\frac{-v_{OUT}}{R}$, which was problematic to realizing the integration function has been eliminated. Continuing on with the analysis, we use the other rule of op-amp analysis. No current flows into the input terminals. Applying that rule, one can see that the current flowing through the resistor is the same current that flows into the capacitor.

\[i=\frac{v_{IN}}{R}=C\frac{dv_C}{dt}\]

Notice that $v_C=-v_{OUT}$.

\[i=\frac{v_{IN}}{R}=-C\frac{dv_{OUT}}{dt}\]

Now we just have to get the expression into the final form.

\[\frac{-v_{IN}}{RC}dt=dv_{OUT}\]

\[v_{OUT}=\frac{-1}{RC}\int_{t_0}^t{v_{IN}dt}+v_{0}\]

This is exactly what we want except perhaps that the answer is scaled by a -1. If one can multiply by a constant -1 than it won't be a problem(one can use an op-amp in the inverting configuration to created a scale factor of -1).

Another question one might have is how to set the initial conditions on the integrator. This can be done by adding a number of switches(semiconductor or mechanical relays) and resistors to the circuit. See the circuit below.

To set the initial conditions, close S1 and S2 and open S3. That results in the following circuit.

To analyze this circuit, one can write the nodal equation at the inverting terminal.

\[\frac{v_{INIT}}{R_s}+\frac{v_{OUT}}{Rs}+C\frac{dv_{OUT}}{dt}=0\] \[v_{OUT}+R_sC\frac{dv_{OUT}}{dt}=-v_{INIT}\]

Without solving the differential equation, you can see in steady state, the derivative goes to zero and $v_{OUT}=-v_{INIT}$. If you want to solve the differential equation, you can calculate how long it will take to charge the capacitor to the initial value. Finally, if you close S3 and open S1 and S2 then you get back the basic op-amp integrator.

Constant Multiplier

Multiplying by a constant can be achieved by amplifying a signal by a constant gain. The best way to do this is to use an op-amp in either the inverting or non-inverting configuration. The inverting amplifier can multiply by negative numbers or fractions, so we'll analyze it below.

The current $i$ going into the inverting node is given by:

\[i=\frac{v_{IN}}{R_i}\]

Since, no current flowing into the op-amp the same current $i$ flows into $R_f$. Therefore the output voltage is given by:

\[v_{OUT}=iR_f=-v_{IN}\frac{R_f}{R_i}\]

Summing Block

We can use the concept of the inverting amplifier to building an inverting summing block. The trick is just to add extra input resistors.

The input current is now given by,

\[i=\frac{v_{1}+v_2+v_3}{R}\]

\[v_{OUT}=iR=-(v_{1}+v_2+v_3)\]

Excellent!

Examples

To tie everything together, I'm going to do two examples. The first example is the LC Circuit, or LC Oscillator. The full mathematical analysis of the circuit can be found here. The second example will be easier, but more applicable to the Tennis for Two game. We will solve the equations of motion for a ball dropped from 20 meters.

LC Analog Computer

High School Physics Analog Computer

The problem we are going to solve is:How long does it take to a ball dropped from 20 meters to hit the ground.

Hand Solution

If we are near the surface of the Earth, all objects fall with a constant acceleration, $a$ due to gravity. We can just write the definition of acceleration.

\[a=\frac{d^2x}{dt^2}\]

To solve this equation, we just integrate twice.

\[\int a dt=\int \frac{d^2x}{dt}\]

\[at+K_1=\frac{dx}{dt}\]

\[\int at+K_1dt=\int dx\]

\[\frac{1}{2}at^2+K_1t+K_2=x\]

The boundary conditions from the problem are that the initial velocity of the ball is zero, and the initial position is 20 meters.

\[t=0,x=20\]

\[K_2=20\]

\[t=0,v=0\]

\[\frac{d}{dt}(\frac{1}{2}at^2+K_1t+K_2)=\frac{dx}{dt}=v=0\]

\[at+K_1=0\]

\[K_1=0\]

Finishing the problem…

\[\frac{1}{2}(-9.8)t^2+20=0\] \[t=2.02\]

Analog Computing Solution

To simplify things, we'll use this symbol to represent an integrator, which can be made by cascading the integrator circuit (with switches to set the initial conditions), and an inverting amplifier with a gain of -1.

The basic idea is just to cascade two integrators…something like this.

In simulation we can do something like is…

analog_computers.txt · Last modified: 2015/06/11 21:19 by admin