Google Classroom
GeoGebraGeoGebra Classroom

GeoGebra snow

Information

This simulation has 20 GGB snowflakes Here is another one with 40 GGB snowflakes: GeoGebra snowing It runs better offline: Download GeoGebra snowing

Scripting button

# Before we must add the picture centred at the origin # I used this one: https://wiki.geogebra.org/uploads/1/11/GeoGebra.svg # Then create a Setup button with the following script Ln = 1...20 Execute( Zip( "posX"+i+" = Slider(-50, 50, 0.01, 1, 200, false, true, false, false)", i, Ln ) ) Execute( Zip( "SetVisibleInView( posX"+i+", 1, false )", i, Ln) ) Execute( Zip( "SetValue( posX"+i+", RandomBetween(-50, 50) )", i, Ln) ) Execute( Zip( "posY"+i+" = Slider(-100, 100, 0.01, 1, 200, false, true, false, false)", i, Ln ) ) Execute( Zip( "SetVisibleInView( posY"+i+", 1, false )", i, Ln) ) Execute( Zip( "SetValue( posY"+i+", 50 )", i, Ln) ) Execute( Zip( "initialAngle"+i+" = RandomUniform(0, 2 * pi)", i, Ln ) ) Execute( Zip( "size"+i+" = RandomUniform(0.3, 1.2)", i, Ln ) ) Execute( Zip( "radius"+i+" = RandomUniform(0, 10^2)", i, Ln ) ) # Angular velocity Execute( Zip( "w"+i+" = RandomBetween(1, 3)", i, Ln ) ) # time time = 0 Execute( Zip( "angle"+i+" = w"+i+" * time + initialAngle"+i+"", i, Ln ) ) run = Slider(0, 1, 0.01, 1, 200, false, true, false, false) Execute( Zip( "T"+i+" = Translate( Rotate( Dilate( pic1, size"+i+"), 2*pi*sin(angle"+i+") ), Vector( (posX"+i+", posY"+i+") ) )", i, Ln) )

Scripting Slider

# In the slider named "run" add this script in the tab On Update SetValue(time, time + 0.01) #Execute( Zip("" , i, Ln) ) Execute( Zip(" SetValue(angle"+i+", w"+i+" * time + initialAngle"+i+") " , i, Ln) ) Execute( Zip(" SetValue(posX"+i+", 20 + radius"+i+" * sin(angle"+i+")) " , i, Ln) ) Execute( Zip(" SetValue(posY"+i+", posY"+i+" - (size"+i+")^(1/2)) " , i, Ln) ) Execute( Zip(" If( posY"+i+" < -20, SetValue(posY"+i+", RandomBetween(50, 60))) " , i, Ln) ) Execute( Zip(" If( posY"+i+" < -20, SetValue(posX"+i+", RandomBetween(-50, 50))) " , i, Ln) )

GIF with 40 snowflakes

GIF with 40 snowflakes