density art

RELATIVE DENSITY ART

Let’s learn how to create and paint with objects, by moving them around the canvas based on their relative density.

 

What floats and what sinks (buoyancy), and why (relative density), are interesting ideas for young children, that capture their imagination and get them thinking.

Take a tiny pebble and throw it in a pond. It sinks.

Take a big log and throw it in the same pond. It floats.

Why does a big, heavy log float when a tiny, light pebble float?

One grade 1 student replied, “They are made of different stuff.”

 

Will it Sink or Will it Float?

Here is a song called Will it Sink or Will it Float, written by Grades 3/4 students at a math/science summer camp (parody of Should I Stay or Should I Go by the Clash).

       

 

Let’s make it sink & float with code

The coding app we’ll use is shown below.

  • The Canvas (on the left) is where the objects you create will move based on their relative density, and where they will paint.
  • The Coding Area on the right is where you will place code blocks to control the objects.

 

Object 1

Here is the code for Object 1 (with explanatory notes).

Go to researchideas.ca/density .

  • Select Object 1 (as shown at right)
  • Click on Run This Code
  • You should get the image shown below
  • Can you explain why the object moves and paints as it does?

Experiment:

  • make edits to the code of Object 1
  • Click on Run This Code to see the effect

 

Object 2

Here is the code for Object 2.

  • Notice that the relative density of Object 2 is 0.9. What effect will this have?
  • Also, notice that the elasticity of Object 2 is 100. What effect will this have?
  • Lastly, notice the on collision code block. This will have an affect later, when we set 2 objects in motion, and they collide.

Refresh the web page at researchideas.ca/density to erase your previous work.

  • Select Object 2 (as shown at right)
  • Click on Run This Code
  • You should get the image shown below
  • Can you explain why the object moves and paints as it does?

Experiment:

  • make edits to the code of Object 2
  • Click on Run This Code to see the effect

 

Objects 1 and 2

Refresh the web page at researchideas.ca/density to erase your previous work.

  • Select Object 2 (as shown at right)
  • Click on Run All Code, to run the code for both objects

Experiment:

  • make edits to the code of Object 1 and Object 2
  • Click on Run All Code to see the effect

 

USING VARIABLES

Example 1

Enter this code for an object.

The click on Run This Code. You should get this image.

Experiment:

  • make edits to the code
  • Click on Run All Code to see the effect

 

Example 2

Enter this code for an object.

The click on Run This Code. You should get this image.

Experiment:

  • make edits to the code
  • Click on Run All Code to see the effect

 

Write your own code

Write code to create a density/buoyancy artwork.

Click on Save Image to save and share.