All of the following commands assume that you are located in the appropriate score directory.
france01.krn
]).
COMMAND: semits -x france01.krn | xdelta -a -s ^= | grep -v '[=r\[]' | rid -GLId | stats
ANSWER: The average interval size for the actual melody is 1.97 semitones.
COMMAND: scramble -r france01.krn | semits -x | xdelta -a -s ^= | grep -v '[=r\[]' | rid -GLId | stats
ANSWER: The average interval size for the randomized melody is roughly between 3.7 and 4.1 semitones.
french08.krn
folksong
and assume that a "large" interval is 5 semitones or larger.
Begin by creating a "reassignment" file for the recode command:COMMAND: semits -x france08.krn | xdelta -a -s ^= | grep -v '[r=\[]' | recode -i '**Xsemits' -f reassign > temp>=5 large
>0 small
context -n 2 temp | grep -c 'large large'
scramble -r temp | context -n 2 | grep -c 'large large'
ANSWER: For the actual melody, there is only one instance of a large interval followed by a large interval. For the random melody, there is typically between 0 and 1 instance of two successive large intervals.
COMMAND: extract -i '**harm' *.hrm | context -n 2 -o | grep -c '^V IV$'
extract -i '**harm' *.hrm > temp
scramble -r temp | context -n 2 -o | grep -c '^V IV$'
ANSWER: There are two V-IV progressions in the Bach chorale sample.
For the scrambled progressions there are roughly 14 V-IV progressions.
Bach appears to avoid V-IV progressions.
COMMAND: ditto -s = inven11.krn | hint | grep -c 'A11'
ANSWER: There are 11 augmented elevenths in the actual music.
COMMAND: extract -f 1 inven11.krn > temp1
extract -f 2 inven11.krn > temp2
scramble -r -s = temp1 > temp1s
assemble temp1s temp2 | ditto -s = | hint | grep -c 'A11'
ANSWER: There are and average of roughly 7 augmented elevenths in the randomized music.
Bach appears to "seek-out" augmented elevenths in Invention No. 11.