Spring2010.CSCI180Homework2 History

Hide minor edits - Show changes to output

Changed lines 36-37 from:
%height=200px% http://students.umf.maine.edu/~stonelhm/Assignments/Planets.jpg
to:
%height=200px% http://www.aerospaceweb.org/question/astronomy/solar-system/solar-system.jpg
Added lines 117-123:
!!A Few Interesting Submissions

There were several great submissions. Here are three that stood out: [--(regardless of grade earned - grading depended on more than just sound)--]

# [[http://www.cs.cofc.edu/~manaris/uploads/Spring2010/harmonicesMundi.AltmanMiller.mid | Harmonices Mundi #1]] (by Courtney Miller and Caitlin Altman)
# [[http://www.cs.cofc.edu/~manaris/uploads/Spring2010/harmonicesMundi.McNellisFricker.mid | Harmonices Mundi #2]] (by Douglas McNellis and Ian Fricker)
# [[http://www.cs.cofc.edu/~manaris/uploads/Spring2010/harmonicesMundi2.BloughWayles_McSween.mid | Harmonices Mundi #3]] (by Matthew Blough-Wayles and Shea McSween)
Changed lines 1-2 from:
'''Assigned Date''': Thursday, Feb. 18, 2010\\
'''Due Date''': Thursday, Feb. 25, 2010\\
to:
'''Assigned Date''': Thursday, Feb. 25, 2010\\
'''Due Date''': Thursday, Mar. 4, 2010\\
Changed lines 40-41 from:
Write a Jython program that generates a sonification of the plants' organization using the jMusic programming library for musicians. Your program should generate a MIDI file with your sonification.
to:
Write a Jython program that generates a sonification of the planets' organization using the jMusic programming library for musicians. Your program should generate a MIDI file with your sonification.
Added line 54:
# Do include Ceres (i.e., the asteroid belt) and Pluto.
Deleted line 54:
Deleted line 99:
Deleted line 112:
Changed lines 114-115 from:
to:
# Enchanted Learning.com, "[[http://www.enchantedlearning.com/subjects/astronomy/planets/ | The Planets (plus the Dwarf Planet Pluto)]]", Accessed on-line, Feb. 17, 2010.
Added lines 21-26:
According to Scaletti [1],

-> [t]he idea of representing data in sound is an ancient one. For the ancient Greeks music was not an art-for-art's sake, practiced in a vacuum, but a manifestation of the same ratios and relationships as those found in geometry or in the positions and behaviors of the planets.

!!!Johannes Kepler
Changed lines 40-41 from:
Write a Jython program that generates a sonification of the plants organization using the jMusic programming library for musicians. Your program should generate a MIDI file with your sonification.
to:
Write a Jython program that generates a sonification of the plants' organization using the jMusic programming library for musicians. Your program should generate a MIDI file with your sonification.

In particular, convert the orbital velocities of the planets to MIDI notes:

* Map the range of [[http://www.windows.ucar.edu/tour/link=/our_solar_system/planets_table.html&edu=high | orbital velocities]] to the range of 30-120. Use the resulting numbers as MIDI pitches.

To do so, use the following formula:

@@pitch = ((velocity - minVelocity) / (maxVelocity - minVelocity) * 90) + 30@@

where @@velocity@@ is the orbital velocity of some planet, @@minVelocity@@ is the smallest orbital velocity among the planets, and @@maxVelocity@@ is the largest orbital velocity among the planets.

!!!Notes:

# Make sure you initialize each of the above variables appropriately

# Make sure you convert @@pitch@@ to an integer (via the @@int()@@ function) before using it to create a MIDI note
.
Changed lines 60-61 from:
Follow the Golden Rule of Style: "A program should be as easy for a human being to read and understand as it is for a computer to execute." [1]
to:
Follow the Golden Rule of Style: "A program should be as easy for a human being to read and understand as it is for a computer to execute." [2]
Added lines 114-115:
# Quote from [[http://www.symbolicsound.com/ssc.html|Carla Scaletti]], "Sonification - An Ancient Idea Made Feasible by New Technology", ''ACM SIGRAPH '93 - Course Notes 81'', Aug. 1993, p. 4.2.
Added lines 86-89:
!!!Relevant Quote

"Any amount of work can be done in any amount of time... only the quality varies." ~Joao Meidanis
Added lines 26-27:
!!!Bode's Law
Added lines 30-31:
%height=200px% http://students.umf.maine.edu/~stonelhm/Assignments/Planets.jpg
Added lines 1-85:
'''Assigned Date''': Thursday, Feb. 18, 2010\\
'''Due Date''': Thursday, Feb. 25, 2010\\
'''Due Time''': 9:20am

Last modified on {$LastModified} (see [[http://www.cs.cofc.edu/~manaris/?n=Spring2010.CSCI180Homework2?action=diff&source=n&minor=n | updates]])

This is a '''pair-programming''' assignment (i.e., you may work with '''one''' partner). '''You may discuss the assignment only with your partner or the instructor.'''

!!Purpose

This assignment focuses on:

* creating music with computers,
* connections between numbers and music,
* fundamentals of algorithmic composition,
* MIDI notes, durations, etc., and
* generating a MIDI file.

!!Introduction

In 1619 [[http://en.wikipedia.org/wiki/Johannes_Kepler | Johannes Kepler]] wrote his "[[http://en.wikipedia.org/wiki/Harmonices_Mundi | Harmonices Mundi (Harmony of the Worlds)]]" treatise. While philosophers spoke of the "music of the spheres," Kepler discovered physical harmonies in planetary motion and is a key figure in the scientific revolution that brought us out of the dark ages.
* Here is a modern [[http://www.willieruff.com/soundfiles/01.Mercuryoutward.mp3 | sonification]] based on Kepler's "Harmonices Mundi" and actual orbital data of planets in our solar system.
* Here is [[http://www.willieruff.com/kepler.html | more information about this sonification]].
** [--Here is a lesser quality, but still relevant [[http://www.youtube.com/watch?v=1EFZuzgcIzY | YouTube video]].--]

The [[http://en.wikipedia.org/wiki/Titius%E2%80%93Bode_law | Titius–Bode law]] (aka Bode's law) is an attempt to model the symmetries and proportions of our solar system. Actually, it predicted [[http://en.wikipedia.org/wiki/Asteroid_belt | the asteroid belt]] between Mars and Jupiter (long before it was discovered), but fails to account of the irregularly moving Neptune and the (now demoted non-planet) Pluto.

!!Assignment

Write a Jython program that generates a sonification of the plants organization using the jMusic programming library for musicians. Your program should generate a MIDI file with your sonification.

!!Documentation

Follow the Golden Rule of Style: "A program should be as easy for a human being to read and understand as it is for a computer to execute." [1]

In general, you should comment any variable, obscure statement, block of code, method, and class you create.

Your comments should express '''why''' something is being done, as opposed to '''how''' – the how is shown by the code.

!!!Top Documentation

Additionally, your code should always include opening comments as follows:

(:source lang=Python tabwidth=3 -trim :)
#
# Author: <Your Name(s)>
# Email: <Your email address(es)>
# Class: CSCI 180, Section 1
# Assignment: HMWK2
# Due Date: <The assignment's due date>
#
# Certification of Authenticity <remove one of the following>:
#
# I certify that this lab is entirely my own work.
#
# I certify that this lab is my own work, but I received
# some assistance from: <Name(s)>
#
# Purpose: <Provide a simple, yet complete description of the task being
# performed by this program. It may be several sentences long.>
#
# Input: <Provide a simple, yet complete description of the input required
# by this program.>
#
# Output: <Provide a simple, yet complete description of the output generated
# by this program.>
#
(:sourcend:)

!!Submissions

You will submit your assignment via WebCT. Be prepared to demo your music to the rest of the class. Your submission consists of the following:

# Your Jython program (call it '''harmonicesMundi.py''').

# Your MIDI file (call it '''harmonicesMundi.mid''').

!!Grading

Your grade will be based on how well you followed the above instructions, and the depth/quality of your work.

!!Reference

# Cooper, D. and Clancy, M. (1985) "Oh! Pascal", 2nd ed., W.W. Norton & Company, New York, p. 42.