: 4nec2 & Other Antenna Design Modeling Software


Pages : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 [44] 45

300ohm
2012-01-08, 01:02 PM
I was trying to do a 36 inch wide by 2 foot on each panel using 2 x 4 inch mesh.
Here ya go, its deceptively simple, heh.

CM Corner Reflector using SM and SC cards by 300ohm
CM Basic Corner Reflector
CM SM panels
CM Density = 2 inch by 4 inch mesh
CM Size = 36 inch wide by 24 inch high panels
CE
SM 12 9 16.9706 -18 16.9706 0 -18 0
SC 0 0 0 18 0
SM 12 9 0 -18 0 16.9706 -18 -16.9706
SC 0 0 16.9706 18 -16.9706
GS 0 0 0.0254 ' All in in.
GE 0
GN -1
FR 0 1 0 0 585 0


but I was trying to grasp the SM and SC cards.
Basically, youre defining each of the X, Y, Z coordinates of the top left, bottom left, bottom right corners of a rectangle, which makes up the outside dimensions of 1 panel. Thats done with one SM and SC card combo. The SM card describes the top left and bottom left coordinates, while the SC cards describes the bottom right coordinate. You need two combos for the two panels of a corner reflector.
And you define how each panel is split up, vertically and horizontally, which is your mesh size.

The easiest way to get the coordinates is to make a wire model first, which you should do anyway at the end of optimizing for finer accuracy. SM/SC cards are accurate enough for the quick calculations and optimizations though.

In the above example, the +/- 18 numbers are the width of the panel, the Y coodinates, making 36 inches. The +/- 16.9706 numbers are the X and Z coordinates of the 24" panel height, which are the same number (1/2 of (24 * SQRT 2)) because its a 45 degree angle. The 0 number is at the apex.
There are twelve 2 inch sections in the 24 inch height, and nine 4 inch sections in the 36 inch width.

Surface patches are not usable in Geometry Edit, so you have to enter them thru NEC Edit.

kc2cbd
2012-01-08, 04:46 PM
Thanks 300ohm I think I understand it better now.
Couldn't seem to grasp it from Cebik's (W4RNL) article.
I did get the right hand rule, just couldn't figure out where the coordinates came from.
Thanks again!

300ohm
2012-03-06, 11:57 PM
Hmm, 4nec2 wont open in the Windows 8 evaluation preview, 64-bit version. Will have to try the 32-bit version much later.


Other than looking like a iPad barfed all over my desktop, it seems to run pretty snappy. :)
But then again, its a clean install.

holl_ands
2012-03-07, 12:51 PM
300ohm: Just an FYI for future posts:

I tried to print out a hard copy of your Surface Patch description using "PRINT/Selection"....
but I had to SHRINK it to 50% of full size before I could "see" the right side of the post...
but at that size I really couldn't "see" it very well at all---way too small.

I'm using Firefox on a wide screen monitor.
I don't know what sort of settings you are using...must be on very
wide screen monitor....but it's just TOO many chars/line...and
Firefox isn't shrinking the number of chars/line for narrower widths.

300ohm
2012-03-07, 04:58 PM
Hmm, Im using Firefox too (except right now Im playing with Win8 since last night only) on a dual monitor setup that displays the same on both monitors. One monitor is an Acer 19" 1400 X 900 and the other is I-INC 25" 1920 X 1080. I never have tried to print a page from here though. :confused:


Did you catch the memo from Hugh a few months back about the changes in this forums default display size in settings ?

When I say memo, I mean the little notes/links at the top of the page he used to post.

Edit: The selection is at the very bottom of the page. Right now I set it to "Digital Home Fluid". I had it on "Digital Forum Narrow" before.

========================================
Hmm, 4nec2 wont open in the Windows 8 evaluation preview, 64-bit version.
Specifically, it says "Program cant start because dx8vb.dll is missing from your computer".
No backward DirectX compatibility in Win8 ?

300ohm
2012-03-08, 09:06 PM
Yay, 4nec2 works fine in Windows 8 64-bit using the installer on 5.8.8. :D:p

The first time I tried it, Win 8 gave me the big message that it was trying to prevent serious harm to my computer. So I tried to install going the extract zip route and that gave me errors with the dll's not registering.

I tried the installer again, and this time clicked on the "more info" line and it gave me the option to "Run Anyway", so I did and it worked fine.

The Metro (sexual ?) interface is just so different and weird than anything before. Theres going to be a fairly long learning curve just to do stuff you could easily do before. And a lot of customization. And not just for novices either. :rolleyes:
Even shutting down the computer takes more moves than before. I installed a Vista shut-down gadget on the desktop to take care of that little nuisance, heh.

But so far, it seems to be running very smooth, snappy and stable on my machine. IE10 seems pretty snappy too. :) Overall, everything seems to be a bit snappier with Win 8 64-bit versus winXP 32 bit, once I cut thru the crap.

Its very surprising, because MS claimed Win98 ran faster than Win95. They lied. They claimed Win ME ran faster than Win 98, they lied again. They claimed WinXP ran faster than win98, not really true. They claimed Vista was faster than XP, an out and out lie. They claimed win 7 was faster than Vista. Partial truth.

dasemesti
2012-05-17, 12:56 AM
Hey all guys interrested in antennas!

Modelling different antennas in 4nec2 i wonder which parameter given by the software will indicate the following very important result:

The incoming radio waves are actually converted to voltage/current and presented at the cable connector to the receiver. The bigger quantity the better.

Is it gain? Or efficiency? Or aperture efficiency (can't see it in 4nec2)?
Or some combination of all those above?

What would indicate in the 4nec2 that a small radio wave incoming uniformly from one direction is catched in "bigger quantities" overall by a bigger antenna than by smaller one, even if the directivity of both are the same?

Sorry for being so plainly practical, but the end result is important, isn't it?

Appreciate all your ideas

300ohm
2012-05-17, 01:37 PM
What would indicate in the 4nec2 that a small radio wave incoming uniformly from one direction is catched in "bigger quantities" overall by a bigger antenna than by smaller one, even if the directivity of both are the same?

If two antennas have exactly the same net gain, then the one with the higher horizontal and vertical beamwidth would be "catching" more overall waves.
http://en.wikipedia.org/wiki/Directivity

Correctly aimed, two antennas with the same net gain would have the same bottom line effect on the TV tuner. The one with the wider beamwidth would be easier to aim. But in some multipath cases, the narrower beamwidth one would be preferred.

Dave Loudin
2012-05-17, 01:59 PM
Remember that VSWR is the indication of how much RF energy captured by the antenna will be delivered into a transmission line. Wouldn't Net Gain be the best "quality" value to focus on?

300ohm
2012-05-17, 02:20 PM
Wouldn't Net Gain be the best "quality" value to focus on?
Yep, and for digital you would want the SWR to be less than around 2.7 : 1, no matter the Net Gain. ( In other words, you can have high SWR and still have a high Net Gain. Net Gain is Raw Gain minus the SWR mismatch loss. )

A lot of the old commercial TV antennas had SWRs of over 3.5, which was OK for analog, as it affected only the net signal strength and not so much the picture quality. With digital, high SWR can effect the signal waveform and data, causing pixelation.

holl_ands
2012-05-17, 05:30 PM
Raw Gain (as calculated by 4nec2) determines the amount of Power delivered to a
MATCHED Impedance (e.g. RLC Network) connected across the antenna terminals:
http://en.wikipedia.org/wiki/Impedance_matching

Note that in RF systems, we worry much more about POWER transfer
than trying to maximize VOLTAGE (by choosing a very high load resistance).
Indeed, in a matched load situation the voltage generated by the source
is divided EQUALLY across the Source and Load Impedances.

Maximum Power is delivered to this Load when the complex impedance
of the Load is the CONJUGATE of the Source Impedance...which could
mean adding a Capacitor(s) to the Load to cancel Inductance in the
Antenna (see Load Matching function in 4nec2). Of course, with
a well designed antenna with a low SWR, this is not needed, which
is fortunate for us, since RLC matching networks are inherently
narrowband, which is good for Ham Radio Transmitters and bad for
very wideband TV Receive Antennas.

Net Gain is a measurement of the MAXIMUM amount of loss that COULD
occur in standing wave NULLS, equally spaced along the length of the Coax.
If Coax electrical length happens to be a multiple of the half-wavelength
on a particular channel, then the user could experience the Maximum Loss...
however, on most channels, users will never come close to experiencing
Net Gain.....and if they did have a problem on a weak channel...insert some
short lengths of coax to "move" the Null(s) to strong or unoccupied channels....

nikiml
2012-08-25, 12:30 PM
I have uploaded a new version (http://clients.teksavvy.com/%7Enickm/scripts.html#download) of the nec.opt scripts.
I has been almost year since the previous release so the list of changes may be incomplete, but here are the most important ones:


support for Python 3,
support for NEC/MP (http://users.otenet.gr/%7Ejmsp/)
fixed autosegmentation to work with TL and NT cards
changed the default parameters for the Differential Evolution
changed the way average of logarithmic values is calculated: before it was average(10*log(gain)), now it is 10*log(average(gain))
added support for ^ operator to calculate exponents

tripelo
2012-08-25, 04:02 PM
Net Gain is a measurement of the MAXIMUM amount of loss that COULD
occur in standing wave NULLS, equally spaced along the length of the Coax.

Suppose:

- There were a load (say preamp or receiver) with 75 Ohm input impedance and the transmission line (TL) characteristic impedance was ideal 75 Ohms.

- The antenna had an impedance different from 75 Ohms; say purely 150 Ohms real or resistive.

-----------------------

* Would there be standing waves on the TL, since all the power (delivered into the TL/load) from the antenna would be absorbed in the TL and the load (receiver)?

If there are no standing waves on the TL:

* Would there be reflected power at the antenna to TL junction because the mismatch between the antenna and the TL/load.?

If there is power reflected at the antenna/TL junction:

* Would there not be a difference between the "Raw" gain and the "Net" gain?

If Coax electrical length happens to be a multiple of the half-wavelength on a particular channel, then the user could experience the Maximum Loss...* Would changing the length of the line make any difference in the preceding example?

* Does the concept of "Net" Gain apply to the antenna and it's load, regardless of whether the TL has standing waves or not?

300ohm
2012-08-25, 04:18 PM
Does the concept of "Net" Gain apply to the antenna and it's load, regardless of whether the TL has standing waves or not?
Yes, it applies to the antenna and its "perfect" load impedance. The Raw Gain of the antenna minus its mismatch loss to a "perfect" load impedance of X is the Net Gain.

Transmission line losses are a separate issue. You have line losses due to length, and you can mismatch losses in the line itself, like for example if the coax is bent too sharp or you have twin lead going over a metal surface. Transmission line losses are not counted in either Raw or Net Gain of the antenna.

Mismatching the transmission line to match the antenna mismatch can be done. That's essentially whats going on in the old sliding aluminum foil over 300ohm twin lead trick. :)

holl_ands
2012-08-26, 11:35 AM
Suppose:

- There were a load (say preamp or receiver) with 75 Ohm input impedance and the transmission line (TL) characteristic impedance was ideal 75 Ohms.

- The antenna had an impedance different from 75 Ohms; say purely 150 Ohms real or resistive.

-----------------------

* Would there be standing waves on the TL, since all the power (delivered into the TL/load) from the antenna would be absorbed in the TL and the load (receiver)?

Only a portion of the power is absorbed by the TL (1-2 dB on a short length, 3-4 dB on a long length coax).
BTW: Power incident to the Load undergoes a single path loss, whereas a reflection undergoes THREE paths,
hence coax loss helps to reduce SWR. This effect is very rarely quantified, but is commonly used in RF labs
to isolate the effect of SWR on precision measurements:
http://emc.toprudder.com/vswr.pdf


If there are no standing waves on the TL:

* Would there be reflected power at the antenna to TL junction because the mismatch between the antenna and the TL/load.?

Although the 150-ohm antenna is feeding a 75-ohm TL, the interconnection
has zero length and hence there is no "instantaneously" small standing wave.
HOWEVER, the impedance presented to the 75-ohm load is NOT just the impedance of the TL....
it's the combination of the TL and the source load impedance (150-ohm). This difference is what
will cause reflections to be initiated AT THE LOAD. If no TL, then no standing waves,
which is one more reason why a mast mounted Preamp can be better if it isn't overloaded....


If there is power reflected at the antenna/TL junction:

* Would there not be a difference between the "Raw" gain and the "Net" gain?

* Would changing the length of the line make any difference in the preceding example?

* Does the concept of "Net" Gain apply to the antenna and it's load, regardless of whether the TL has standing waves or not?

Actually the power is reflected at the TL/Load junction. Net Gain = Raw Gain - Mismatch Loss.
Maximum Mismatch Loss is ONLY experienced at the positions of the NULLS.
Since standing wave nulls occur every 1/2-wavelength on the coax, on a particular frequency,
the end of the coax would only "see" that null if the total (electrical) length was a multiple of
1/2-wavelengths. So adding a length of coax of about 1/4-wavelength long would eliminate the
null being presented to the load. Of course, this could cause nulls being moved to other
channels, but if they had adequate gain margin, this might not be a problem.


These animations and explanations may help to understand SWR (aka VSWR):
http://www.bessernet.com/Ereflecto/tutorialFrameset.htm [Enter an SWR value, RETURN]
[Also note the check box to display THREE impedance example.]
http://www.microwaves101.com/encyclopedia/vswr.cfm
http://www.microwaves101.com/encyclopedia/vswr_visual.cfm
Also note you can REVERSE the order of components if it helps to visualize your situation.
By the Reciprocity Law, same argument applies if power is sourced from LOAD to antenna.

==========================================================
In ADDITION to the SWR Loss described above, there will be a MIS-MATCH Loss from
the antenna's 150-ohm impedance to the 75-ohm TL (terminated in a 75-ohm Load):
http://en.wikipedia.org/wiki/Maximum_power_transfer_theorem
This SWR value is what is plotted when we run 4nec2 simulations, presuming a Load and TL
(lossless, arbitrary length) with impedances equal to presumed characteristic impedance.

nezdepain
2013-05-10, 10:37 PM
Hi all,
I'm in my first steps with 4nec2. I'm using Meserve's site to generate a yagi with a design frequency of 521 MHz, I transfer the data into a nec file that I input into Nikiml's nec.eval script. First of all, it seems that the Net gain peaks at a higher frequency than the design frequency. In order to get a peak at 521 MHz with nec.eval, I have to use the measurements output by Meserve's script for a design frequency around of 505 MHz.
One thing that really needs some clarifications: I am getting different gain results when I run nec.eval with a full uhf sweep (470,6,39), compared with a shorter one:

python -m nec.eval "C:\4nec2\yagi509_DL6WU - proche de 17 avec corner reflector.nec" -s (506,6,8)
Input file : C:\4nec2\yagi509_DL6WU - proche de 17 avec corner reflector.nec
Freq sweeps: [(506, 6, 8)]
Autosegmentation: 10 per 2.11268


Freq RawGain NetGain SWR F/R F/B Real Imag AGT(corr)
============================================================ ====================
==
506.0 15.986 15.636 1.771 25.920 25.920 294.83 172.24 1.00( 0.004)

512.0 16.426 15.928 1.981 22.000 22.000 332.93 217.75 1.00( 0.004)

518.0 16.807 16.420 1.825 19.470 19.470 419.55 180.64 1.01( 0.023)

524.0 17.087 16.980 1.369 19.440 19.440 353.61 87.50 1.01( 0.023)

530.0 17.237 16.912 1.733 22.240 22.240 306.58 168.80 0.98(-0.107)

536.0 16.967 16.876 1.337 21.780 21.780 312.74 88.32 0.98(-0.107)

542.0 15.552 13.600 4.020 20.960 20.960 242.86 402.55 1.08( 0.338)

548.0 14.552 10.909 7.113 13.750 13.750 43.26 47.59 1.08( 0.338)


Compared to the full sweep:

U - proche de 17 avec corner reflector.nec"
Input file : C:\4nec2\yagi509_DL6WU - proche de 17 avec corner reflector.nec
Freq sweeps: [(470, 6, 39)]
Autosegmentation: 10 per 2.11268


Freq RawGain NetGain SWR F/R F/B Real Imag AGT(corr)
============================================================ ====================
==
470.0 13.299 13.021 1.664 28.500 29.880 266.24 141.47 1.00( 0.001)

476.0 13.709 13.430 1.666 28.210 36.010 279.55 147.93 1.00( 0.001)

482.0 14.149 13.869 1.666 27.860 33.000 295.59 153.52 1.00( 0.001)

488.0 14.599 14.339 1.636 27.790 28.680 312.62 151.70 1.00( 0.001)

494.0 15.069 14.846 1.577 26.890 27.390 318.74 140.81 1.00( 0.001)

500.0 15.529 15.299 1.587 27.180 27.750 304.86 140.91 1.00( 0.001)

506.0 15.989 15.639 1.771 25.920 25.920 294.83 172.24 1.00( 0.001)

512.0 16.429 15.931 1.981 22.000 22.000 332.93 217.75 1.00( 0.001)

518.0 16.829 16.442 1.825 19.470 19.470 419.55 180.64 1.00( 0.001)

524.0 18.044 17.937 1.369 19.440 19.440 353.61 87.50 0.81(-0.934)

530.0 18.064 17.739 1.733 22.240 22.240 306.58 168.80 0.81(-0.934)

536.0 17.794 17.703 1.337 21.780 21.780 312.74 88.32 0.81(-0.934)

542.0 16.824 14.872 4.020 20.960 20.960 242.86 402.55 0.81(-0.934)

548.0 15.824 12.181 7.113 13.750 13.750 43.26 47.59 0.81(-0.934)

300ohm
2013-05-11, 12:34 AM
First of all, it seems that the Net gain peaks at a higher frequency than the design frequency. In order to get a peak at 521 MHz with nec.eval, I have to use the measurements output by Meserve's script for a design frequency around of 505 MHz.

Yeah, but since the max gain point of a high gain yagi has a pretty steep drop off at the end, I personally would design for a few MHz below that to be safe in case of build errors or not taking into account boom corrections or other factors that I may not be considering at the time. A half a db in gain is not that bad of a trade off for design safety IMO. Also consider that its much easier cut off material to adjust for higher frequencies than it is to add material to correct for lower freqs.

nezdepain
2013-05-11, 09:20 AM
I don't mind taking a chance of falling off the peak.
Just by tweaking a little bit the sizes and distances (I mix the data output with ARRL and DL6WU parameters for the same design frequencies) I come with much more gain (around 20 dbi). How reliable is this? It's a 18 elements yagi. I already have one built for a designed frequency of 521MHz, I want to bring the peak closer to 521Mhz and I add a corner reflector:

Autosegmentation: 10 per 2.11268


Freq RawGain NetGain SWR F/R F/B Real Imag AGT(corr)
============================================================ ====================
==
470.0 13.655 13.446 1.554 29.540 31.460 248.88 110.22 1.16( 0.635)

476.0 14.085 13.884 1.541 29.200 42.410 260.58 115.28 1.16( 0.635)

482.0 14.535 14.347 1.518 28.680 34.110 275.98 118.56 1.16( 0.635)

488.0 15.005 14.850 1.461 28.290 29.040 290.60 112.31 1.16( 0.635)

494.0 15.475 15.350 1.406 27.410 27.410 289.14 100.27 1.16( 0.635)

500.0 15.945 15.776 1.486 26.330 26.330 270.84 109.80 1.16( 0.635)

506.0 16.395 16.088 1.707 23.270 23.270 275.72 153.78 1.16( 0.635)

512.0 16.825 16.465 1.786 19.940 19.940 356.19 183.83 1.16( 0.635)

518.0 17.125 16.995 1.414 18.310 18.310 409.47 54.16 1.16( 0.635)

524.0 20.583 20.551 1.189 19.320 19.320 287.73 49.33 0.53(-2.743)

530.0 20.293 20.229 1.276 21.420 22.990 362.91 50.55 0.53(-2.743)

536.0 19.393 18.623 2.351 22.380 22.380 148.45 107.73 0.53(-2.743)

542.0 18.283 15.216 5.937 15.860 20.150 101.82 -293.46 0.53(-2.743)

548.0 13.763 7.439 15.091 6.620 6.620 54.18 391.68 0.53(-2.743)

554.0 -13.877 -20.481 16.240 -11.390 -11.390 20.82 -106.74 0.53(-2.743)


Edit: By decreasing the diameter of the feed segment, I brought the AGT values listed above somewhat closer to 1 (1.01 instead of 1.16 and 0.46 where it peaks at 20 dbi). I suppose I should work on that?

nikiml
2013-05-11, 12:13 PM
It can be observed that there is some instability in the results.
The script has calculated AGT at two frequencies: the middle of 470-518 and the middle of 524-554 and the AGT values are completely different.

I would not thrust the gain values in such case.
You need to find segmentation at which the AGT values are stable and close to 1.

your earlier post includes a result with much better AGT values.

Also try to use -n 4 or even higher - this will cause AGT calculation at more frequencies.

Also - post your results in a code block - they get formatted much better

holl_ands
2013-05-11, 01:09 PM
Many times the optimization algorithms won't do what you WANT them to do, because they are working toward an OVERALL optimization, as demanded by the stipulated range of frequencies and the need to ALSO optimize SWR....sometimes at the expense of Max Gain.

There are a several different things you can do within the python control script (*.bat file) to have more control over the shape of the Gain curve and the placement of the Gain peak.

I haven't done any UHF Yagi Optimizations (Really???? I need to do some), but I do have several other examples, incl. the fol. Hi-VHF 12-El Yagi, which used the listed *.bat file:
http://imageevent.com/holl_ands/yagis/hivhf12elfdyagiopt


cd c:\Python27
python -m nec.opt --num-cores=7 -s(174,6,8) -t(14,16) --auto-segmentation=15 --swr-target=2.7 --f2r-target=25 --f2b-target=25 --target-function=(max_ml+8*max_gain_diff+4*max_f2r_diff+max_f2b_diff ) HiVHF_12El_FD_Yagi_PY.nec
pause


1) Since a Yagi will typically have an upward slope to the Gain curve, I used a Gain control statement calling for a Target of 14 dBi on the lowest freq and 16 dBi on the highest.

2) Many times I have found a Gain curve that Maxed out just below the highest frequency (the desired Max Gain freq). I could "move" the Max Gain freq up just a bit by changing the Frequency control statement to go HIGHER by the same amount. So in UHF Band, add 6 MHz more by adding one or two more "test points": change -s (506,6,8) to -s (506,6,9).

3) In a Yagi, optimizing for a WIDE bandwidth will result in a LOWER Max Gain, explaining the different results you found. And if you optimized over an even narrower bandwidth, Max Gain would be even higher....but you may of may not be happy with the Gain & SWR response elsewhere.

4) When not specifically stipulated, you are using the "default": --target-function=max(max_gain_diff, max_swr_diff). Although it is a good first cut, it may be giving away some Max Gain in order to drive SWR to an absolute minimum. In my above example, I use a WEIGHTED target function that can provide more "importance" to those parameters that NEED to be boosted and less "importance" to parameters that are perhaps "Better" than we need them to be. If you are trying to achieve Max Gain and don't CARE about F/B and F/R Ratios, you can delete those parameters.