Skip to content

Instantly share code, notes, and snippets.

@rumblefrog
Created March 28, 2019 02:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rumblefrog/17bdc3e853d7dd357baa2754a04dd44d to your computer and use it in GitHub Desktop.
Save rumblefrog/17bdc3e853d7dd357baa2754a04dd44d to your computer and use it in GitHub Desktop.
Sophisticated Helix Antenna Design with matching Coax to 50 Ω
function mehrWind() { x = document.generator.n.value * 1; x = x + 1 ; document.generator.n.value = x.toFixed(0) ; rechnen();}
function wenigerWind() { x = document.generator.n.value * 1; x = x - 1 ; if (x<1) x=1; document.generator.n.value = x.toFixed(0) ; rechnen();}
function mehrCond() { x = document.generator.d4.value * 1; x = x + 0.1 ; document.generator.d4.value = x.toFixed(2) ; rechnen();}
function wenigerCond() { x = document.generator.d4.value * 1; x = x - 0.1 ; if (x<0.1) x=0.1; document.generator.d4.value = x.toFixed(2) ; rechnen();}
function rechnen()
{
var freq;
freq = document.generator.freq.value * 1;
n = document.generator.n.value * 1;
d4 = document.generator.d4.value * 1;
var lambda = 300000000 / ( freq * 1000 ) ;
var pi = 3.141592653 ;
var d3 = lambda * 1.1;
var l1 = lambda / 4 ;
var steigung = l1 ;
var umfang = lambda ;
var d2 = umfang / pi ;
var impedanz_helix = 140 * pi * d2 / lambda ;
var impedanz_quelle = 50 ;
var impedanz_matcher = Math.sqrt( impedanz_helix * impedanz_quelle ); // lambda viertel lang !!!
var outer_diameter = d4 * Math.pow(10,(impedanz_matcher / 138 )) ;
var l2 = n * steigung;
var gain = 11.8 + 10* Math.log(pi * pi * d2 *d2 * n * steigung / ( lambda * lambda * lambda )) / Math.log(10) ;
document.generator.l1.value=l1.toFixed(2);
document.generator.d1.value=outer_diameter.toFixed(2);
document.generator.d3.value=d3.toFixed(2);
document.generator.lambda.value=lambda.toFixed(2);
document.generator.d2.value=d2.toFixed(2);
document.generator.l2.value=l2.toFixed(2);
document.generator.gain.value=gain.toFixed(2);
document.generator.R.value=impedanz_helix.toFixed(2);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment