Simulating Transformers in 4nec2


Unlike the EZNEC, the 4nec2 simulator does not have a transformer object you could place in the antenna model. In the simple antenna models, this is not a problem at all. If you want to feed your antenna with 50-ohm coax and 1:4 balun to match its feed point impedance, you can simply change the source impedance in your model to 200 ohms and that's it. The problem may arise though when you want to model a system of two or more antennas with different feed point impedance and fed with a single coax. In such situation, you need transformer(s) in your model to find the SWR at the coax connected to the antennas.

Fortunately, there is a solution. The 4nec2 simulator supports the NT-card defined by NEC-2. This allows you to enter a card (a line in the antenna model file) containing a 2-port network described by its admittance matrix Y.

For the reciprocal 2-port networks, Y12=Y21. The networks built with passive components only are usually reciprocal, and such networks are supported by 4nec2 simulator. That’s why it requires us to input only Y12 and assumes that Y21 is the same. The figure below shows a transformer model you can use in the 4nec2 to simulate real transformers (baluns or ununs).

I prepared an Excel spreadsheet with a number of most typical K values and the corresponding Y11, Y12 and Y22 values. I assumed Rout equal to 0.1 ohm, so it is an almost ideal lossless transformer. Note that you can not use Rout equal to zero by you may use arbitrary small value.

I also assumed that the output impedance is purely resistive and the primary-to-secondary ratio K is a real number (not a complex one). This resulted in all imaginary parts of Y11, Y12 and Y22 being equal to zero. 

If you download the Excel file, you will be able to enter your value of K in the very last line of the table and get the right Y values. You can also change the Rout value, what influences the Y values as well.

Once you know the Y values, you can open the Nec Edit window in the 4nec2 (by pressing Ctrl+F2) and insert the NT card in the antenna model file as shown in the example below.

Please note that the 4nec2 will NOT show you any transformer symbol in the antenna view(s) but it will include it when calculating the whole model performance.

Click here to download the spreadsheet.