N-gones - Slow version: Difference between revisions

From JSXGraph Wiki
No edit summary
No edit summary
Line 4: Line 4:
<script type="text/javascript" src="http://jsxgraph.uni-bayreuth.de/distrib/jsxgraphcore.js"></script>
<script type="text/javascript" src="http://jsxgraph.uni-bayreuth.de/distrib/jsxgraphcore.js"></script>
<form><textarea id="inputtext" rows=12 cols=35 wrap="off" style="width:600px;">
<form><textarea id="inputtext" rows=12 cols=35 wrap="off" style="width:600px;">
/*
function mn_eck(ne,sz) {
function mn_eck(ne,sz) {
   for(var i=ne;i>0;i--) {
   for(var i=ne;i>0;i--) {
Line 13: Line 14:
   }
   }
}
}
*/
function outerloop(ne,sz) {
  t.rt(360/ne);
  for(var j=ne;j>0;j--) {
    t.rt(360/ne);
    t.fd(sz);
  }
  setTimeout('outerloop('+ne+','+sz+')',25);
}
function mn_eck(ne,sz) {
}
t.cs().hideTurtle().setProperty({strokeWidth:4,strokeOpacity:0.6,fillOpacity:0.3});
t.cs().hideTurtle().setProperty({strokeWidth:4,strokeOpacity:0.6,fillOpacity:0.3});
mn_eck(7,80);
mn_eck(7,80);

Revision as of 16:02, 25 February 2009