Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Tube Amp Modeling (Read 8431 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Tube Amp Modeling

I'd like to dig into modeling tube amps with digital equipment. I have basic knowledge about DSP, FIR/IIR filters, phase shift in IIR filters and such.
Now for a try, I've ran a ~300Hz sine wave through an tube amplifier (OR120-like).
This is the sine wave:

Tube Amp Modeling

Reply #1
SPICE is a pretty good way to model the behavior of analog circuits with relatively high accuracy.  Its just really slow since you're doing a full time domain model of the underlying electronics rather than black boxing it.

If you want something less accurate but faster, take a look at Google scholar.  People have proposed an enormous number of approximate models that simulate the nonlinearity and feedback of tube amplifier circuits without the full simulation of the underlying electronics, at least to some degree.

Tube Amp Modeling

Reply #2
I think you just need to make a (non linear) transfer function.  i.e. For small values, input = output.  At larger values, you reduce the gain proportional to the input level, so you eventually get limiting/clipping. 

You can use different transfer functions for positive & negative half-cycles.

Some low-pass filtering should help too.  The waveform looks a lot like a clipped waveform through a low-pass filter. 

Remember that the sound of a guitar amp also depends on the speaker & cabinet.

And, there may be another effect you are not seeing with a constant sine wave...  If the power supply is unregulated (or intentionally "soft") You can get more power on the attack (when you pluck the string), and then the voltage starts to "sag", and you get clipping/limiting, or more clipping/limiting...  Like a compressor/limiter with a relatively slow attack.

You should be able to get something of a "tube sound", but modeling the sound of a particular amp won't be easy, and it's going to take more than one measurement at one frequency and one output level. 

Quote
In the output, you can see, that the amplifier is Class-A
You really can't (practically) make a 100W class A amplifier!!!          Class-A amplifiers are something like 20% efficient, so it would need to consume 500W (even at low output-volume) and the output tube would have to dissipate all of that wasted power.  Guitar amps are usually Class-A/B design (with 2 or 4 output tubes).    The input/preamp stage could be class A, but a class-A amplifier can be just as linear as any other amplifier design.  Or for a guitar amp, it might be designed to have "character".

One way to create asymmetry (in hardware) is to use different gains for the positive & negative half of the waveform.  i.e. In the Class-A/B output stave, the "top"  tube stage has different gain than the "bottom" tube stage.  (I've read about that being done in guitar amps.... Actually I read about a guy who "fixed" a guitar amp by making both halves equal, and the guitar player was not happy with the reapair!)

Tube Amp Modeling

Reply #3
I'd like to dig into modeling tube amps with digital equipment. I have basic knowledge about DSP, FIR/IIR filters, phase shift in IIR filters and such.
Now for a try, I've ran a ~300Hz sine wave through an tube amplifier (OR120-like).
This is the sine wave:


It kinda depends on what you want to do. If you want to experiment with the effects of component and circuit configuration changes on system performance with audio signals, then the SPICE model approach seems like the way to go.

If you want to experiment with the effects of various input-output characteristics on system performance with audio signals then you have other options. I'm not a Matlab guru (way over my pay grade) but I understand that it or possibly some freeware version of it would be the way to go. I seem to recall Woodinville posting something here lately about some software that might fit your need.

The basic idea is that you model the frequency response/impulse response of the amplifier with a linear model and model the input-output nonlinearities with a nonlinear model and cascade the two.

There are also hybrid approaches were you use SPICE models to develop parameters for Matlab (-like) mathematical models.

Tube Amp Modeling

Reply #4
It kinda depends on what you want to do. If you want to experiment with the effects of component and circuit configuration changes on system performance with audio signals, then the SPICE model approach seems like the way to go.

If you want to experiment with the effects of various input-output characteristics on system performance with audio signals then you have other options. I'm not a Matlab guru (way over my pay grade) but I understand that it or possibly some freeware version of it would be the way to go. I seem to recall Woodinville posting something here lately about some software that might fit your need.

The basic idea is that you model the frequency response/impulse response of the amplifier with a linear model and model the input-output nonlinearities with a nonlinear model and cascade the two.

There are also hybrid approaches were you use SPICE models to develop parameters for Matlab (-like) mathematical models.

There are many tools for implementing algorithms on a PC. Some allow for realtime audio i/o (if your hardware is capable of doing the desired number-crunching). Some are free, some are not. In many cases, there will be a demo version/student version/limited trial available.

Common prototyping tools seems to be:
MATLAB
Octave
Python
LabView

Now, I think that the problem of doing good tube-amplifier/loudspeaker modelling is harder than implementing the math in some software language. Can you input the block-diagram of some tube amplifier into Spice and get a reasonable prediction of the response of a physical implementation of that circuit? I was under the impression that stuff like non-ideal transformers, heating etc made this task complicated.

Is there some sensible theoretical framework that can both describe e.g. tube-amps and be used as an aid for adapting the model to some given system, like the LTI framework does for things like room reverb? I had hoped that Volterra Series would be such a thing, but I am not so sure anymore.

-k

Tube Amp Modeling

Reply #5
Tubes are not linear nor time invariant and they tend to feedback a lot. So you're looking at a nonlinear system that is also recursive to some extent. Models are pretty much all you can use in this case, with complexity well correlated with accuracy.

Many have been proposed over the years.