
clear greatcircle
function greatcircle(e1,e2,style)
	theta = atan(e2(3),e1(3));
	t = (theta-%pi/2):0.01:(theta+%pi/2);
	plot(e1(1)*cos(t)+e2(1)*sin(t),e1(2)*cos(t)+e2(2)*sin(t),'r-');
	if ( style > 0) then
		t = (theta+%pi/2):0.01:(theta+3*%pi/2);
		plot(e1(1)*cos(t)+e2(1)*sin(t),e1(2)*cos(t)+e2(2)*sin(t),'r:');
	end
endfunction


clf

t=0:0.01:2*%pi;
plot(cos(t),sin(t),'k-');

//(1,1,1)/sqrt(3) (2,-1,-1)/sqrt(6)
greatcircle([-2,2,-1]/sqrt(9),[1,2,2]/sqrt(9),1);
greatcircle([1,1,-2]/sqrt(6),[0,2,1]/sqrt(5),1);
greatcircle([1,1,-2]/sqrt(6),[2,0,1]/sqrt(5),1);

a=gca();
a.box="off"; a.isoview="on"; a.axes_visible=["off","off","off"];


xs2pdf(0,'circle.pdf');
