function deleteAllCookies(){var e=document.cookie.split(";");for(var t=0;t-1?n.substr(0,r):n;document.cookie=i+"=;expires=Thu, 01 Jan 1970 00:00:00 GMT"}}function test_t_ant(){var e;var t=new Array;t=getCN_degradation(1*Frequency,1*AntSize,0);alert(t[0])}function ITUR_BO1213_AntennaPattern(e,t,n,r,i){var s,o,u,a,f,l,c,h,p,d,v,m;s=299792458;o=Math.PI;c=Math.pow(10,34/25);u=s/(n*1e3*1e3*1e3);m=e/u;d=10*log10(t*(o*e/u)*(o*e/u));l=95*(u/e);p=29-25*log10(l);f=u/e*Math.sqrt((d-p)/.0025);if(0<=i&&i=11)return v-d;else{return 99}}function find_offaxis_for_gain_reduction(e,t,n){var r,s,o,u;for(i=0;i<1800;i++){r=i/10;s=ITUR_BO1213_AntennaPattern(1*t,1*n,1*Frequency,54,r);if(s==99)return-1*1;if(sf){u=r*i*(f/a)*(f/a)}else{u=r*i}y=Math.pow(10,g/10);m=10*log10((v+u*y)/v);w[0]=formatnumber(Math.round(m*1e3)/1e3,4);w[1]=Math.floor(v);w[2]=Math.floor(u*y);w[3]=Math.floor(u);w[4]=Math.floor(r*12e4*Math.pow(e,-.75));return w}function log10(e){return Math.log(e)/Math.log(10)}function onchange_antenna_size(){AntSize=1*document.getElementById("AntSize").value;document.getElementById("AntSizeFeet").value=formatvalue(AntSize*metertofeet,4);document.getElementById("AntSizeInches").value=formatvalue(AntSize*metertoinch,5);SetCookie();load_tables();print_outages()}function onchange_antenna_size_feet(){var e;e=1*document.getElementById("AntSizeFeet").value;AntSize=e*feettometer;document.getElementById("AntSize").value=formatvalue(AntSize,4);document.getElementById("AntSizeInches").value=formatvalue(e*feettoinch,5);SetCookie();load_tables();print_outages()}function onchange_antenna_size_inches(){var e;e=1*document.getElementById("AntSizeInches").value;AntSize=e*inchtometer;document.getElementById("AntSize").value=formatvalue(AntSize,4);document.getElementById("AntSizeFeet").value=formatvalue(e*inctofeet,5);SetCookie();load_tables();print_outages()}function onchange_band(){if(document.getElementById("c-band").checked==true)Frequency=3.95;else if(document.getElementById("ku-band").checked==true)Frequency=11.95;else if(document.getElementById("user-band").checked==true)Frequency=1*document.getElementById("Frequency").value;document.getElementById("Frequency").value=Frequency;SetCookie();load_tables();print_outages()}function onchange_frequency(){document.getElementById("user-band").checked=true;Frequency=1*document.getElementById("Frequency").value;SetCookie();load_tables();print_outages()}function onchange_year(){Year=1*document.getElementById("Year").value;print_outages()}function onchange_season(){if(document.getElementById("Spring").checked==true)season=0;else season=1;print_outages()}function SetHtmlDefaults(){var e,t;t=new Date;Year=t.getUTCFullYear();Month=t.getUTCMonth()+1;if(Month>=5){document.getElementById("Fall").checked=1;season=1}else{document.getElementById("Spring").checked=1;season=0}document.getElementById("ku-band").checked=true;document.getElementById("AntSize").value=.72;document.getElementById("Frequency").value=10.95;document.getElementById("Year").value=Year;e=document.cookie;if(e==null){document.getElementById("ku-band").checked=1;Frequency=11.95}else{var n=new Array;n=e.split(":");if(n[14]=="C")document.getElementById("c-band").checked=true;else if(n[14]=="ku")document.getElementById("ku-band").checked=true;else if(n[14]=="userband")document.getElementById("user-band").checked=true;else document.getElementById("ku-band").checked=true;if(!isNaN(n[12])&&n[12]!="undefined"&&n[12]!=""){document.getElementById("AntSize").value=1*n[12];AntSize=1*n[12]}else{AntSize=.6;document.getElementById("AntSize").value=.6}if(!isNaN(n[13])&&n[13]!="undefined"&&n[13]!=""){Frequency=1*n[13];document.getElementById("Frequency").value=1*1*n[13]}else{Frequency=11.95;document.getElementById("Frequency").value=Frequency}}if(document.getElementById("user-band").checked)Frequency=1*document.getElementById("Frequency").value;else if(document.getElementById("ku-band").checked){Frequency=11.95;document.getElementById("Frequency").value=Frequency}else if(document.getElementById("c-band").checked){Frequency=3.95;document.getElementById("Frequency").value=Frequency}if(!isNaN(AntSize)){document.getElementById("AntSizeFeet").value=formatvalue(AntSize*metertofeet,4);document.getElementById("AntSizeInches").value=formatvalue(AntSize*metertoinch,5)}}function SetCookie(){var e,t,n,r,i;var s,o;var u,a,f,l;var c,h,p,d,v,m,g,y,b,w;var E,S,x,T,N,C,h,p,d;var k=new Array;var L=new Array;MyCookieVal=document.cookie;if(MyCookieVal!==""){k=MyCookieVal.split(":");E=k[4];S=k[6];x=k[7];T=k[8];N=k[9];C=k[10];h=k[12];p=k[13];d=k[14];v=k[15];g=k[17];y=k[18];b=k[19];w=k[20]}if(MyCookieVal==""){E="undefined";S="undefined";x="undefined";T="undefined";N="undefined";C="undefined";h="undefined";p="undefined";d="undefined";v="undefined";g="undefined";y="undefined";b="undefined";w="undefined"}if(SiteLat<0){n="South";e=-SiteLat}else{n="North";e=SiteLat}if(SiteLon>0){r="East";t=SiteLon}else{r="West";t=-SiteLon}o=document.Position.SelectList.selectedIndex;HightAboveOcean=1*Height_over_ocean;m=map.getZoom();if(currentAddressResponse!="")v=currentAddressResponse;h=1*document.getElementById("AntSize").value;p=1*document.getElementById("Frequency").value;if(document.getElementById("c-band").checked==true)d="C";else if(document.getElementById("ku-band").checked==true)d="ku";else if(document.getElementById("user-band").checked==true)d="userband";else document.getElementById("ku-band").checked=true;i=e+":"+n+":"+t+":"+r+":"+E+":"+o+":"+S+":"+x+":"+T+":"+N+":"+C+":"+HightAboveOcean+":"+h+":"+p+":"+d+":"+v+":"+m+":"+g+":"+b+":"+w+";expires=Tue, 10 Jul 2040 23:59:59 UTC;";deleteAllCookies();document.cookie=i}function print_outages(){document.getElementById("outages").innerHTML=get_outage_dates_and_HAtransit(SatLon,SiteLon,SiteLat,season,Year,Frequency,AntSize,Height_over_ocean,Geosync_radius)}function clear_multiple_outages(){multipleoutagesoutput="";lastprintedoutage="";document.getElementById("outages").innerHTML=""}function print_multiple_outages(){multipleoutagesoutput=get_outage_dates_and_HAtransit(SatLon,SiteLon,SiteLat,season,Year,Frequency,AntSize,Height_over_ocean,Geosync_radius)+multipleoutagesoutput;document.getElementById("outages").innerHTML=multipleoutagesoutput}function PrintSave(){var e;var t=new Date;e=t.getFullYear();PrintWindow=window.open("","Print_window","");PrintWindow.oldWindow=top;var n="GEOSTATIONARY SATELLITE - SUN INTERFERENCE PREDICTIONS REPORT - (C) "+e+" JENS T. STRE http://www.satellite-calculations.com\n";n+="\n";n+="\n";n+="\n";n+="\n";n+='\n
GEOSTATIONARY SATELLITE - SUN INTERFERENCE PREDICTIONS REPORT
(C) "+e+' JENS T. STRE
http://www.satellite-calculations.com
\n';n+='\n
';n+='\n";n+='\n