
if(parent.frames.length>0)
{
	document.location.href="../mathekurse.htm";
}

function plot(f,x0,x1,y0,y1)
{
	if(parent.frames[2].location.href.indexOf("plotter.htm")>-1)
		frames[2].window.bsp(f,x0,x1,y0,y1);
	else if(navigator.appName.indexOf("etsc")>-1)
	{
		var t=frames[2].location.href;
		var i=t.indexOf("/mathe/");
		frames[2].location.href=t.substr(0,i+7)+"java/plotter.htm";
		window.setTimeout("plotbsp('"+f+"',"+x0+","+x1+","+y0+","+y1+")",1000);	
	}
	else
	{
		var t=frames[2].location.href;
		var i=t.indexOf("/mathe/");
		frames[2].location.href=t.substr(0,i+7)+"java/plotter.htm#bsp("+f+","+x0+","+x1+","+y0+","+y1+")";	
	}
	
}
function plotbsp(f,x0,x1,y0,y1)
{
	if(frames[2].document.plotter==null){window.setTimeout("plotbsp('"+f+"',"+x0+","+x1+","+y0+","+y1+")",500);return;}
	frames[2].document.f.autodemo.checked=false;
	window.setTimeout("plotbsp1('"+f+"',"+x0+","+x1+","+y0+","+y1+")",500);
}
function plotbsp1(f,x0,x1,y0,y1)
{
	frames[2].window.bsp(f,x0,x1,y0,y1);
	window.setTimeout("plotbsp2('"+f+"',"+x0+","+x1+","+y0+","+y1+")",2000);
}
function plotbsp2(f,x0,x1,y0,y1)
{
	if(frames[2].window.document.f.term.value!=f)frames[2].window.bsp(f,x0,x1,y0,y1);
}

