Turtle spiral: Difference between revisions
From JSXGraph Wiki
A WASSERMANN (talk | contribs) No edit summary |
A WASSERMANN (talk | contribs) No edit summary |
||
Line 47: | Line 47: | ||
* Hints how to "[[Slow the turtle down]]" | * Hints how to "[[Slow the turtle down]]" | ||
* [http://www.geogebra.org/de/wiki/index.php/Turtlegrafik Compare with GeoGebra] | |||
[[Category:Examples]] | [[Category:Examples]] | ||
[[Category:Turtle Graphics]] | [[Category:Turtle Graphics]] |
Revision as of 16:38, 25 March 2009
Source code
<jsxgraph width="600" height="600">
var brd = JXG.JSXGraph.initBoard('jxgbox', {originX: 300, originY: 300, unitX: 1, unitY: 1});
var t = brd.createElement('turtle');
function run() {
brd.suspendUpdate();
var code = $('inputtext').value;
if (code=='') { return; }
eval(code);
brd.unsuspendUpdate();
}
function clearturtle() {
t.cs();
}
</jsxgraph>
- Hints how to "Slow the turtle down"
- Compare with GeoGebra