Polygon II: Difference between revisions

From JSXGraph Wiki
No edit summary
No edit summary
Line 4: Line 4:
var c1 = brd.create('circle',[p1,2],{strokeOpacity:0.1});
var c1 = brd.create('circle',[p1,2],{strokeOpacity:0.1});
var p2 = brd.create('glider',[1,-1,c1]);
var p2 = brd.create('glider',[1,-1,c1]);
var rot = brd.create('transform',[function(){ return Math.atan2(p2.Y()-p1.Y(),p2.X()-p1.X()) + Math.PI/4;},p1],{type:'rotate'});
var p3 = brd.create('point',[rot,p2],{fixed:true});
//var c2 = brd.create('circle',[p1,Math.sqrt(0.5*0.5+1.0)],{strokeOpacity:0.1});
//var p3 = brd.create('glider',[0,0.5,c2],{fixed:true});




var c2 = brd.create('circle',[p1,Math.sqrt(0.5*0.5+1.0)],{strokeOpacity:0.1});
var p3 = brd.create('glider',[0,0.5,c2],{fixed:true});
//var rot = brd.create('transform',[function(){ return Math.atan2(p2.Y()-p1.Y(),p2.X()-p1.X());},p1],{type:'rotate'});
//rot.bindTo(p3);
//rot.bindTo(p3);



Revision as of 11:23, 3 March 2010