SUCCEED

   

Forensic Science
Shodor > SUCCEED > Curriculum > Workshops > Forensic Science

Creating a Computer Virus Model

Objective: Students will learn about the spread of a computer virus through computer modeling.

Materials: Each student will need

Step One

  1. Start off with interface: make go and setup buttons
  2. Explain what setup and go mean, then add code for setup and go. As you call for new methods, also create them. The emphasis should be on good syntax and code structure.
  3. Help students create a working model where the virus spreads to computer.
  4. Allow students to edit their graphics.
Code for step one can be downloaded here

Step Two

Ask students the following questions:

  • Is this a realistic model?
  • Do all computers "catch" the virus?
  • Do computers ever "recover"?
  1. Have the students add the ability for computers to "recover". Add sliders for the number of computers, number of bugs, infectiousness, and recovery rate.
  2. If there are specific graphics for recovered/sick/healthy computers, create breeds as necessary.
Code for step two can be downloaded here

Step Three

  1. Create "immunity". Create a "counter" to kill the computers.
  2. Create a plot of all the populations. Have students change parameters and play with the model.
Code for step three can be downloaded here