Hacker News new | ask | show | jobs
by JKCalhoun 197 days ago
As a hobbyist, I'm playing with analog computer circuits right now. If you can match your curve with a similar voltage profile, a simple analog integrator (an op-amp with a capacitor connected in feedback) will also give you the area under the curve (also as a voltage of course).

Analog circuits (and op-amps just generally) are surprising cool. I know, kind of off on a tangent here but I have integration on the brain lately. You say "4 lines of Python", and I say "1 op-amp".)

4 comments

One of my favorite circuits from Korn & Korn [0] is an implementation of an arbitrary function of a single variable. Take an oscilloscope-style display tube. Put your input on the X axis as a deflection voltage. Close a feedback loop on the Y axis with a photodiode, and use the Y axis deflection voltage as your output. Cut your function of one variable out of cardboard and tape to the front of the tube.

[0] https://www.amazon.com/Electronic-Analog-Computers-D-c/dp/B0...

N-SPHERES

https://youtu.be/BDERfRP2GI0

N-SPHERES ist the most complex Oscilloscope Music work by Jerobeam Fenderson & Hansi3D and took six years to make.

Since it is almost entirely created with parametric functions, it is possible to store only these functions in an executable program and let the program create the audio and video output on the fly. The storage space required for such a program is just a fraction of an audio or video file, so that it's possible to store the executables for the entire audiovisual EP all on one 3.5" 1.44MB floppy disk.The first 500 orders will receive the initial numbered edition with pen-plotted artwork

Yep. This is also how you solve differential equations with analog computers. (You need to recast them as integral equations because real-world differentiators are not well-behaved, but it still works.)

https://i4cy.com/analog_computing/

How does this compare to the Picard-Lindelof theorem and the technique of Picard iteration?
On op-amps I've got a personal theory that the cochlea amplifier in ear is basically an op amp providing negative feedback to prevent excessive amplitudes rather than the positive feedback mentioned in Wikipedia https://en.wikipedia.org/wiki/Cochlear_amplifier
Speaking of Analog computation:

A single artificial neuron could be implemented as:

Weighted Sum

Using a summing amplifier:

net = Σ_i (Rf/Ri * xi)

Where resistor ratios set the synaptic weights.

Activation Function

Common op-amp activation circuits:

Saturating function: via op-amp with clipping diodes → approximated sigmoid

Hard limiter: comparator behavior for step activation

Tanh-like response: differential pair circuits

Learning

Early analog systems often lacked on-device learning; weights were manually set with potentiometers or stored using:

Memristive elements (recent)

Floating-gate MOSFETs

Programmable resistor networks