/* Programmed by Michihiro Teshiba - teshiba at ou dot edu */
//
/* Link name, position, and title */
//
function menu() {
	menuName = new Array("ARRC","Research","Education","About", "OU'", "RIL");
	menuHref = new Array("/", "/research","/education","/about","/ouprime/OUPRIME_UserFlyer.pdf", "/ril"); // Need slash at the first character
	menuTitle = new Array("ARRC","Research Activities","Educational Activities","About Us","OU PRIME", "Radar Innovations Laboratory");
	projName = new Array("Wind Turbine","M-PAR","DEPSCoR");
	projHref = new Array("/turbine","/mpar","/depscor"); // Need slash at the first character
	projTitle = new Array("Significance and Mitigation of Wind Turbine Clutter for the WSR-88D Network",
	"Development and Application of a Multi-Function Phased Array Radar",
	"Defense Experimental Program to Stimulate Competitive Research");
	menuloc();
}
//
/* for sidelist */
//
function listAbout() {
	tag = 0;
	myName = new Array("About Us","Members","Sitemap");
	myHref = new Array(".","members.htm","sitemap.htm");
	myTitle = new Array("About Us","Members of ARRC","Sitemap");
	sidelist();
}
function listRes() {
	tag = 0;
	myName = new Array("Research Areas","Publications","Seminar Series");
	myHref = new Array(".","public.php","/education/seminar.htm");
	myTitle = new Array("Research Areas","Publication List","Atmospheric Radar Research Seminar");
	sidelist();
}
function listEdu() {
	tag = 0;
	myName = new Array("Announcement","Goals","Course Development Effort","Laboratory Modules","Seminar Series");
	myHref = new Array(".","goal.htm","effort.htm","/modules/index.php","seminar.htm");
	myTitle = new Array("Announcement of Courses","General Philosophy and Goals","Course Development Effort","Laboratory Modules","Atmospheric Radar Research Seminar");
	sidelist();
}
function listRIL() {
	tag = 0;
	myName = new Array("Radar Innovations Laboratory","Floor Plan", "Capabilities","Members","Advisory Committee");
	myHref = new Array(".","planview.htm","cap.htm","members.htm","commit.htm");
	myTitle = new Array("Radar Innovation Laboratory","Floor Plan","Capabilites","Members","Advisory Committee");
	sidelist();
}
//
/* Wind Turbine Clutter */
//
function listTurbine() {
	tag = 0;
	myName = new Array("<h3>Wind Turbine Project</h3>","<h3>Introduction</h3>","<h3>Research Topics</h3>","<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("/turbine/","/turbine/intro.htm","/turbine/climat.htm","/turbine/ref.htm","/turbine/people.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation","Research Topics","Reference List","About Us");
	sidelistNoBG();
}
function listTurbineIntro() {
	tag = 0;
	myName = new Array("<h3>Wind Turbine Project</h3>");
	myHref = new Array(".");
	myTitle = new Array("Start from Here");
	sidelistNoBG();
	document.writeln("<h3>Introduction</h3>");
	myName = new Array("Motivation","Characteristics");
	myHref = new Array("intro.htm","char.htm");
	myTitle = new Array("Introduction and Motivation","Characteristics of Wind Turbines and Their Clutter Signature");
	sidelist();
	myName = new Array("<h3>Research Topics</h3>","<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("climat.htm","ref.htm","people.htm");
	myTitle = new Array("Research Topics","Reference List","People");
	sidelistNoBG();
}
function listTurbineRes() {
	tag = 0;
	myName = new Array("<h3>Wind Turbine Project</h3>","<h3>Introduction</h3>");
	myHref = new Array(".","intro.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation");
	sidelistNoBG();
	document.writeln("<h3>Research Topics</h3>");
	myName = new Array("Climatology","Adaptive Signal Processing");
	myHref = new Array("climat.htm","signal.htm");
	myTitle = new Array("Climatology","Adaptive Signal Processing");
	sidelist();
	myName = new Array("<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("ref.htm","people.htm");
	myTitle = new Array("Reference List","People");
	sidelistNoBG();
}
function listTurbineRef() {
	tag = 0;
	myName = new Array("<h3>Wind Turbine Project</h3>","<h3>Introduction</h3>","<h3>Research Topics</h3>");
	myHref = new Array(".","intro.htm","climat.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation","Research Topics");
	sidelistNoBG();
	document.writeln("<h3>References</h3>");
	myName = new Array("List");
	myHref = new Array("ref.htm");
	myTitle = new Array("Reference List");
	sidelist();
	myName = new Array("<h3>About</h3>");
	myHref = new Array("people.htm");
	myTitle = new Array("People");
	sidelistNoBG();
}
function listTurbineAbout() {
	tag = 0;
	myName = new Array("<h3>Wind Turbine Project</h3>","<h3>Introduction</h3>","<h3>Research Topics</h3>","<h3>References</h3>");
	myHref = new Array(".","intro.htm","climat.htm","ref.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation","Research Topics","Reference List");
	sidelistNoBG();
	document.writeln("<h3>About</h3>");
	myName = new Array("People","Scheduled Meetings");
	myHref = new Array("people.htm","meeting.htm");
	myTitle = new Array("Associate People","Scheduled Meetings");
	sidelist();
}
//
/* M-PAR */
//
function listMPARIntro() {
	tag = 0;
	myName = new Array("<h3>M-PAR Project</h3>");
	myHref = new Array(".");
	myTitle = new Array("Start from Here");
	sidelistNoBG();
	document.writeln("<h3>Introduction</h3>");
	myName = new Array("Motivation","Instruments");
	myHref = new Array("intro.htm","inst.htm");
	myTitle = new Array("Introduction and Motivation","Instruments - PAR &amp; Radar Simulator");
	sidelist();
	document.writeln("<h3>Research Topics</h3>");
	myName = new Array("<h4>Advancing NWRT Capabilities</h4>","<h4>System Optimization</h4>","<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("retrieve.htm","multi.htm","ref.htm","people.htm");
	myTitle = new Array("Advancing NWRT Capabilities","System Optimization","Reference List","People");
	sidelistNoBG();
}
function listMPARNWRT() {
	tag = 0;
	myName = new Array("<h3>M-PAR Project</h3>","<h3>Introduction</h3>");
	myHref = new Array(".","intro.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation");
	sidelistNoBG();
	document.writeln("<h3>Research Topics</h3>");
	document.writeln("<h4>Advancing NWRT Capabilities</h4>");
	myName = new Array("Refractivity Retrieval","Weather Radar Interferometry","Aircraft Tracking");
	myHref = new Array("retrieve.htm","interf.htm","track.htm");
	myTitle = new Array("Refractivity Retrieval","Weather Radar Interferometry","Aircraft Tracking");
	sidelist();
	myName = new Array("<h4>System Optimization</h4>","<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("multi.htm","ref.htm","people.htm");
	myTitle = new Array("System Optimization","Reference List","People");
	sidelistNoBG();
}
function listMPARSys() {
	tag = 0;
	myName = new Array("<h3>M-PAR Project</h3>","<h3>Introduction</h3>");
	myHref = new Array(".","intro.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation");
	sidelistNoBG();
	document.writeln("<h3>Research Topics</h3>");
	myName = new Array("<h4>Advancing NWRT Capabilities</h4>");
	myHref = new Array("retrieve.htm");
	myTitle = new Array("Advancing NWRT Capabilites");
	sidelistNoBG();
	document.writeln("<h4>System Optimization</h4>");
	myName = new Array("Beam Multiplexing","Adaptive Array Processing","Waveform Design");
	myHref = new Array("multi.htm","array.htm","wave.htm");
	myTitle = new Array("Beam Multiplexing","Adaptive Array Processing","Waveform Design");
	sidelist();
	myName = new Array("<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("ref.htm","people.htm");
	myTitle = new Array("Reference List","People");
	sidelistNoBG();
}
function listMPARRef() {
	tag = 0;
	myName = new Array("<h3>M-PAR Project</h3>","<h3>Introduction</h3>");
	myHref = new Array(".","intro.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation");
	sidelistNoBG();
	document.writeln("<h3>Research Topics</h3>");
	myName = new Array("<h4>Advancing NWRT Capabilities</h4>","<h4>System Optimization</h4>");
	myHref = new Array("retrieve.htm","multi.htm");
	myTitle = new Array("Advancing NWRT Capabilities","System Optimization");
	sidelistNoBG();
	document.writeln("<h3>References</h3>");
	myName = new Array("List","Related Links");
	myHref = new Array("ref.htm","link.htm");
	myTitle = new Array("Reference List","Related Links");
	sidelist();
	myName = new Array("<h3>About</h3>");
	myHref = new Array("people.htm");
	myTitle = new Array("People");
	sidelistNoBG();
}
function listMPARAbout() {
	tag = 0;
	myName = new Array("<h3>M-PAR Project</h3>","<h3>Introduction</h3>");
	myHref = new Array(".","intro.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation");
	sidelistNoBG();
	document.writeln("<h3>Research Topics</h3>");
	myName = new Array("<h4>Advancing NWRT Capabilities</h4>","<h4>System Optimization</h4>");
	myHref = new Array("retrieve.htm","multi.htm");
	myTitle = new Array("Advancing NWRT Capabilities","System Optimization");
	sidelistNoBG();
	myName = new Array("<h3>References</h3>");
	myHref = new Array("ref.htm");
	myTitle = new Array("Reference List");
	sidelistNoBG();
	document.writeln("<h3>About</h3>");
	myName = new Array("People","Presentation Files");
	myHref = new Array("people.htm","meeting.htm");
	myTitle = new Array("People","Presentation Files");
	sidelist();
}
//
/* DEPSCoR */
//
function listDEPSIntro() {
	tag = 0;
	myName = new Array("<h3>DEPSCoR Project</h3>");
	myHref = new Array(".");
	myTitle = new Array("Start from Here");
	sidelistNoBG();
	document.writeln("<h3>Introduction</h3>");
	myName = new Array("Motivation");
	myHref = new Array("intro.htm");
	myTitle = new Array("Introduction and Motivation");
	sidelist();
	myName = new Array("<h3>Research Topics</h3>","<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("enkf.htm","ref.htm","people.htm");
	myTitle = new Array("Research Topics","Reference List","People");
	sidelistNoBG();
}
function listDEPSRes() {
	tag = 0;
	myName = new Array("<h3>DEPSCoR Project</h3>","<h3>Introduction</h3>");
	myHref = new Array(".","intro.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation");
	sidelistNoBG();
	document.writeln("<h3>Research Topics</h3>");
	myName = new Array("EnKF System","OSSE","Beam Multiplexing","Cross-beam Wind Estimation");
	myHref = new Array("enkf.htm","osse.htm","multi.htm","wind.htm");
	myTitle = new Array("Establish the EnKF System","Observing System Simulation Experiment","Beam Multiplexing","Cross-beam Wind Estimation Using SA Method");
	sidelist();
	myName = new Array("<h3>References</h3>","<h3>About</h3>");
	myHref = new Array("ref.htm","people.htm");
	myTitle = new Array("Reference List","People");
	sidelistNoBG();
}
function listDEPSRef() {
	tag = 0;
	myName = new Array("<h3>DEPSCoR Project</h3>","<h3>Introduction</h3>","<h3>Research Topics</h3>");
	myHref = new Array(".","intro.htm","enkf.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation","Research Topics");
	sidelistNoBG();
	document.writeln("<h3>References</h3>");
	myName = new Array("List","Related Links");
	myHref = new Array("ref.htm","link.htm");
	myTitle = new Array("Reference List","Related Links");
	sidelist();
	myName = new Array("<h3>About</h3>");
	myHref = new Array("people.htm");
	myTitle = new Array("People");
	sidelistNoBG();
}
function listDEPSAbout() {
	tag = 0;
	myName = new Array("<h3>DEPSCoR Project</h3>","<h3>Introduction</h3>","<h3>Research Topics</h3>","<h3>References</h3>");
	myHref = new Array(".","intro.htm","enkf.htm","ref.htm");
	myTitle = new Array("Start from Here","Introduction and Motivation","Research Topics","Reference List");
	sidelistNoBG();
	document.writeln("<h3>About</h3>");
	myName = new Array("People","Scheduled Meetings");
	myHref = new Array("people.htm","meeting.htm");
	myTitle = new Array("Associate People","Scheduled Meetings");
	sidelist();
}
//
/* Global Functions */
//
function loc() {
	pos0 = location.pathname;
	pos1 = new Array();
	pos2 = pos0.split("\/");
	nPos = pos2.length;
	n = 0;
	for (j=0; j<nPos; j++) {
		if (pos2[j]) {
			pos1[n] = pos2[j]
			n++;
		}
	}
	pos = new Array();
	ns = 0;
	if (pos1[ns]) {
		pos[ns] = "\/"+pos1[ns];
	} else {
		pos[ns] = "\/";
	}
	if (pos1[ns+1]) {
		pos[ns+1] = pos1[ns+1];
	} else {
		pos[ns+1] = "";
	}
	if (pos1[ns+2]) {
		pos[ns+2] = pos1[ns+2];
	} else {
		pos[ns+2] = "";
	}
	return;
}
function menuloc() {
	loc();
	document.writeln("<ul>");
	nName = menuName.length;
	for (j=0; j<nName; j++) {
		if (menuHref[j] == pos[ns] || menuHref[j] == "") {
			document.writeln("<li class='current'><a title='You are here: "+menuTitle[j]+"'>"+menuName[j]+"<\/a><\/li>");
		} else {
			document.writeln("<li><a href='"+menuHref[j]+"' title='"+menuTitle[j]+"'>"+menuName[j]+"<\/a><\/li>");
		}
	}
	document.writeln("<li><a class='divide'><\/a><\/li>");
	nName = projName.length;
	for (j=0; j<nName; j++) {
		if (projHref[j] == pos[ns] || projHref[j] == "") {
			document.writeln("<li class='current'><a title='You are here: "+projTitle[j]+"'>"+projName[j]+"<\/a><\/li>");
		} else {
			document.writeln("<li><a href='"+projHref[j]+"' title='"+projTitle[j]+"'>"+projName[j]+"<\/a><\/li>");
		}
	}
	document.writeln("<\/ul>");
}
//
/* For Sidelist */
//
function sidelist() {
	document.writeln("<ul>");
	nName = myName.length;
	if (pos[ns+1] == "" && tag == 0) {
		document.writeln("<li class='currentli'><a title='You are here: "+myTitle[0]+"'>"+myName[0]+"<\/a><\/li>");
		for (j=1; j<nName; j++) {
			document.writeln("<li><a href='"+myHref[j]+"' title='"+myTitle[j]+"'>"+myName[j]+"<\/a><\/li>");
		}
	} else {
		for (j=0; j<nName; j++) {
			if (myHref[j] == pos[ns+1] || myHref[j] == "") {
				document.writeln("<li class='currentli'><a title='You are here: "+myTitle[j]+"'>"+myName[j]+"<\/a><\/li>");
			} else {
				document.writeln("<li><a href='"+myHref[j]+"' title='"+myTitle[j]+"'>"+myName[j]+"<\/a><\/li>");
			}
		}
	}
	document.writeln("<\/ul>");
}
//
/* For sidelist - don't use background image */
//
function sidelistNoBG() {
	document.writeln("<ul>");
	nName = myName.length;
	for (j=0; j<nName; j++) {
		if (myHref[j] == pos[ns+1] || myHref[j] == "") {
			document.writeln("<li class='nobg currentli'><a title='You are here: "+myTitle[j]+"'>"+myName[j]+"<\/a><\/li>");
		} else {
			document.writeln("<li class='nobg'><a href='"+myHref[j]+"' title='"+myTitle[j]+"'>"+myName[j]+"<\/a><\/li>");
		}
	}
	document.writeln("<\/ul>");
}
//
/* Footer - Copyright */
//
function copyright() {
	// Technically, wouldn't this be the year on the client's computer?
	myD = new Date();
	myYear = myD.getYear();
	myYears = ( myYear < 2000 ) ? myYear+1900 : myYear;
	document.write("<div id='logo'><img src='/images/logo.gif' alt='ARRC' title='ARRC'/><\/div>");
	document.write("<div id='footmenu'>");
	menu();
	document.write("<\/div>");
	document.write("<div id='add'>");
	document.write("<a href='/'>Atmospheric Radar Research Center<\/a>, <a href='http://www.ou.edu/' target='_blank'>University of Oklahoma<\/a><br \/>");
	document.write("120 David L. Boren Blvd., Suite 4610, Norman, OK 73072-7307<br \/>");
	document.write("Phone: (405) 325-5094 / Fax: (405) 325-7689<\/div>");
	document.write("<div id='cri'>Copyright &copy; 2005-"+myYears+" / ");
	document.write("<a href='http://www.ou.edu/ouweb/disclaimer/' target='_blank'>Disclaimer<\/a> - <a href='http://www.ou.edu/ouweb/disclaimer/copyright.html' target='_blank'>Copyright<\/a> about the <a href='/'>Website<\/a><\/div>");
}
//
/* Top image */
//
function images() {
	for (i=0; i<2; i++) {
		n = Math.floor(Math.random()*11)+1;
		document.write("<img id='shade"+i+"' src='images/top/img"+n+".jpg'/>");
	}
	new Effect.Fade($("shade"),{ from:0, to:1 });
	new Effect.Fade($("shade0"),{ from:0, to:1 });
	new Effect.Fade($("shade1"),{ from:0, to:1 });
}
