; Rock Cycle Diagram Simulation: Cooking Rocks ; Designed for use with ACMES Module 2.1 Rock Cycle ; Montclair State University Fall 2018 ; by Sowmith Etikyala, Toni York, and Jay Singh ; Rock Cycle diagram created October 2018 by Toni York ; Sediment image from Michael C. Rygel's "Ripples" photo found on Wikipedia in October 2018 ; All other images are public domain found on Wikipedia in October 2018 globals [ BackgroundImage ; name of background image to use IngredientVariable ; internal storage of chosen option IngredientToDraw ; filename to draw ProcessVariable ProcessToDraw ResultVariable ResultToDraw DrawShading ShadingShape ShadingColor ShadingSize ShadingX ShadingY ] breed [shades shade] to ResetButton ; check mode and set background accordingly ifelse ModeChooser = "Investigation" [set BackgroundImage "images/background_blanks.png"] [ifelse ModeChooser = "Diagram" [set BackgroundImage "images/background_full.png"][]] ; set other variables set IngredientVariable "None" set IngredientChooser "None" set IngredientToDraw "None" set ProcessVariable "None" set ProcessChooser "None" set ProcessToDraw "None" set ResultVariable "None" set ResultToDraw "None" set DrawShading "False" set ShadingColor [0 110 255 60] ; draw the initial screen DrawScreen end to SelectIngredientButton set IngredientVariable IngredientChooser set ResultVariable "None" set DrawShading "False" DrawScreen end to SelectProcessButton set ProcessVariable ProcessChooser set ResultVariable "None" set DrawShading "False" DrawScreen end to CookButton if (IngredientVariable != "None") and (ProcessVariable != "None") [ FindResult DrawScreen ] end to DrawScreen ; reset background clear-turtles ask patches [ if pxcor > -40 [ set pcolor white ]] import-drawing BackgroundImage ; draw ingredient ifelse IngredientVariable = "None" [set IngredientToDraw "None"] [ifelse IngredientVariable = "Igneous Rock" [set IngredientToDraw "images/ingredient/igneous.png"] [ifelse IngredientVariable = "Sedimentary Rock" [set IngredientToDraw "images/ingredient/sedimentary.png"] [ifelse IngredientVariable = "Metamorphic Rock" [set IngredientToDraw "images/ingredient/metamorphic.png"] [ifelse IngredientVariable = "Sediment" [set IngredientToDraw "images/ingredient/sediment.png"] [ifelse IngredientVariable = "Magma/Lava" [set IngredientToDraw "images/ingredient/magma.png"] []]]]]] if IngredientToDraw != "None" [ import-drawing IngredientToDraw ] ; draw process ifelse ProcessVariable = "None" [set ProcessToDraw "None"] [ifelse ProcessVariable = "Weathering and Erosion" [set ProcessToDraw "images/process/weathering.png"] [ifelse ProcessVariable = "Compacting and Cementing" [set ProcessToDraw "images/process/compacting.png"] [ifelse ProcessVariable = "Heat and Pressure" [set ProcessToDraw "images/process/heat.png"] [ifelse ProcessVariable = "Melting" [set ProcessToDraw "images/process/melting.png"] [ifelse ProcessVariable = "Cooling" [set ProcessToDraw "images/process/cooling.png"] []]]]]] if ProcessToDraw != "None" [ import-drawing ProcessToDraw ] ; draw result ifelse ResultVariable = "None" [set ResultToDraw "None"] [ifelse ResultVariable = "Igneous Rock" [set ResultToDraw "images/result/igneous.png"] [ifelse ResultVariable = "Sedimentary Rock" [set ResultToDraw "images/result/sedimentary.png"] [ifelse ResultVariable = "Metamorphic Rock" [set ResultToDraw "images/result/metamorphic.png"] [ifelse ResultVariable = "Sediment" [set ResultToDraw "images/result/sediment.png"] [ifelse ResultVariable = "Magma/Lava" [set ResultToDraw "images/result/magma.png"] [ifelse ResultVariable = "X" [set ResultToDraw "images/result/x.png"] []]]]]]] if ResultToDraw != "None" [ import-drawing ResultToDraw ] ; draw shading if DrawShading = "True" [ create-shades 1 [ set shape ShadingShape set color ShadingColor set size ShadingSize setxy ShadingX ShadingY set heading 0 ] ] end to FindResult ; start with no shading set DrawShading "False" ; then do logic based on ingredient and process variables to choose result and set shading (if necessary) ; igneous rock ifelse IngredientVariable = "Igneous Rock" [ ifelse ProcessVariable = "Weathering and Erosion" [ set ResultVariable "Sediment" set DrawShading "True" set ShadingShape "shade-igneous-weathering" set ShadingSize 20 set ShadingX 0 set ShadingY -7 ] [ifelse ProcessVariable = "Compacting and Cementing" [set ResultVariable "X"] [ifelse ProcessVariable = "Heat and Pressure" [ set ResultVariable "Metamorphic Rock" set DrawShading "True" set ShadingShape "shade-igneous-heat" set ShadingSize 20 set ShadingX 5 set ShadingY 0 ] [ifelse ProcessVariable = "Melting" [ set ResultVariable "Magma/Lava" set DrawShading "True" set ShadingShape "shade-igneous-melting" set ShadingSize 20 set ShadingX 10 set ShadingY -5 ] [ifelse ProcessVariable = "Cooling" [set ResultVariable "X"] []]]]]] ; sedimentary rock [ifelse IngredientVariable = "Sedimentary Rock" [ ifelse ProcessVariable = "Weathering and Erosion" [ set ResultVariable "Sediment" set DrawShading "True" set ShadingShape "shade-sedimentary-weathering" set ShadingSize 20 set ShadingX -10 set ShadingY -5 ] [ifelse ProcessVariable = "Compacting and Cementing" [set ResultVariable "X"] [ifelse ProcessVariable = "Heat and Pressure" [ set ResultVariable "Metamorphic Rock" set DrawShading "True" set ShadingShape "shade-sedimentary-heat" set ShadingSize 20 set ShadingX -4 set ShadingY 5 ] [ifelse ProcessVariable = "Melting" [ set ResultVariable "Magma/Lava" set DrawShading "True" set ShadingShape "shade-sedimentary-melting" set ShadingSize 30 set ShadingX 0 set ShadingY 10 ] [ifelse ProcessVariable = "Cooling" [set ResultVariable "X"] []]]]]] ; metamorphic rock [ifelse IngredientVariable = "Metamorphic Rock" [ ifelse ProcessVariable = "Weathering and Erosion" [ set ResultVariable "Sediment" set DrawShading "True" set ShadingShape "shade-metamorphic-weathering" set ShadingSize 20 set ShadingX -6 set ShadingY 3 ] [ifelse ProcessVariable = "Compacting and Cementing" [set ResultVariable "X"] [ifelse ProcessVariable = "Heat and Pressure" [ set ResultVariable "Metamorphic Rock" set DrawShading "True" set ShadingShape "shade-metamorphic-heat" set ShadingSize 9 set ShadingX 0 set ShadingY 10 ] [ifelse ProcessVariable = "Melting" [ set ResultVariable "Magma/Lava" set DrawShading "True" set ShadingShape "shade-metamorphic-melting" set ShadingSize 20 set ShadingX 3 set ShadingY 5 ] [ifelse ProcessVariable = "Cooling" [set ResultVariable "X"] []]]]]] ; sediment [ifelse IngredientVariable = "Sediment" [ ifelse ProcessVariable = "Weathering and Erosion" [set ResultVariable "X"] [ifelse ProcessVariable = "Compacting and Cementing" [ set ResultVariable "Sedimentary Rock" set DrawShading "True" set ShadingShape "shade-sediment-compacting" set ShadingSize 20 set ShadingX -10 set ShadingY -5 ] [ifelse ProcessVariable = "Heat and Pressure" [set ResultVariable "X"] [ifelse ProcessVariable = "Melting" [set ResultVariable "X"] [ifelse ProcessVariable = "Cooling" [set ResultVariable "X"] []]]]]] ; magma [ifelse IngredientVariable = "Magma/Lava" [ ifelse ProcessVariable = "Weathering and Erosion" [set ResultVariable "X"] [ifelse ProcessVariable = "Compacting and Cementing" [set ResultVariable "X"] [ifelse ProcessVariable = "Heat and Pressure" [set ResultVariable "X"] [ifelse ProcessVariable = "Melting" [set ResultVariable "X"] [ifelse ProcessVariable = "Cooling" [ set ResultVariable "Igneous Rock" set DrawShading "True" set ShadingShape "shade-magma-cooling" set ShadingSize 20 set ShadingX 10 set ShadingY -5 ] []]]]]] []]]]] end @#$#@#$#@ GRAPHICS-WINDOW 369 18 1027 518 -1 -1 15.854 1 10 1 1 1 0 0 0 1 -20 20 -15 15 0 0 1 ticks 30.0 BUTTON 264 389 345 432 Cook! CookButton NIL 1 T OBSERVER NIL NIL NIL NIL 1 CHOOSER 40 200 251 245 IngredientChooser IngredientChooser "None" "Igneous Rock" "Sedimentary Rock" "Metamorphic Rock" "Sediment" "Magma/Lava" 0 CHOOSER 40 296 251 341 ProcessChooser ProcessChooser "None" "Weathering and Erosion" "Compacting and Cementing" "Heat and Pressure" "Melting" "Cooling" 0 TEXTBOX 39 177 352 198 2. Choose an ingredient and click Select. 15 0.0 1 TEXTBOX 40 275 358 300 3. Choose a process and click Select. 15 0.0 1 BUTTON 265 107 345 149 Reset ResetButton NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 266 202 346 244 Select SelectIngredientButton NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 266 297 346 342 Select SelectProcessButton NIL 1 T OBSERVER NIL NIL NIL NIL 1 TEXTBOX 37 83 341 104 1. Select a mode and click Reset. 15 0.0 1 TEXTBOX 40 367 336 386 4. Click Cook! 15 0.0 1 CHOOSER 40 104 249 149 ModeChooser ModeChooser "Investigation" "Diagram" 0 @#$#@#$#@ ## WHAT IS IT? This is an interactive simulation that shows different ways a rock is transformed in the rock cycle. The user can choose a specific rock and a specific process applied to the rock to test out it's reaction. ## HOW TO USE IT The user will click either investigation or diagram based on their learning preferences. Then click reset and choose the type of rock and the type of process and click select. This will outline the process on the screen and show the user the rock's transformation. ## HOW TO CITE If you mention this model or the NetLogo software in a publication, we ask that you include the citations below. For the simulation itself: ACMES Group (2018). NetLogo Water Cycle simulation. Assimilating Computational and Mathematical Thinking into Earth and Environmental Science. Montclair State University, Montclair, NJ. Please cite the NetLogo software as: * Wilensky, U. (1999). NetLogo. http://ccl.northwestern.edu/netlogo/. Center for Connected Learning and Computer-Based Modeling, Northwestern University, Evanston, IL. ## COPYRIGHT AND LICENSE Copyright 2018 ACMES Group at Montclair State University This work is licensed under the GNU GENERAL PUBLIC LICENSE V3. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. To view the details of the license, you can visit https://www.gnu.org/licenses/gpl.html. Acknowledgment This research is supported through a STEM+Computing grant from the Division of Research on Learning of the National Science Foundation (# 1742125). @#$#@#$#@ default true 0 Polygon -7500403 true true 150 5 40 250 150 205 260 250 shade-igneous-heat true 0 Polygon -7500403 true true 0 0 0 60 90 60 105 270 225 270 225 210 150 210 135 0 60 0 shade-igneous-melting true 0 Polygon -7500403 true true 15 195 45 120 105 -15 210 -15 150 105 135 150 135 195 shade-igneous-weathering true 0 Polygon -7500403 true true -45 90 315 90 315 180 240 180 -45 180 shade-magma-cooling true 0 Polygon -7500403 true true 90 15 90 45 165 60 165 135 165 105 150 120 135 135 120 135 90 135 75 135 60 135 30 135 30 195 90 195 120 195 180 195 210 180 225 165 210 195 240 135 240 90 240 45 195 0 150 -15 90 -15 90 15 shade-metamorphic-heat false 0 Rectangle -7500403 true true 30 30 270 270 shade-metamorphic-melting true 0 Polygon -7500403 true true 225 75 270 75 270 150 270 195 240 195 195 195 195 165 180 135 30 135 30 135 30 105 30 75 105 75 Polygon -7500403 true true 180 180 shade-metamorphic-weathering true 0 Polygon -7500403 true true 180 210 105 270 45 300 165 300 255 45 180 45 shade-sediment-compacting true 0 Polygon -7500403 true true 45 -15 165 -15 150 90 165 135 225 135 240 165 225 195 135 195 90 195 shade-sedimentary-heat true 0 Polygon -7500403 true true 90 180 -30 195 -30 150 45 120 45 75 255 75 285 120 180 135 150 135 135 135 120 135 shade-sedimentary-melting true 0 Polygon -7500403 true true 60 225 -15 225 -15 180 -15 135 -15 105 -15 90 30 60 105 60 195 60 300 60 300 225 210 225 210 195 270 180 270 120 180 120 135 120 120 120 90 120 60 120 30 135 30 180 75 195 75 210 75 225 shade-sedimentary-weathering true 0 Polygon -7500403 true true 45 -15 150 -15 195 15 240 60 240 165 240 165 195 195 90 195 90 135 180 135 150 90 150 45 45 45 45 30 @#$#@#$#@ NetLogo 6.0.2 @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ default 0.0 -0.2 0 0.0 1.0 0.0 1 1.0 0.0 0.2 0 0.0 1.0 link direction true 0 Line -7500403 true 150 150 90 180 Line -7500403 true 150 150 210 180 @#$#@#$#@ 0 @#$#@#$#@