# Quickstart-guide: Damped oscillation¶

The modeling of a damped oscillation is a good starting point for analog programming beginners. This article shall give a detailed step by step explanation how to implement a simulation on The Analog Thing by describing the system with a differential equation, deriving a computer circuit using the full repatriation method (originally developed by Lord Kelvin around 1875) and to get results on an oscilloscope.

There are four major steps to execute a simulation on an analog computer, all of which are equally crucial:

Describe the to be simulated system with differential equations

Derive a computer circuit from these equations

Wire the computer circuit on the analog computer (including connection to output device) and adjust parameters

Choose operation mode and viable visualization method (usually oscilloscopes).

This article will focus on point 2. to 4. and requires a basic understanding of differential equations.

## 1. Mathematical description of a damped oscillation¶

## 2. Derivation of a computer circuit¶

At first, we need to understand three basic computing elements which can probably be found on every electrical analog computer:

### Basic computing parts:¶

With these basic computing elements we are able to generate ẍ = -(d*ẋ + k*x) / m.

### Deriving the actual circuit:¶

The basic idea of the full repatriation method is to solve the differential equation for it´s highest derivative and assume it (in this case ẍ) as input of the first integrator. From there on you add computing elements to generate -(d*ẋ + k*x) / m, which will then be given as input of the first integrator to close the circuit.

## 3. Wiring the circuit on a THAT and adjusting parameters¶

In order to wire the circuit worked out above you need to be familiar with the computing elements used.

### THAT-overview¶

From this point you can start wiring the actual simulation circuit.

### Wiring THAT¶

Colors from circuit scheme and actual images are matched to make them easier to identify, but have no further meaning.

Wiring complete.

Now the potentiometers have to be set to their corresponding values. In this setup it is good to **set every potenetiometer to 0.5** for the beginning.

## 4. Operation and visualization¶

### 4.1 Output device¶

In order to study the results of a given simulation an output device is necessary. For electrical analog computers oscilloscopes are the tool of choice. They provide a graphic visualization of changing voltages over time, which is exactly what electrical analog computers give.

The THAT machine unit is 10 volts. The chinch outputs **(x,y,z,u)** are connected to a voltage devider with a factor of 1/10. So the maximum output is plus/minus 1 volt, which makes it compatible to standard mircophone inputs so it can be used with soundcard oscilloscopes.

Note: Most oscilloscopes come with BNC-input sockets. Therefore a CHINCH to BNC adapter is needed in order to connect the chinch outputs properly. However, it is possible to connect oscilloscope probes directly with the patch cables.

The trigger output can be very useful in case the oscilloscope has a free input left or even a seperate trigger input.

### 4.2 Choosing a viable operation mode¶

After setting up the output device the operation mode is to be choosen.

When setting the THAT to **OP**, the calculation will start and will continue until manually interrupted. This will lead to a valid result, but the result is only given one time. Once the damped oscillation is damped completely, the result will be zero (forever).

The damped oscillation is a good example for using the **fast repetitive mode (REPF)** in order to study the behavior of the system with
different potentiometer settings.

In this mode the THAT switches between **operation** and **initial condition**, so both the green and yellow LED appear to shine simultaniously.

For the repetitive mode the operation time needs to be taken into account. At the THAT it is controlled by the nob (OP-TIME) next to the operation mode switch.

The operation time defines the time after which the simulation is repeated. After this time the THAT switches to IC mode for a fixed amount of time in order to prepare the next simulation run.