Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

SESSION 2 RESOURCES

Session 2 Resources

PHYSICS ASSIGNMENT INSTRUCTIONS


1: Project Specifications

The goal of this assignment is to use Newtons 2nd Law of Motion in your code. Feel free to start from the
examples provided. Some ideas are:

Re-work your assignment from session 1 to use the concept of forces and an applyForce() function.

Reverse gravity and create a simulation of a helium-filled balloon floating upward. What else can
you add? A wind force which changes over time, perhaps according to Perlin noise?

Instead of particles bouncing off the edges of the screen, can you create a force that pushes them
inward as they approach the edges? Can you weight the force according to how far the object is from
an edge, i.e. the closer it is, the stronger the force?

Create areas (circles? rectangles?) of drag resistance that affect particles as they intersect those
areas. What if you make some of them apply a force opposite to drag and speed up the particles?

Create a simulation where many particles are attracted to the mouse, but repel each other. Think
about how you need to balance the relative strength of the forces and how to most effectively use
distance in your force calculations.

2: Submission Instructions

Create a zip file with the following components:

Sketch File named sketch.js


Include all p5 libraries used
Include index.html file named index.html

Submit your file to the Assignment 2 Physics Assignment Coursework.


SESSION 2 RESOURCES

You might also like