Canadian TV, Computing and Home Theatre Forums banner

Get Build Measurements from NEC data with 4nec2

32K views 43 replies 14 participants last post by  300ohm  
#1 · (Edited by Moderator)
This has kind of bothered me for a while, ie drawing out the measurements for use by anyone. There are so so many models ! It seems like the simplest solution may be is to go right to the source. I dont really think its that hard. (at least in Windows XP, Im having my son work on the Linux solution, heh)

  1. Download and install the excellent free forever 4nec2 program from Arie Voors site at http://home.ict.nl/~arivoors/
    • also download and install the 4nec2 3d extension if you have any kind of recent video card at all, which Im sure you must, heh
  2. In the Main Tab, click Settings option, make these adjustments:
    • set Char-Impedance to 300 (actually this is optional)
    • set Length unit to feet, inches or meters, what ever you prefer to use.
    • set Radius unit to inches/AWG or Millimeters, what ever you prefer to use.
    • set to Geometry edit
  3. Copy and paste the NEC code data that is posted to a .txt file.
  4. Rename the .txt file to a .nec file (ignore the warning, heh)
  5. In the Main Tab, File > Open 4nec2 in-/output-file (name of the renamed .txt to .nec file)
  6. In the Main Tab, click Edit > Input(.nec) file. (that .nec file)
  7. In the Geometry Edit screen, choose either 3D, XZ,YZ, or XY button depending on the view of the antenna you want.
    • Note: in the 3D view you can twirl the antenna around holding the left mouse button down and moving it.
  8. Click on the antenna element in question. To the right will be shown the Length and Wire Gauge or radius of the element.
    • You can also quickly deduce the spacings.
It really is that easy!

By using this method, the models on this forum can be shown in a whole new light for typical users.
 
#3 ·
Yeah, angle degrees still have to be worked out with math, but at least the xyz positions are shown. I guess you could hold a protractor up to the screen to get the angles.

Thanks for formatting my post Stampeder. It is tricky to do, I never know how this bulletin board is going to handle things, heh.
 
#26 ·
Yeah, angle degrees still have to be worked out with math, but at least the xyz positions are shown. I guess you could hold a protractor up to the screen to get the angles.

You shouldn't have to work it out, as NEC does this for you.

The raw data that the NEC engine outputs, contains the orientation of each segment in angles, under the section labeled "SEGMENTATION DATA"

I'm not familiar with the operation of the 4nec2 program (it will not work on my computer), but there should be a function that will allow you to look at the raw output. Then just scroll down until you see it.

Maybe someone more familiar with the program can follow up with further instructions. Or even send a feature request to the 4nec2 author to make the angle determination a little more user friendly.
 
#4 ·
Pictures can be more helpful than words,

This refers to step 2, set Char-Impedance to 300 (actually this is optional)
Image


This refers to step 2, set Length unit to feet, inches or meters, what ever you prefer to use.
Image


Note that set to Geometry edit is checked.
 
#5 ·
This refers to step 2, set Radius unit to inches/AWG or Millimeters, what ever you prefer to use.
Image

Note that Geometry Edit is checked.

This refers to step 5, In the Main Tab, File > Open 4nec2 in-/output-file (name of the renamed .txt to .nec file)
Image
 
#6 ·
This refers to step 6, in the Main Tab, click Edit > Input(.nec) file. (that .nec file)

Image


And finally this refers to steps 7 and 8. When you click on an element it will turn red indicating it was selected.

Image


Note the length of the element is shown in the lower right hand corner. The radius is shown about middle right. In the 4nec2 help file, F1, under contents, under Reference Data, there is an AWG wire table that will show you the wire gauge per the radius size.

Dont be afraid of messing anything up by trying some other options. Nothing will be changed unless you save the file. In that case, you can always repeat steps 3 and 4 to get another clean copy.
 
#7 ·
300ohm: I tried to grab X036 from WUALA, but I get CM a error(did I loose spaces/ with CM cards deleted same error)[ I liked the IBM cards, the holes would not move]. All so how do you step thur the frequency on (F4) pattern. That is what you get with a pea brain just more questions.
 
#8 ·
Ahh good, youre ready to graduate to the modeling thread. I knew you would be. I envisioned this thread for the ultra simple usage, so no one would have to toil over tedious sketching with graph paper.

The F4 pattern is the 2D radiation pattern for a single frequency on most of my models. You can change between horizontal and vertical pattern by hitting the space bar (you must click on the F4 pattern first so its highlighted). You can also steps thru the degrees with the arrow keys. Hitting F9, the 3D view, and choosing "multi-color" will give you a 3D radiation pattern.
However, on firimani's X032 model, because of the way he set up his RP card, you CAN step thru the F4 frequencies with the arrow keys. (I like that, so Ill probably start doing that also in some cases) You wont get a vertical pattern that way though, or the nifty 3D pattern.

But first a frequency sweep output must be generated. On firimani's X032 model, just hit F7 and use "original file", then click Generate and wait a few minutes.
On most of my models, if there isnt a F4 pattern already, just hit F7, choose Far Field pattern, input the Frequency desired, choose Full, and click Generate.
 
#9 ·
I used a method close to that for making a file that I could import into a CAD system. Most of info near the end .nec file is already basically in ASCII format it just needs a bit of editing to be imported into cad. If you want a more detailed description I can make one but its mostly just for cad users.

Desktop screenshot (dual monitors)

BTW I have found most of the models here the zig-zag driven elements are not 90 deg bends but something close...(normally within a 1/4 of a degree of 90)... I guess that must come from optimizing?
 
#10 ·
I guess that must come from optimizing?
Nah, mostly from rounding or trying to put it on a grid line. Anything closer than .1mm or .01 inch is going to be a just little tough to build anyway, heh heh. Copper and aluminum may expand and contract that much. At least thats what I blame it on if the measurements in my builds are off. :)
 
#11 ·
Also, important for getting measurements from 4nec2, is to think in 3D terms.

By convention the coordinates are:

The Z axis is up and down.

The X axis is towards the transmitting station and away from it.

The Y axis is broadside to the station.
 
#14 ·
Perhaps...

This matter and one other could be incorporated into a Sticky - 4NEC2 Basics and Standards.

I was (and am) often frustrated when a .nec run does not match what was posted. Of course, mostly this is due to my ignorance, but still there is no 'standard' set of parameters to ensure apples-to-apples comparisons.

Could there not be an "agreed" set of values and if a variance is needed, that it be clearly marked in the model?

Thoughts?
 
#15 ·
I was (and am) often frustrated when a .nec run does not match what was posted.
This probably belongs in the modeling thread. (this thread is for the simple displaying of nec data with 4nec2)

The only occurance Ive found where a .nec run does not match what was posted (significantly) is where the AGT was not adjusted for 1.0 (0db) or having Auto-Segmentation set in the 12 to 16 range for UHF. Ive been using an Auto-Segmentation setting of 21, and I note that setting in the nec file comments.
 
#18 ·
Does it have to be adjusted to exactly 1.0 ? Are we allowed to be off by anything at all ?
Heh. When doing a single frequency calculation for yourself, you can add or subtract the db figure in the parenthesis. But if youre posting it for someone else, then it should be as accurate as you can make it, or make a note of it in your posting.
For frequency sweeps and gain charts, you can see how all that adding or subtracting can be a real nuisance, so you would want it adjusted accurately, AGT = 1.0 (0db).

If you get a db figure like (4-e6 db), thats so tiny that for all practical purposes its 0.

Actually, both this question and the one above it belong in the modeling thread. This thread is more for simply getting measurement data from the models for use in building the antennas. I would like to keep this thread simple, and use the modeling thread for more involved questions, if you know what I mean.
 
#19 ·
Using tubing instead of wire does not affect anything modeling wise does it? It acts the same as solid wire right?
Correct. As far as Ive read, receiving antenna radiation only takes place on the skin. Receiving antennas only deal with very very low volts and milliamps.
If putting a lot of voltage and current on a transmitting antenna, then things change, heh.

Regarding your previous questions on impedances and mismatches, Ken Nist, HDPrimer.com has a good simple write up on it here:
http://www.hdtvprimer.com/ANTENNAS/GlossaryG.html#mismatch
 
#20 ·
NEC models have been used to design & build thousands and thousands of different
antennas....many of them using tubular aluminum elements (e.g. Yagi's). The accuracy
of the NEC models have been extensively researched, including estimating the minor
corrections needed when converting from a NO-BOOM NEC design to a REAL-METAL-BOOM,
with either above-boom, top-of-boom, thru-boom or insulated tubular element mounts.
 
#22 ·
Image


When you click on a wire in 4nec2 Geometry Edit :

The green circled area shows you the length of the wire.

The red circled area shows you the X, Y, Z coordinates, in that order, XYZ.

The blue circled area allows you to change viewing angles.
Drawn in the conventional manner :
XZ = Side View
YZ = Front View
XY = Top View
 
#23 ·
I'll use jedsofts GH10 as an example

1. Is there a way to print out on one page the antenna design on a 1' grid
Yes. Follow the directions above.

Looking at post number 6 on the Geometry Edit screen, selecting XZ,YZ or XY will give you a grid. Then set the zoom slider to what size grid you want.
Then use a free screen capture utility like swbcap20 or SnapShot to capture the active window. :)
 
#24 ·
The "nec" editor works the same way

If you pretend you want to edit the input file then close the window without
making any changes the geometry window gives you the same info (click on a wire and it pops up a window with the info on that wire like length and the end points , no angles though ) and there is less chance of accidentally altering
the model you are working with because the editor is only open for a second or two. I don't remember if the NEC editor is the default or not.
 
#27 ·
The raw data that the NEC engine outputs, contains the orientation of each segment in angles, under the section labeled "SEGMENTATION DATA"
Not really. Heres part of an output file, "SEGMENTATION DATA" section :

Code:
                                 - - - - SEGMENTATION DATA - - - -

                                        COORDINATES IN METERS

                         I+ AND I- INDICATE THE SEGMENTS BEFORE AND AFTER I


  SEG.   COORDINATES OF SEG. CENTER     SEG.     ORIENTATION ANGLES    WIRE    CONNECTION DATA   TAG
  NO.       X         Y         Z       LENGTH     ALPHA     BETA      RADIUS    I-   I    I+    NO.
     1   0.08451   0.00011   0.03175   0.00762    0.00000   0.00000   0.00260    -2    1    5      1
     2   0.08070  -0.00518   0.03175   0.01058    0.00000 -90.00000   0.00260    -1    2    3      2
     3   0.08070  -0.01577   0.03175   0.01058    0.00000 -90.00000   0.00260     2    3    4      2
     4   0.08070  -0.02635   0.03175   0.01058    0.00000 -90.00000   0.00260     3    4   46      2
     5   0.09594   0.00011   0.03175   0.01524    0.00000   0.00000   0.00260   -51    5    6      3
     6   0.11118   0.00011   0.03175   0.01524    0.00000   0.00000   0.00260     5    6    7      3
     7   0.12642   0.00011   0.03175   0.01524    0.00000   0.00000   0.00260     6    7    8      3
     8   0.14166   0.00011   0.03175   0.01524    0.00000   0.00000   0.00260     7    8    9      3
     9   0.15690   0.00011   0.03175   0.01524    0.00000   0.00000   0.00260     8    9   10      3
    10   0.17150   0.00011   0.03175   0.01397    0.00000   0.00000   0.00260   -63   10   11      4
    11   0.18547   0.00011   0.03175   0.01397    0.00000   0.00000   0.00260    10   11   12      4
    12   0.19944   0.00011   0.03175   0.01397    0.00000   0.00000   0.00260    11   12   13      4
    13   0.21341   0.00011   0.03175   0.01397    0.00000   0.00000   0.00260    12   13   14      4
Wire number 2, when looked at in the XZ perspective, is about 30 degrees from the 0 point. Instead its telling me its 90 degrees. It is 90 degrees from the X coordinate, but thats not the angle Im after.
 
#28 ·
In post#20 above, just below "Length" (circled in green) was a Theta & Phi angle readout.
You can change this to Azimuth & Elevation (which is more intuitive) via SETTINGS, "Phi/Azim units".

However, it appears that the displayed angles are relative to the wire STARTING point,
so the polarity of the angle may be reversed...use GeoEdit to verify whether pos or neg.