composing tools for the command line
Title: "ctools"
Version: 2.0
Year: 2015-2016
Development Language: C++
Platform: Mac OSX/Windows
Interface: CLI
Description: This program lets you construct pitch sets, rows or matrixes from input, then display them or outputs them to a text file in the same directory. There are thirteen sub-programs available.
Download the latest build release for Max OSX (2016-04-17): ctools-2.0-release-Mac.zip
Download the latest build release for Windows 10 (2016-04-17): ctools-2.0-release-Win.zip
Version: 2.0
Year: 2015-2016
Development Language: C++
Platform: Mac OSX/Windows
Interface: CLI
Description: This program lets you construct pitch sets, rows or matrixes from input, then display them or outputs them to a text file in the same directory. There are thirteen sub-programs available.
Download the latest build release for Max OSX (2016-04-17): ctools-2.0-release-Mac.zip
Download the latest build release for Windows 10 (2016-04-17): ctools-2.0-release-Win.zip
4. Construct a matrix
This program lets the users construct a matrix. Many have written programs similar to this, but few give the option to write matrixes that are less than or more than twelve tones. This program allows users to write matrixes that are constructed by up to 50 pitches, and are formatted with the traditional method of labeling row numbers, where labels for pitches are numbered in relation to their transposition from P0.
To find transpositions, it adds numbers to each columns and modulates back to the range of 0-11 if the transposition exceeds 12; to find inversions, the numbers are subtracted by 12. Specifically, this program finds the transpositions between each pitch in the row, then uses this array of transposition indexes to calculate the values for all rows. The transposition function is implemented as followed:
To find transpositions, it adds numbers to each columns and modulates back to the range of 0-11 if the transposition exceeds 12; to find inversions, the numbers are subtracted by 12. Specifically, this program finds the transpositions between each pitch in the row, then uses this array of transposition indexes to calculate the values for all rows. The transposition function is implemented as followed:
void Modules::transposition(int rType) {
setRow(0, 0, 4); // no transposition for the first pitch
for (int i = 1; i < getRowSize(1); i++)
// initialize a transposition table to find the distance between each pitch in the row
setRow(i, getRow(i, rType) - getRow(i - 1, rType), 4); // start with subtracting the 1st pitch from the 2nd pitch
}
setRow(0, 0, 4); // no transposition for the first pitch
for (int i = 1; i < getRowSize(1); i++)
// initialize a transposition table to find the distance between each pitch in the row
setRow(i, getRow(i, rType) - getRow(i - 1, rType), 4); // start with subtracting the 1st pitch from the 2nd pitch
}
A sample output of this program looks like the following:
5. Construct a matrix in rotation
Similar to the previous matrix program, this program additionally allows users to print the matrixes in rotation to the right or left by one index (one column) at a time, changing the pitch sequence of all the rows. For example, rotating the row C-D-E to the right by one, the sequence would become D-E-C.