File/dsg_cli.php

Description

Contains the main loop of the DSG program

Dissonance Grading program by Jos Kunst (1936-1996), intended as a tool for musical composition and used as such by himself.

Original version written in Pascal (1993). Ported to PHP (Command Line Interface version) by Jan Pieter Kunst (2006).

Usage: $ php [-f] dsg_cli.php

Notes:

The Pascal control structure

  1. repeat ... until condition

is represented by

  1. while(1... if (conditionbreak;}

throughout.

The Pascal data type 'set' is represented by PHP arrays, see set_emulation.inc.php.

  • filesource: Source Code for this file
  • author: Jos Kunst
  • author: Ported to PHP by Jan Pieter Kunst
  • version: 2.0.1 (version number of original Pascal program)
  • todo: web interface
Includes
 require ('set_emulation.inc.php') (line 47)

Utility functions to emulate Pascal data type 'set' with PHP arrays

 require ('translations.inc.php') (line 51)

Functions to translate to and from strings representing chords and pitches

 require ('chordworker.inc.php') (line 59)

Functions to change the dissonance of a chord

 require ('input_output.inc.php') (line 63)

Functions for overall program logic, user input and program output

 require ('chordscanner.inc.php') (line 55)

Functions to analyze a chord, represented by an array of pitches (integers)

Variables
array $last_fed_in_chord (line 70)

Used to save original chord provided by the user

Documentation generated on Sun, 26 Nov 2006 14:27:06 +0100 by phpDocumentor 1.3.1