• WARNING: Tube/Valve amplifiers use potentially LETHAL HIGH VOLTAGES.
    Building, troubleshooting and testing of these amplifiers should only be
    performed by someone who is thoroughly familiar with
    the safety precautions around high voltages.

Vacuum Tube SPICE Models

I have generated a tube model of 12B4A focused on
the low plate voltage region of up to DC30V.

My method is as follows:

Method: Ayumi's method
Ep-IP curve: measured by myself on GE's 12B4A

Obtained SPICE model is as below and Ep-Ip curve is shown
in the attachment.

* Generic triode model: 12B4ALV
* Copyright 2003--2008 by Ayumi Nakabayashi, All rights reserved.
* Version 3.10, Generated on Thu Oct 31 14:01:18 2013
* Plate
* | Grid
* | | Cathode
* | | |
.SUBCKT 12B4ALV A G K
BGG GG 0 V=V(G,K)+0.13741479
BM1 M1 0 V=(0.21659532*(URAMP(V(A,K))+1e-10))^-2.6434179
BM2 M2 0 V=(0.36201996*(URAMP(V(GG)+URAMP(V(A,K))/2.9454932)+1e-10))^4.1434179
BP P 0 V=0.003850751*(URAMP(V(GG)+URAMP(V(A,K))/8.1362729)+1e-10)^1.5
BIK IK 0 V=U(V(GG))*V(P)+(1-U(V(GG)))*0.017219613*V(M1)*V(M2)
BIG IG 0 V=0.0019253755*URAMP(V(G,K))^1.5*(URAMP(V(G,K))/(URAMP(V(A,K))+URAMP(V(G,K)))*1.2+0.4)
BIAK A K I=URAMP(V(IK,IG)-URAMP(V(IK,IG)-(0.0026566845*URAMP(V(A,K))^1.5)))+1e-10*V(A,K)
BIGK G K I=V(IG)
* CAPS
CGA G A 4.8P
CGK G K 5p
CAK A K 1.5p
.ENDS
 

Attachments

  • 12B4A-EpIp.gif
    12B4A-EpIp.gif
    13.3 KB · Views: 1,738
Ex-Moderator
Joined 2011
VT diode and regulator models from Stephie Bench (via intact audio forum):

===
Hi,

If you open STANDARD.DIO (in the cmp subdirectory... path something like ---> program files/LTC/LTspiceIV/lib/cmp/standard.dio
and append the following to it, you get a few tube rectifiers and voltage regulator tubes. If you then place a diode on your schematic, these parts will appear in your drop down menu. Note that each part is a line of text, in case this gets "folded over" during the posting.

Sorry so late with the response... this is the first time I've logged on in a bit... busy.

Stephie <3

.model 5Y3 D(Is=1e-2 RS=180 Cjo=20p vj=2 N=400 bv=1400 mfg=Stephie type=vacuum )
.model 5R4 D(Is=1e-2 RS=150 Cjo=30p vj=2 N=305 bv=3100 mfg=Stephie type=vacuum )
.model 6X4 D(Is=1e-2 RS=121 Cjo=20p vj=2 N=256 bv=1250 mfg=Stephie type=vacuum )
.model 5U4 D(Is=1e-2 RS=103 Cjo=30p vj=2 N=250 bv=1550 mfg=Stephie type=vacuum )
.model 6AL5 D(Is=1e-2 RS=60 Cjo=5p vj=2 N=128 bv=330 mfg=Stephie type=vacuum )
.model 5AR4 D(Is=1e-2 RS=36 Cjo=30p vj=2 N=80 bv=1500 mfg=Stephie type=vacuum )
.model 0A2 D(Is=10u Rs=50 Cjo=10p nbv=147 bv=150 Ibv=20m Vpk=150 mfg=Stephie type=zener )
.model 0A3 D(Is=10u Rs=30 Cjo=10p nbv=72 bv=75 Ibv=20m Vpk=75 mfg=Stephie type=zener )
.model 0B2 D(Is=10u Rs=33 Cjo=10p nbv=105 bv=108 Ibv=20m Vpk=108 mfg=Stephie type=zener )
.model 5651 D(Is=1u Rs=1k Cjo=1p nbv=84 bv=85.5 Ibv=2.5m Vpk=85.5 mfg=Stephie type=zener )
 
Administrator
Joined 2004
Paid Member
RajkoM would you mind posting instructions and screen captures here for curving tracing pentodes in LTspice - I'm not having much success and I need to vet some models I've created using my uTracer.. (I don't trust my pentode models at all, I suspect operator error due to inexperience.)

Edit: Note my source order. (Also I'm using an Ayumi tube model here, not one of the ones I generated) I just would like to see how other people do it, if different and/or if I am doing something stupid. This one looks reasonable but I have not checked it against a data sheet or on the bench yet.
 

Attachments

  • Capture.JPG
    Capture.JPG
    131.1 KB · Views: 1,722
  • Capture2.JPG
    Capture2.JPG
    108.2 KB · Views: 1,705
RajkoM would you mind posting instructions and screen captures here for curving tracing pentodes in LTspice - I'm not having much success and I need to vet some models I've created using my uTracer.. (I don't trust my pentode models at all, I suspect operator error due to inexperience.)
.

Kevin,
I'm not expert in creation pentode spice models. I made ​​only two: C3M and another one for my personal use. These models have not seen on the net before.
As I said, I used the formula for Kvb, Kg1 .... from the net (from memory: Paeng - digilander.libero.it and Eugene Karpov instruction).
With the obtained approximate values​​, go to LTspice and make fine adjustments. Small changes in parameters MU, Ex, Kvb, Kg1, Kg2, Kp I brought the model to the diagram as the manufacturer data sheet.

Relatively patient and painstaking work.:)
 
Administrator
Joined 2004
Paid Member
Hi Raj,
I was actually thinking of the model testing protocol in LTspice rather than generating the models themselves. I have not done much testing of models prior to now and was wondering if I was on the right track or not.

My curve tracer can generate models directly from tubes I have swept, but they are only good if the ranges for tracing are appropriate. I've had a few good results with pentodes, and more than a few that were garbage or it could be that the pentodes in question just aren't very linear. Triodes are way easier. lol
 
In this thread, I posted a link to an alternative tube model for tetrod/pentod: Modeling and Simulation of the Power Amplifier for the RHIC 28 MHz Accelerating Cavity.pdf by S. Zheng and John Keane.

They work with high frequency, but a pentod/tetrod remain the same tube at any frequency. The parasitic caps will have more importance at high frequency, which force to use other montages, but the tube and its model remain the same. The curves they give for the 4CW150000 look pretty similar to the curves from its data sheet. That imply their model seam to be very good to modelize the tube at any Ua even when in saturation. In the paper, they give the SPICE model and how to calculate the model's parameters from the curves.

The main issue is they use the constant current curves, which are common for high power tubes like that one, but don't exist for low power tubes. Fortunately, it is quite easy, even if it is time consuming, to extrapolate the constant current curves from the constant voltage curves.

As I use the 807, and have expensive data on that tube, I begun it was some time ago to extrapolate the constant current curves. I was almost done when a falling harddisk screwed my work. So, I am back to case one. If anyone is interested, I use Engauge Digituzer to get the data from the original curves. After that, I will import them into some spreadshhet to draw the new curves, and hopefully calculate the parameters at the same time.
 
Administrator
Joined 2004
Paid Member
@kevinkr - The LTSpice schematic looks correct, and the curves as well. But I am not sure how your curve tracer can generate models directly... Are you using Dr. Dekker's uTracer?

Yes, and I am using Nick Barton's alternate gui which automatically generates spice models from the curves measured. Just have to create the tube profile first and what spice model to use - one triode and four pentode/tetrode models - Norman Koren generic models are used. This all presupposes that you know what you are doing, and I am not sure I always do.. lol Obviously the model results depend heavily on the test parameters chosen for the specific tube. I am coming to the conclusion that in some instances more than one model may be required with different screen voltages, and specifically if operating at low voltages.

The uTracer is proving to be useful beyond my wildest imaginings - I'm using it a lot more than I had originally envisaged.
 
Ex-Moderator
Joined 2011
In this thread, I posted a link to an alternative tube model for tetrod/pentod: Modeling and Simulation of the Power Amplifier for the RHIC 28 MHz Accelerating Cavity.pdf by S. Zheng and John Keane.

They work with high frequency, but a pentod/tetrod remain the same tube at any frequency. The parasitic caps will have more importance at high frequency, which force to use other montages, but the tube and its model remain the same. The curves they give for the 4CW150000 look pretty similar to the curves from its data sheet. That imply their model seam to be very good to modelize the tube at any Ua even when in saturation. In the paper, they give the SPICE model and how to calculate the model's parameters from the curves.

The main issue is they use the constant current curves, which are common for high power tubes like that one, but don't exist for low power tubes. Fortunately, it is quite easy, even if it is time consuming, to extrapolate the constant current curves from the constant voltage curves.

As I use the 807, and have expensive data on that tube, I begun it was some time ago to extrapolate the constant current curves. I was almost done when a falling harddisk screwed my work. So, I am back to case one. If anyone is interested, I use Engauge Digituzer to get the data from the original curves. After that, I will import them into some spreadshhet to draw the new curves, and hopefully calculate the parameters at the same time.

Please take a look at Robert's post above. It gets very good results for pentodes and most tetrodes.
 
I received an email from Ron Dekker yesterday indicating that the "manual" for the uTracer has been updated.

he's open to suggestions -- one of which I pass along -- allowing Vg2 to be a mathematical function of Vak -- for modeling ultralinear operation. Thus Vg2= k + 40% Vak where k is a constant.

i anxiously await V4 which should be able to test higher voltages and higher currents.
 
Ex-Moderator
Joined 2011
I did not know that with Nick Barton's alternative UI, one could generate SPICE model directly with the uTracer until reading Kevin's post above, I think with some work, it could generate Ayumi's models as well. So I am too looking forward to the release of V4 of uTracer.
 
Please take a look at Robert's post above. It gets very good results for pentodes and most tetrodes.

It look good for Hifi applications. Now, saturated guitar amplifiers have a functionment that is something in between class B and class C. That imply, when a tube is saturated, Ig1, Ig2, and the Ig2 on Ia interaction must be modelized. Before to find that paper with the model based on the constant current curves, I first try to start from the Koren model, and add parametrs to it. I get a model that was very complicated with a lot of parameters, and it was still necessary to add new parameters in order to get a better fit, mainly with the Ig2 on Ia interaction. So, I gave up with it. I also try to modify the Koren model by modelizing Ik and determine the other currents by substraction. It lokked very simple to start with, but at the end, this gave me the same complexity for a not better result. So I also gave ip with it.

Also, to draw a good SPICE model for the tetrod/pentod, to start from the constant current curves will simplify the model, because the internal tube parameters vary less for a given current than for a given voltage. It is also why I want to try it. The 807 have the same electrical caracteristics than a 6L6. The electrical differences between these 2 tubes are their limits. A 807 can handle 600 Ua and 300V Ug2, when most 6L6 will have big problems with more than 450-500 Ua. But for the SPICE model, LTspice or ng-spice will not explose and the same model can be used for both tubes.

So, it would be great to have a Robert's model for the 807 or 6L6. That in order to be able to compare it with the other models, inclusive the one I will made. But this is nothing urgent, because I am very busy, a lot of urgencies that must be solved, and I just don't have any time for development right now.
 
Last edited:
.model 5Y3 D(Is=1e-2 RS=180 Cjo=20p vj=2 N=400 bv=1400 mfg=Stephie type=vacuum ) .model 5R4 D(Is=1e-2 RS=150 Cjo=30p vj=2 N=305 bv=3100 mfg=Stephie type=vacuum ) .model 6X4 D(Is=1e-2 RS=121 Cjo=20p vj=2 N=256 bv=1250 mfg=Stephie type=vacuum ) .model 5U4 D(Is=1e-2 RS=103 Cjo=30p vj=2 N=250 bv=1550 mfg=Stephie type=vacuum ) .model 6AL5 D(Is=1e-2 RS=60 Cjo=5p vj=2 N=128 bv=330 mfg=Stephie type=vacuum ) .model 5AR4 D(Is=1e-2 RS=36 Cjo=30p vj=2 N=80 bv=1500 mfg=Stephie type=vacuum ) .model 0A2 D(Is=10u Rs=50 Cjo=10p nbv=147 bv=150 Ibv=20m Vpk=150 mfg=Stephie type=zener ) .model 0A3 D(Is=10u Rs=30 Cjo=10p nbv=72 bv=75 Ibv=20m Vpk=75 mfg=Stephie type=zener ) .model 0B2 D(Is=10u Rs=33 Cjo=10p nbv=105 bv=108 Ibv=20m Vpk=108 mfg=Stephie type=zener ) .model 5651 D(Is=1u Rs=1k Cjo=1p nbv=84 bv=85.5 Ibv=2.5m Vpk=85.5 mfg=Stephie type=zener )[/QUOTE said:
In preamp just practically checked Mullard GZ30. Good spice model.

.model GZ30 D(Is=1e-2 RS=56 Cjo=30p vj=2 N=80 bv=1400 mfg=Mullard type=vacuum )
 
Ex-Moderator
Joined 2011
So, it would be great to have a Robert's model for the 807 or 6L6. That in order to be able to compare it with the other models, inclusive the one I will made. But this is nothing urgent, because I am very busy, a lot of urgencies that must be solved, and I just don't have any time for development right now.

Robert's methodology only optimizes the plate characteristic so far, the screen characteristic is based on Koren's equation (which is still less than accurate). So you may want to look at Ayumi's 6L6 model to see if it meets your expectation. Below is his model for LTSpice:

Code:
*
* Generic pentode model: 6L6
* Copyright 2003--2008 by Ayumi Nakabayashi, All rights reserved.
* Version 3.10, Generated on Sat Mar  8 22:40:38 2008
*           Plate
*           | Screen Grid
*           | |  Control Grid
*           | |  |  Cathode
*           | |  |  |
.SUBCKT 6L6 A G2 G1 K
BGG   GG   0 V=V(G1,K)+0.91804059
BM1   M1   0 V=(0.10751078*(URAMP(V(G2,K))+1e-10))**-1.743575
BM2   M2   0 V=(0.4624527*(URAMP(V(GG)+URAMP(V(G2,K))/4.9999386)))**3.243575
BP    P    0 V=0.0016883841*(URAMP(V(GG)+URAMP(V(G2,K))/10.811784))**1.5
BIK   IK   0 V=U(V(GG))*V(P)+(1-U(V(GG)))*0.0021948901*V(M1)*V(M2)
BIG   IG   0 V=0.0022135943*URAMP(V(G1,K))**1.5*(URAMP(V(G1,K))/(URAMP(V(A,K))+URAMP(V(G1,K)))*1.2+0.4)
BIK2  IK2  0 V=V(IK,IG)*(1-0.4*(EXP(-URAMP(V(A,K))/URAMP(V(G2,K))*15)-EXP(-15)))
BIG2T IG2T 0 V=V(IK2)*(0.942171668*(1-URAMP(V(A,K))/(URAMP(V(A,K))+10))**1.5+0.057828332)
BIK3  IK3  0 V=V(IK2)*(URAMP(V(A,K))+2180)/(URAMP(V(G2,K))+2180)
BIK4  IK4  0 V=V(IK3)-URAMP(V(IK3)-(0.00056920996*(URAMP(V(A,K))+URAMP(URAMP(V(G2,K))-URAMP(V(A,K))))**1.5))
BIP   IP   0 V=URAMP(V(IK4,IG2T)-URAMP(V(IK4,IG2T)-(0.00056920996*URAMP(V(A,K))**1.5)))
BIAK  A    K I=V(IP)+1e-10*V(A,K)
BIG2  G2   K I=URAMP(V(IK4,IP))
BIGK  G1   K I=V(IG)
* CAPS
CGA   G1  A  0.6p
CGK   G1  K  5.7p
C12   G1  G2 3.8p
CAK   A   K  5.9p
.ENDS
 
Last edited:
Robert's methodology only optimizes the plate characteristic so far, the screen characteristic is based on Koren's equation (which is still less than accurate). So you may want to look at Ayumi's 6L6 model to see if it meets your expectation. Below is his model for LTSpice:

Thank you, I will test it when I get some time. Does he have a model for the EL84/6BQ5?
 
So, it would be great to have a Robert's model for the 807 or 6L6. That in order to be able to compare it with the other models, inclusive the one I will made. But this is nothing urgent, because I am very busy, a lot of urgencies that must be solved, and I just don't have any time for development right now.

Dominique_free, I could probably put a 6L6/807 model together fairly quickly, but after modelling a number of different tubes, I've decided that I need to revise the "Frc" part of the model. The problem is that the curve fitting function veers off quite badly if you use grid voltages beyond the range over which it was fitted. Because of this, I don't want to be posting new tube model parameters when the underlying model may have to change.
 
Administrator
Joined 2004
Paid Member
I'm a little puzzled with the quality of pentode models in spice. I used the uTracer to curve trace eight 6ж9п today and selected one that seemed to match the published curves reasonably well and generated a spice model from it using the alternate gui.

Testing in LTSpice confirmed that it did not match the measured curves closely at all. Extensive tweaking over the course of several hours got me something that looks plausible, but I don't trust it.

I subsequently used the trace from one of the tubes to generate a model using paint_kip, and was able to get a good match in the tool, but when I tested it in LTSpice again the results were not great, although much better than the untweaked model I generated using the uTracer.

Is it that these models just don't do a good job with high transconductance pentodes or as I now suspect with pentodes in general?

I did a quick sloppy trace using paint_kip and generated a model, I then added this model to my LTSpice tube library and tested it, as you can see they do not match at all. (See attachments)
 

Attachments

  • 6J9p-capture.png
    6J9p-capture.png
    150.3 KB · Views: 1,288
  • 6j9p4-ltc trace.png
    6j9p4-ltc trace.png
    20.2 KB · Views: 1,265