# Difference between revisions of "Colorful circles"

From JSXGraph Wiki

Jump to navigationJump to searchA WASSERMANN (talk | contribs) |
A WASSERMANN (talk | contribs) |
||

Line 4: | Line 4: | ||

− | for (i=0;i< | + | for (i=0;i<20;i++) { |

+ | var h = Math.random()*360; | ||

+ | var s = Math.random(); | ||

+ | var v = Math.random(); | ||

brd.createElement('point',[Math.random(),Math.random()], | brd.createElement('point',[Math.random(),Math.random()], | ||

− | {withLabel:false, face:'circle', size:Math.random()*100}); | + | {withLabel:false, face:'circle', |

+ | size:Math.random()*100, | ||

+ | strokeColor:brd.hsv2rgb(h,s,v), | ||

+ | fillColor:brd.hsv2rgb((h+180)%360,s,v) | ||

+ | |||

+ | }); | ||

} | } | ||

</jsxgraph> | </jsxgraph> |