OPTIMISE(1)
πΈ NAME πΈ
okay so bestie, meet optimise β the Yagi-Uda project antenna optimiser π she lives in section 1 of the manual, aka the General Commands Manual, and she is entirely about making your Yagi antenna be her best self β¨
π¦ SYNOPSIS π¦
optimise [ -dhvwO ] [ -aangular_stepsize ] [ -bboom_extension ] [
-ccleanliness_of_pattern ] [ -eelements ] [ -fFBratio ] [
-gGA_optimisation_method ] -lpercent ] [ -mmin_offset_from_peak ] [
-ooptimisation_criteria ] [ -ppopulation ] [ -rresistance ] [ -sswr ] [
-tlength_tolerance ] [ -xreactance ] [ -AAuto_gain ] [
-CCurrents_similar ] [ -Fweight_FB ] [ -Gweight_gain ] [
-Kkeep_for_tries ] [ -Pweight_pattern_cleanliness ] [
-Rweight_resistance ] [ -Sweight_swr ] [ -Tposition_tolerance ] [
-WWeighted_algorithm ] [ -Xweight_reactance [ -ZZo ] filename iterations
π DESCRIPTION π
ok so optimise is one of a bunch of executable programs that are all part of one big set, collectively known as the Yagi-Uda project, and the whole squad was designed for analysis and optimisation of Yagi-Uda antennas. optimise specifically attempts to optimise the performance of a Yagi antenna for one or more parameters that we consider important, like gain, F/B ratio, VSWR etc. How does she do it? She randomly changes the lengths and positions of one or more elements, then compares the performance before and after the change. Any improvements get written to a new file called filename.bes, where filename is the name of the antenna description file created by input or first. π
Now, real talk: when Yagi's are designed on paper, or using this program, it's possible they'll be almost impossible to build, if their performance depends too critically on the dimensions. To figure out if that's the situation with your design, we run optimise with just the options t and T. Those specify the tolerance with which you can build the antenna, expressed as a standard deviation in mm. In this case, instead of trying to optimise a poor design, optimise will calculate the minimum gain, maximum VSWR, and minimum FB ratio of a number of designs, all slightly different from the input file. 99.7% of the components lie within 3 SD of the mean, so if you think you can cut elements to within 1 mm 99.7% of the time, specify t0.33. If you can put them in the boom to within 3 mm 99.7% of the time, specify T1. π
And here's a cute little trick π«Ά β if, while optimise is running using the methods that require weights to be attached to the gain, FB, SWR etc, it becomes apparent the weights are not optimum, it's possible to pause the program and re-adjust the weights. If a file with the name of changes is created, the program will pause, then request new weights are entered at the keyboard. iconic behaviour honestly π
π AVAILABILITY π
ngl bestie, this section is literally empty in the original β there is nothing under it before OPTIONS starts. not me staring at a blank heading π anyway, moving on β¨
β¨ OPTIONS β¨
-dβ print the default values of all the configureable parameters to stdout. Typing this option with any option that changes a parameter (peep below π) will display the new value of the parameter, rather than the default. slay.-hβ print a help message. your little SOS button π-vβ print verbose status information. she will tell you everything, main character energy.-wβ instead of optimising at one fixed frequency (the design frequency), this directs the program to optimise at 3 separate frequencies (lowest, design and highest) then to average data at all 3. This option is better for wideband antenna. π¦
β οΈ note that the input impedance printed is at the design frequency, not averaged over 3 frequencies. Averaging an impedance is likely to give a very misleading impression. The impedance averaged over 3 frequencies can be 50+i0 Ohms, even if the VSWR is very poor over all 3 frequencies, as the following 3 pieces of data show.
Z=147 + j 300 SWR= 15.46:1
Z=2 + j 100 SWR= 125:1
Z=1 - j 400 SWR= 3250:1
note in the above three cases, the average impedance is 50 + j 0, but average SWR is 1130:1. π yeah. that's why.
-Oβ Over-optimisation allowed. By default, the program does not over-optimise a parameter. For example, an SWR of1.01is usually considered good enough and any change, as long as the SWR stayed good, typically below1.1:1, would be allowed, even if the SWR rose. By default, FB's of27 dB, VSWR's of1.1are acceptable. However, by using the-Ooption, you can insist the program always improves things, no matter how good they are. no chill mode, periodt π₯-aAngular_stepsizeβ when optimising by trying to get a clean pattern, this specifies the step size to use when looking for features in the pattern. If it's set too small, the program runs slow π. If it's set too large, the program may miss features in the pattern, such as a sidelobe β and then the resulting antenna will have poor sidelobe performance, even though you think it will be good. π The program attempts to calculate a sensible value, based on 1/10th the approximate 3 dB beamwidth, if you don't set it.-bboom_extensionβ generally speaking, the gain of a Yagi increases with boom length. Hence the optimiser would often give you a Yagi with a much longer boom than the input file. This may not be what you desire due to space restrictions π₯². These long antennas often have high gain, but are very narrow in bandwidth. The default limits the antenna to 10x the original length, which means effectively there is no boom length limitation. You can adjust the percentage by settingboom_extensionto whatever you wish.-b30will limit the boom to no more than 30% more than the original length. pick your vibe π-ccleanliness_of_patternβ specify the number of dB down on the peak gain to aim to get the pattern. Any antenna pattern cleaner than this will not effect the fitness, nor will it be considered any better when comparing to antenna designs.20 dBseems reasonable, so the default is20, but this may of course change if it's deceided too. Check the source code to be certain (seeREASONABLE_SIDELOBEinyagi.h). iykyk π-eelementsβ is an integer which specifies the type of elements that are changed in the optimisation cycle. Possible values are:1β alter only the driven element(s) length (useful to bring to resonance)2β alter only the driven element position. Don't change its length.4β alter only the reflector length. The position is always atx=0.8β alter only the director lengths. Don't change positions.16β alter only the director positions. Don't change lengths.32β randomly adjust one element length, then makes all other the same. Don't change the positions.64β apply a linear taper to the lengths.128β Set the driven element to a resonate length. It may/may-not be altered after the first run, depending on the whether or not1is invoked too. Eg-e128will make it resonate and keep it there forever. However-e129will bring to resonance, then alter to maximuse performance.
The elements altered is made from a logical AND of the above, so for example to alter everything, except the driven element length, use -e30, since 2+4+8+16=30. The default is equivalent to -e31, which changes everything possible. Note the reflector position is never changed. It's always at x=0. π« never ever, no cap.
-fFBratioβ when optimising an antenna, consider any FB ratio greater thanFBratiodB to be equal toFBratiodB. This avoids optimising to a very high FB ratio, which is impracticable, as the bandwidth over which this FB ratio will be maintained is very small and mechanical considerations will prevent you from constructing it with such a high FB ratio anyway. If this was not prevented, you might just happen to get an antenna with100 dBFB ratio, but poor gain and swr π. Since by default all parameters must improve, the optimisation routine will most likely never being able to improve on the100 dBFB ratio, so no improvement will result. Most people would prefer to get a few extra dB of gain, even if the FB ratio dropped to30 dB. reasonable tbh π-gGA_optimisation_methodβ Use a genetic algorithm. 𧬠With the genetic algorithm, the program does not take any account any of the initial lengths/positions of elements specified in the input file. Rather it works by initialising a number of different antenna, then computing a'fitness'value for each. The fitness value can depend on the gain, FB, real part of the input impedance, reactive part of the input impedance, VSWR or the level of the sidelobes. The integer after thegtells the optimiser what to consider.-g1Use gain-g2Use FB-g4Use R-g8Use X-g16Use the SWR-g32Use the level of the sidelobes.
You can use a logical AND of these, so for example -g49 will use a genetic algorithm, optimising for gain, swr and sidelobe level, since 1(gain)+16(SWR)+32(sidelobe level)=49. math ate π
-lpercentβ is a parameter (floating point number) which specifies the maximum percentage change in the positions or lengths of an elements at each iteration. If the option is not used, it will be set internally at10%for the first 25% of the iterations,1%for the next 25%,0.1%for the third 25% of the iterations and0.01%for the last 25% of the iterations. If set to a positive number x (egoptimise -l 0.3 145e10) then the percentage will be set at x% for 25% of iterations, x/10 for the next 25%, x/100 for the next 25 and x/1000 for the last 25%. If set to a negative number y (egoptimise -l -0.5 145e10) then the parameters will stay fixed at y% (in this example0.5%) all the time. π-mmin_offset-from_peakβ Sets the minimum angle in degrees offset fromtheta=90degrees, where the side lobes start and the main lobe finishes. The higher the gain, the smaller it should be. It is set internally if not set on the command line. πΈ-ooptimisation_criteriaβ okay bestie, this is the big one, the vibe check for what "better" even means. You pass it a number, and it's built from these lil flags, and you add them together to make a bitmask (the manpage calls it a logical AND, but the example adds them, so iykyk π ):1β Assume better if the gain has increased. π2β Assume better if the front to back ratio has improved. π―4β Assume better if the real part of the input impedance is closer to the value that the program was compiled for, or set using the-Zoption. This will usually be50 Ohms, but you may wish to set this to12.5 Ohmsif you use a4:1balun. Generally you can get higher gain from a Yagi if you allow the input impedance to fall, but of course feeding it becomes more difficult. π«8β Assume better if the magnitude of the reactive component of the input impedance is lower (ie. the antenna is nearer resonance). π16β Assume better if the VSWR is lower. β¬οΈ32β Assume better if the level of all sidelobes is lower. π€«
The optimisation_criteria may be formed from a logical AND of these numbers, so for example choosing -o19 will only consider a revised antenna better than the previous, if the SWR, gain and F/B ratio have all simultaneously improved. β¨
Clearly an antenna which originally had 12 dB gain and 1.01:1 VSWR but then changes to 20 dB gain @ 1.02:1 VSWR, would to most people be better, even though the VSWR has increased. By default, optimise only optimises to sensible maximums, so to not let the optimisation stall prematurely. By running optimise with no arguments, the program will list the limits of acceptability. These might be typically F/B ratio > 27 dB, VSWR < 1.1:1, magnitude of input reactance less than 5 Ohms and the real part of the input impedance within 5 Ohms of Zo. Choosing -o19 (1+2+16=19) will optimise for gain (since G=1), FB (since FB=2) and SWR (Since SWR=16), but would consider a higher gain and FB ratio antenna better than a previous one, even if the SWR rose, as long as it stayed below 1.1:1 (or as was set during compilation). The default behaviour (no options) is equivalent to -o37 which optimises for gain(1), the real part of the input impedance(4) and sidelobes(32) but this may be changed at any time, so type optimise -d to check the current settings. If you insist on the program optimising for the very best of all selected parameters, use the -O option too, but be warned the optimisation will probably stick once it gets one parameter really good. π
-ppopulationβ this determines the initial population used with the genetic algorithm. π§¬β¨-rresistanceβ when optimising an antenna, consider any input resistance closer toZo(usually50 Ohms) thanresistanceOhms to be acceptable. This avoids optimising to an input resistance too close toZo, which is impracticable, as the bandwidth over which the input resistance could be maintained is very small and mechanical considerations will prevent you from constructing the antenna with such an ideal input resistance. If this was not prevented, you might just happen to get an antenna with an input resistance of50.000001 Ohms, but poor gain, FB and possibly even a poor swr, if the antenna is well away from resonance. Since by default all parameters must improve, the optimisation routine will get most likely never being able to improve on the antenna, whereas we might be happier with a few more dB gain, if the input resistance went to50.1 Ohms. It should be noted that the default optimisation routine never uses the input resistance directly (only VSWR), so this option cant be used without the-ooption to optimise for other than the default parameters (gain, VSWR and FB ratio). π-sswrβ when optimising an antenna, consider any SWR less thanswrto be equal toswr. This avoids optimising to a very low swr, which is impracticable, as the bandwidth over which such a low swr could be maintained would be very small and mechanical considerations will prevent you from constructing such an antenna anyway. If this is was not prevented, you might just happen to get an antenna with an swr of1.000000000001:1, but poor gain, FB ratio. Since by default all parameters must improve, the optimisation routine will most likely never being able to improve on the antenna, even though in practice you would like to get a few extra dB of gain if the SWR would rise to1.02:1. The default was equivalent to-s1.1but runoptimise -dto display this and any other defaults. π«Ά-tlength_toleranceβlength_toleranceis the standard deviation in mm of the accuracy with which you can cut elements. Since99.7%of elements will be with 3 standard deviations of the mean length (stats theory says this), set-t0.2if virtually all (well99.7%) of elements are within3x0.2=0.6 mmof the correct length. This option must be used with the-Toption and can't be used with any other options apart from-Z,-vand-d. π-xreactanceβ when optimising an antenna, consider any input reactance of less thanreactanceto bereactance. This avoids over optimising the reactance, at the expense of something else. πΈ-Aauto_gainβ when theauto_gainoption is used, the program maximes the gain of the antenna (ignoring all other parameters such as SWR, FB ratio etc) by adjusting the length (not position) of one element only.-A-1will maximuse the gain, by adjusting the length of the reflector,-A0will maximise the gain by adjusting the length of the driven element. Its generally not a good idea to maximise the gain by adjusting the driven element, but the program lets you do it, but using the option-A0. Using-A1will maximise gain by adjusting the length of the first director,-A2the second director and so on, up to the last director. You must check carefully that the input impedance in particular does not fall to silly values if you use this option. On a yagi with many elements (> 10or so), you can pretty safely maximise the8thor more director, but doing it on the reflector, driven element or early directors often leads to silly input impedances - so beware! Note, no matter how many iterations you specify, this process is only done once. Its unlikely you will be able to do it again, without things going out of hand, but if you must do it, you must re-runoptimiseagain. π-Ccurrents_similarβ if this option is used, wherecurrents_similaris an integer, the program looks to make the currents in the lastcurrents_similarelements as similar as possible. It computes the sum of the squares of the deviations of the absolute values of the element currents from the mean. If this falls, and the criteria specified with the-Woption is also satisfied, the antenna is considered better. Ifcurrents_similaris three less than the number of directors, it tries to make the currents in the the directors (but ignoringing the first3) all similar. Ifcurrents_similaris equal to the number of directors, it tries to make all the directors have similar currents. Ifcurrents_similaris one more than the number of directors, it tries to make all the directors and the reflector have similar currents. Ifcurrents_similaris equal to the total number of elements, then it fails with an error message. π-Fweight_FBβ is the floating point number (default1.0) specifying the weight to attach to the FB ratio of the antenna when using the-Woption, which calculates a fitness for the antenna based on one or more parameters (FB, gain, input resistance, input reactance, SWR, cleanliness of antenna pattern). The-Foption is similar to the options-G,-P,-R,-S,-X(which specify weights for gain, pattern cleanliness, input resistance, SWR and input reactance). When using the-Woption the exact algorithm used to compute the fitness (and hence the effect of this parameter) is best checked by looking at the source code (seeperform.c). This is one area of constant program improvement/changes/development, so its difficult to say exactly the effect the parameter has. However, increasing the weight of a parameter (using the-F,-G,-R,-Sor-Xoptions) will make the associated parameter have a greater effect on the fitness. However, unless you optimise for a high FB ratio with the-Woption, then setting the-Foption will have no effect. For example, setting the options-F2.5 -W1is a complete waste of time. There you have used the-W1option to optimise only for gain (see-Woption section of man page) but have changed the weight of the FB ratio from its default1.0to2.5. If you are not optimising for FB ratio, the weight you attach to it is irrelavent. π-Gweight_gainβ is the floating point number (default1.0) specifying the weight to attach to the gain of the antenna when using the-Woption, which calculates a fitness for the antenna based on one or more parameters (FB, gain, input resistance, input reactance, SWR, cleanliness of antenna pattern). The-Goption is similar to the options-F,-P,-R,-S,-X(which specify weights for FB ratio, pattern cleanliness, input resistance, SWR and input reactance). When using the-Woption the exact algorithm used to compute the fitness (and hence the effect of this parameter) is best checked by looking at the source code (seeperform.c). This is one area of constant program improvement/changes/development, so its difficult to say exactly the effect the parameter has. However, increasing the weight of a parameter (using the-F,-G,-R,-Sor-Xoptions) will make the associated parameter have a greater effect on the fitness. However, unless you optimise for gain with the-Woption, then setting the-Goption will have no effect. For example, setting the options-G2.5 -W2is a complete waste of time. There you have used the-W2option to optimise only for FB ratio (see-Woption section of man page) but have changed the weight of the gain from its default1.0to2.5. If you are not optimising for gain, the weight you attach to it is irrelavent. π-Kkeep_for_triesβ okay sokeep_for_triesis how many tries the optimiser stays put, still using the original data file as its starting point, before it's like "aight I'm moving". Default is1, meaning the second it finds a better spot it immediately starts looking from a whole new position. theoretically that could land you on a quick-but-mid local maximum π« but ifkeep_for_triesis1000, it chills at a position for 1000 iterations after the last best result before it decides "this is the global optimum fr" and then moves on. Ngl, in practice the author found this option made things worse in most cases. It got added to dodge the local-minimum problem, but the optimisation surface is apparently pretty smooth, so it just slows the program down without really gaining anything. Anyway, it stays as an option β just check your results with and without it carefully before you go using it extensively. π-Ppattern_cleanlyinessβ a floating point number (default1.0) setting the weight attached to the cleanness of the antenna pattern when you're using the'-W'option, which calculates a fitness for the antenna based on one or more parameters (FB, gain, input resistance, input reactance, SWR, cleanliness of antenna pattern). The'-P'option is similar to the options-F,-G,-R,-S,-X(which specify weights for FB ratio, gain, input resistance, SWR and input reactance). When you use the-Woption, the exact algorithm computing the fitness β and therefore this parameter's effect β is best checked by looking at the source code (seeperform.c). This is one area of constant program improvement/changes/development, so it's hard to say exactly what effect the parameter has. That said, increasing the weight of a parameter (via the-F,-G,-R,-Sor-Xoptions) makes the associated parameter have a greater effect on the fitness. But β unless you optimise for a clean antenna pattern with the-Woption, setting-Pdoes literally nothing. For example, setting the options-P2.5 -W1is a complete waste of time. There you've used-W1to optimise only for gain (see the-Woption section of the man page) but changed the weight of pattern cleanliness from its default1.0to2.5. If you're not optimising for a clean radiation pattern, the weight you attach to it is irrelevant. With appropriate use of the-Woption (eg-W49for gain, SWR and a clean pattern), the program finds the level of the most significant sidelobe, wherever it may be outside the main beam. It then optimises to reduce this. The-Poption tells it how much weight to put on reducing this sidelobe. π¦-Rweight_resistanceβ a floating point number (default1.0) setting the weight attached to obtaining an input resistance close to Zo on the antenna when you're using the'-W'option, which calculates a fitness for the antenna based on one or more parameters (FB, gain, input resistance, input reactance, SWR, cleanliness of antenna pattern). The'-R'option is similar to the options-F,-G,-P,-S,-X(which specify weights for FB, gain, pattern cleanliness, SWR and input reactance). When you use the-Woption, the exact algorithm computing the fitness β and therefore this parameter's effect β is best checked by looking at the source code (seeperform.c). This is one area of constant program improvement/changes/development, so it's hard to say exactly what effect the parameter has. That said, increasing the weight of a parameter (via the-F,-G,-R,-Sor-Xoptions) makes the associated parameter have a greater effect on the fitness. But β unless you optimise for an input resistance close to Zo with the-Woption, setting-Rdoes nothing. For example, setting the options-R2.5 -W1is a complete waste of time. There you've used-W1to optimise only for gain (see the-Woption section of the man page) but changed the weight of the resistance from its default1.0to2.5. If you're not optimising for an input resistance close to Zo, the weight you attach to it is irrelevant. π-Sweight_swrβ a floating point number (default1.0) setting the weight attached to the SWR of the antenna when you're using the'-W'option, which calculates a fitness for the antenna based on one or more parameters (FB, gain, input resistance, input reactance, SWR, cleanliness of antenna pattern). The'-S'option is similar to the options-F,-G,-P,-R,-X(which specify weights for FB, gain, pattern cleanliness, input resistance and input reactance). When you use the-Woption, the exact algorithm computing the fitness β and therefore this parameter's effect β is best checked by looking at the source code (seeperform.c). This is one area of constant program improvement/changes/development, so it's hard to say exactly what effect the parameter has. That said, increasing the weight of a parameter (via the-F,-G,-R,-Sor-Xoptions) makes the associated parameter have a greater effect on the fitness. But β unless you optimise for SWR with the-Woption, setting-Sdoes nothing. For example, setting the options-S2.5 -W1is a complete waste of time. There you've used-W1to optimise only for gain (see the-Woption section of the man page) but changed the weight of the SWR from its default1.0to2.5. If you're not optimising for SWR, the weight you attach to it is irrelevant. β¨-Tposition_toleranceβposition_toleranceis the standard deviation in mm of the accuracy with which you can cut elements. Since 99.7% of elements will be within 3 standard deviations of the correct position (stats theory says so, no cap), set-T2if virtually all (well, 99.7%) of elements are within 3x2=6 mm of the correct position. > This option must be used with the'-t'option and can't be used with any other options apart from'-Z','-v'and'-d'. π-WWeighted_algorithmβ try to get an antenna which is better according to a weighted combination of parameters, rather than requiring them all to improve. The integer specifies what to consider in the weighted parameters.W1Gain.W2FBW4RW8XW16SWRW32SIDE_LOBE
You can logically AND these together, so for example -W3 will optimise using a weighted combination of gain and FB. -W49 will use a weighted combination of gain, swr and sidelobe level, since 32+16+1=49. π₯
-Xweight_reactanceβ a floating point number (default1.0) setting the weight attached to achieving a low input reactance on the antenna when you're using the'-W'option, which calculates a fitness for the antenna based on one or more parameters (FB, gain, input resistance, input reactance, SWR, cleanliness of antenna pattern). The'-X'option is similar to the options-F,G,-P,-Rand-S(which specify weights for FB ratio, gain, pattern cleanliness, input resistance, and SWR). When you use the-Woption, the exact algorithm computing the fitness β and therefore this parameter's effect β is best checked by looking at the source code (seeperform.c). This is one area of constant program improvement/changes/development, so it's hard to say exactly what effect the parameter has. That said, increasing the weight of a parameter (via the-F,-G,-R,-Sor-Xoptions) makes the associated parameter have a greater effect on the fitness. But β unless you optimise for a low input reactance with the-Woption, setting-Xdoes nothing. For example, setting the options-X2.5 -W1is a complete waste of time. There you've used-W1to optimise only for gain (see the-Woption section of the man page) but changed the weight of the reactance from its default1.0to2.5. If you're not optimising for a low input reactance, the weight you attach to it is irrelevant. π-ZZoβZois the characteristic impedance used when evaluating the VSWR, reflection coefficient and other similar calculations. The optimiser usually tries to bring the input impedance of the antenna to this value. It's set by default to 50 Ohms, so the default is equivalent to-Z50, but it may be set to any positive number. Set to 12.5 Ohms if you're going to feed the antenna with a 4:1 balun. Generally speaking, the gain of a Yagi can be higher for low input impedances, but of course such antennas are more difficult to feed. π
β¨ the arguments, bestie β¨
filenameβ this is the name of the file containing the antenna description. It's expected to be in a format created by eitherinputorfirstβ two other programs in the Yagi-Uda project. This is an ASCII text file. πiterationsβ an integer specifying the number of iterations for the optimiser to perform to try to get the best antenna. Time will limit the number you choose.1000iterations of a 1ele yagi takes about 5 seconds, a 6ele approximately 60 seconds, an 11 element 350 seconds, a 20 element 1030 seconds, a 33ele 2440 seconds, a 50element 5400 seconds, 100ele 21320 seconds β all on an old 25MHz 486 PC with no external cache. π When using the-Aoption the iterations is automatically set internally so only one attempt is made. When using the'-t'and'-T'options, iterations specifies the number of iterations to attempt to get a poorer design, to check the sensitivity of the design to small manufacturing tolerances. πΈ
π EXAMPLES π
Okay bestie, here's a whole little gallery of ways you can run optimise. Come look, they're iconic.
optimise 5ele 1000
So here the file 5ele gets optimised using the default system for 1000 iterations. That default might typically require gain, FB and SWR to all improve, but ngl that can be changed at literally any time. Either way, the program tells you what it's optimising for, so you're never guessing. And by default it only optimises until the selected parameters are good β it's not out here over-optimising any one of them at the detriment of the others. Balance, queen. βοΈ
optimise -b30 -f50 -s2 5ele 1000
Same vibe as above, but now: the boom can't extend by more than 30% from its original length, FB ratios above 50 dB are considered acceptable, and so are SWRs less than 2:1. The optimised resultant antenna is likely to have a better FB ratio, but a poorer SWR than in example (1). Trade-offs, we love to see it. π
optimise -o1 5ele 1000
This one simply optimises 5ele for maximum forward gain. That's it. The resultant antenna may have a poor FB ratio and is likely to have an unacceptably low input impedance and hence high VSWR. So like... this is not a very sensible method of optimisation. π© Do not recommend, bestie.
optimise -W49 -l7 5ele 10000
This optimises the file 5ele for 10000 iterations. It'll require that the weighted performance of the antenna in three important parameters (gain, sidelobe level and SWR) improves from one design to the next. Wild part: one or two parameters can actually get worst from one design to the next, but the weighted performance is still better. And the positions of the elements or lengths of elements will not change by more than 7% in each iteration. Growth mindset fr fr. π±
optimise -g -S30 -G50 -F20 -p1500 5ele 10000
Now we're doing a genetic algorithm, okay?? 1500 antennas will be randomly designed. The performance of each of these will be measured using a 'fitness' function, weighted 30% to SWR, 50% to gain and 20% to FB ratio. And the probability of breading from a pair of antennas is proportional to the fitness function. Darwin found shaking. π§¬β¨
optimise -w atv_antenna 10000
This optimises the file atv_antenna for a best average performance over a wide band. The progrram calculates the gain, FB and SWR at three frequencies, then computes an average (mean) performance of the antenna over the band. Heads up though: N iterations will take 3x as long to execute as N iterations on the same antenna without the '-w' option. Worth it, but it's giving long-haul. β³
optimise -t0.1 -T1 good_design 100
Last one and it's the chaos simulator: this takes the file good_design and makes 100 different antennas from it, to simulate the effects of building tolerances. Each element is assumed to be cut so that the mean error of all elements is 0 mm, but a standard deviation of 0.1 mm, so 68.4% of element lengths are within 0.1 mm, 95.4% within 0.2 mm and 99.7% with in 0.3 mm. The accuracy of placing elements along the boom is much lower, so here we've specified a standard deviation of 1.0 mm, so 68.6% of elements are placed within 1 mm of the correct position, 95.4% within 2 mm of the correct position etc. The program will report the *worst* performances achieved. So if the performance dips too mush, then you either need to build them better, or get a design that's less critical! ππ¨
π STOPPING π
Optimise will stop after the number of iterations specified in the parameter iterations. It will also stop if a file stop exits in the current directory of the executable optimise. This file can of course only be created using a multi-tasking operating system such as Unix.
It is *not* advisable to stop the program by hitting theDELkey (Unix) orCONTROL-C(DOS), as one of the files may be open at the time, resulting in an empty file. π± Files are not open for any longer than necessary (they are closed immediately after writing to them), so this is not a likely occurrence, but can still occur.
π§ LIMITATIONS π§
I'm not aware of any limitations, apart from that filenames, including full path, can't exceed 90 characters. Short and sweet, bestie. π
π FILES π
filenameβ Antenna description, created byinputorfirst.filename.upβ Update file, listing achievements ofoptimise.filename.besβ Best file, containing the best design to date.changesβ File that causes the program to pause to re-adjust weights.stopβ File that stops optimisation process.
π SEE ALSO π
first(1), input(1), output(1), yagi(1), first(5), input(5) output(5) and optimise(5).
π₯οΈ PLATFORMS π₯οΈ
Both DOS and Unix versions have been built. The DOS version as distributed requires a 386 PC with a 387 maths coprocessor. Retro tech moment, we respect the elders. πΉοΈ
Although I have altered the source to make it more compatible with DOS (reduced file name lengths etc), my wish is to build a decent program, rather than fit the program to an outdated operating system. If there is a *good* reason to use code that is incompatible with DOS, this will be done.
Since optimise takes a while to optimise an antenna (I've optimised one design for a week π΅), it is obviously more sensible to build this program under a multi-tasking operating system, as otherwise a PC can be tied up for days.
π BUGS π
Bugs should be reported to david.kirkby@onetel.net. Bugs tend actually to be fixed if they can be isolated, so it is in your interest to report them in such a way that they can be easily reproduced. Help a dev out, okay? π«Ά
- The program will dump core (crash) if asked to optimise a
1elebeam, without any arguments. This is because a1elebeam has no parasitic elements and by default the program only changes parasitic elements. π - Some of the options are not checked for sensible values, although most are now checked and report if they are out of range.
- If the user specifies very large manufacturing errors using the
'-t'and'-T'options, its possible for elements to overlap or for element lengths to become negative. This will cause numerical errors. Any reasonable values will not cause this. - On long Yagi's (
50elements)optimisecan go a bit silly. It can optimise say a1296MHzYagi to get20dB at1296MHz, but less than0dB at only1MHz away. Needs some thought! π€ - The level of the sidelobes is not computed with the GA or some other optimisation types. This will be corrected later.
- All those I don't know about. π
π AUTHORS π
Dr. David Kirkby G8WRB (david.kirkby@onetel.net). with help with converting to DOS from Dr. Joe Mack NA3T (mack@fcrfv2.ncifcrf.gov).
And that's the whole page, bestie!! πβ¨ This was version 1.16, dated 24 October 2000 β yeah she's vintage, an absolute icon of the Y2K era, and honestly? Still serving. Go optimise something gorgeous. π
ππ¦
π¦ where this page comes from
- debian bookworm: yagiuda 1.19-10 Β· GPL-2.0-or-later
- debian trixie: yagiuda 1.19-12 Β· GPL-2.0-or-later
- ubuntu jammy: yagiuda 1.19-10 Β· GPL-2.0-or-later
- ubuntu noble: yagiuda 1.19-11 Β· GPL-2.0-or-later
- ubuntu questing: yagiuda 1.19-12
- ubuntu resolute: yagiuda 1.19-13 Β· GPL-2.0-or-later
- ubuntu stonking: yagiuda 1.19-13 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms