|
|
|
java -jar paint_kit.jar <plate-curves-image>Here, <plate-curves-image> is a GIF or JPG image containing tube plate curves. There is plenty of images available on the web. For starters, Audiomatica contains a good selection of most popular audio triode curves. For example, we'd like a model for 6sn7 matching Audiomatica's curves. First, download 2a3crv.gif and do
java -jar paint_kit.jar 2a3crv.gif
|
Here is a typical session. The horisontal bars are the sliders. The sliders are high-precision and automatically readjust: when you hit a left margin of any bar, the slider scales 1/2, if you hit the right margin, it switches to a 2x scale. After a good match found, you can press the [report] key to print out a working model definition, or press [Exit] to print out the final model definition and exit. Button [Color] changes the color of the model curves.
|
Here is another session - 12B4A.
|
RCA-published curves for the 26 triode are difficult to match well, yet a good fit is found.
|
Painted over the image, you should see a small red gridbox with tube curves in it. This is the model. Moving the sliders will affect the curves in the small red box in realtime.
Your next task is to align the red box and the axis of the plot. You can do that using the mouse, by "rubber-bending" the red box. First, position the mouse precisely over the 0,0 point on the plate plot and press mouse without releasing it. The small red box disappears. Then drag the mouse (move it with the button still pressed) in the direction of the Imax, Vmax point on the image. You'll see that the small red box appears again, growing in size in real time as you drag its max, max point with the mouse. position the mouse at the diagonal point where you wan the plots aligned an release the button. The plot coordinates are geometrically aligned now. Repeat the whole click-drag-drop procedure if the alignment is not precise.
After you've aligned the planes, do not click the mouse when it is hovering over the image, it will shrink the box again.
if the color of the model lines (default red) collides with the image, use button [Color]. Pressing it iterates over a selection of various colors (red, yellow, black, etc).
Now you need to calibrate the model plane. type the values of the Vmax, Imax and grid voltage step in the text box area. For the 6sn7 image from Audiomatica, you need to enter 500, 20, 2. Of course, if you did not drag the model box all the way to 500v,20ma marks, you'll have to enter different values. Note that there is no need to enter a negative sign for grid voltage. Press return when in the box, you'll see that the model re-scales. It is not calibrated in sync with the image plot.
With little practice, the above steps take just a couple of seconds of time. Now you are ready to start finding tube parameters. At this point, chances are that the image and the model lines are a complete mismatch.
Now you can pay closer attention to the sliders. The sliders are "smart": they rescale "infinitevely". Each slider re-scales when you move the control all the way left or right. . For example, initially the MU slider covers the range from ~ .5 to 10, but after you move it to the left corner, it will re-scale to cover ~ 1 .. 20 range, and if you bump it twice again it will readjust to 4 .. 80 range. Each slider does that in a similar way. This allows to always maintain a good precision yet does not lock a slider in a particular range. Try moving the sliders. Watch the shape of curves changing.
Now you are ready to start fitting parameters. Finding the best parameter fit is a hard task at the beginning, but will be easy after little practice. It is absolutely critical to develop a feel of each parameter. Knowing what each parameter does helps to shape the curves very quickly. Below is a little cheat-sheet explaining the impact of each slider.
Recommendations for adjustment strategies. First, find the right MU (distance alone X between first 2-3 curves) then adjust KG1 to get the idea about the curves. Adjust EX to get the best "curving" of most lines, adjust KG1 and MU again. Then try KP. after that, you may want to try KVB and VCT. Remember that the way how you iterate affects the shape of the curves, and that be developing a feel of how the parameters affect the shape you can beat the results of automatic optimizers.
If you think you need to preserve an interim model result, press [Report] button, and the tool will print out the model.
When you're found the best result, generate the final model text and exit by pressing the [Exit] button.
An example of the tool's output:
*********************************************************************
* Created on Thu Dec 11 16:31:24 PST 2003 using tube.model.finder.PaintKIT
.SUBCKT TRIODE_12B4A 1 2 3 ; P G K ;
+ PARAMS: CCG=3P CGP=1.4P CCP=1.9P RGI=2000
+ MU=7.518 EX=1.344 KG1=390.0 KP=45.0 KVB=930.0 VCT=0.328
* Vp_MAX=500.0 Ip_MAX=0.07 Vg_step=10.0
E1 7 0 VALUE={V(1,3)/KP*LOG(1+EXP(KP*(1/MU+V(2,3)/SQRT(KVB+V(1,3)*V(1,3)))))}
RE1 7 0 1G
G1 1 3 VALUE={(PWR(V(7),EX)+PWRS(V(7),EX))/KG1}
RCP 1 3 1G ; TO AVOID FLOATING NODES IN MU-FOLLOWER
C1 2 3 {CCG} ; CATHODE-GRID
C2 2 1 {CGP} ; GRID=PLATE
C3 1 3 {CCP} ; CATHODE-PLATE
D3 5 3 DX ; FOR GRID CURRENT
R1 2 5 {RGI} ; FOR GRID CURRENT
.MODEL DX D(IS=1N RS=1 CJO=10PF TT=1N)
.ENDS
*$
A small yet groving repository of "good matches" can be found in [8]. Frequently you want to set the parameters to values corresponding to some model - to check how it fits a plot, for example, or to continue frome a save-point data. Earlier we described how the text box can be used to calibrate the model grid with 3 space-separated values Vp_MAX, Ip_MAX, Vg_step. Same text box can be used to set MU, KP and any slider parameter. The format is the same that ise used in SPICE, so that you can simply cut&paste the value from SPICE lib files or your own saved model data (as dumped by the [Report] and [Exit] buttons). For example, the follwing sets MU, KG1, etc to the values matching the TRIODE_12B4A model:
MU=7.518 EX=1.344 KG1=390.0 KP=45.0 KVB=930.0 VCT=0.328
If you look closely, you'll see that the model definition contains a comment line
* Vp_MAX=500.0 Ip_MAX=0.07 Vg_step=10.0
this is another way to set the 3 calibration parameters. Thus,
MU=7.518 EX=1.344 KG1=390.0 KP=45.0 KVB=930.0 VCT=0.328 Vp_MAX=500.0 Ip_MAX=0.07 Vg_step=10.0
sets the sliders and calibrates the model plane.
Go here to learn how it works.
paint_kip.jar Koren Improved Pentode Model
paint_ppt.jar Stefano Perugini Polynomial Ex(Ep) Triode model
paint_pexgt.jar Polynomial Ex(Eg) Triode model
[2] http://www.next-power.net/next-tube/data.php3 NextTube data page
[3] http://www.klausmobile.narod.ru/testerfiles/index.htm Klausmobile T-files
[4] http://digilander.libero.it/teodorom/Simulations/TriodeExcel.htm Excel image-to-table tool
[5] http://www.normankoren.com/Audio/Tube_params.html Norman Koren tube parameters
[6] http://tdsl.duncanamps.com/ Duncan Amp's tube data
[7] http://home.planet.nl/~frank.philipse/frank/frank.html Frank's Tube Pages
[8] models-gallery.htm A collection of good matches done with my Paint* java tools, screenshots as well as model text ready to be copied into your SPICE .lib files are provided. Please send me your findings for inclusion.