![]() |
![]() |
cents [-p n] [-tx] [inputfile ...] [> outputfile.cnt]
**cents
spines containing values corresponding to the cents distance
from middle C for pitch-related input tokens.
Pitches above middle C produce positive output values,
whereas pitches below middle C produce negative output values.
For example, the **pitch
token "C3" is transformed to -1200 (cents).
The
cents
command is able to translate any of the pitch-related
representations listed below.
In each case, a tuning standard of A4 equals 440 hertz is assumed.
For descriptions of the various input representations
(including **cents) refer to Section 2
(Representation Reference)
of this reference manual.
It is recommended that output files produced using the cent command should be given names with the distinguishing `.cnt' extension.
**centshundredths of a semitone with respect to middle C=0 **freqfundamental frequency (in hertz) **fretfretted-instrument pitch tablature **kerncore pitch/duration representation **MIDIMusic Instrument Digital Interface tablature **pitchAmerican National Standards Institute pitch notation (e.g. "A#4") **semitsequal-tempered semitones with respect to middle C=0 (e.g. 12 equals C5) **solfgFrench solfège system (fixed `doh') **specCspectral centroid (in hertz) **TonhGerman pitch system Input representations processed by cents.
Options are specified in the command line.
-h displays a help screen summarizing the command syntax -p n output precision of n decimal places -t suppresses printing of all but the first note of a group of tied **kern notes-x suppresses printing of non-cents signifiers
The
-p
option can be used to set the precision of the output values to n
decimal places.
The default precision is integer values only (n=0).
Note that
cents
is able to process **cents
as input; this feature allows the user to round-off existing **cents
data to a specified precision.
The
-t
ensures that only a single output value is given for tied **kern notes;
the output coincides with the first note of the tie.
In the default operation,
cents
outputs non-pitch-related signifiers in addition to the cents value.
For example, the **pitch token "A5zzz" will result in the output
"2100zzz" -- that is, after translating A5 to 2100 cents,
the "zzz" signifiers are retained in the output.
For some applications, echoing non-pitch-related signifiers in the output
is useful.
However, in other situations, the result can prove confusing --
especially, when the non-pitch-related signifiers are numbers.
Consider the case of the **kern token "8aa";
after translating `aa' to 2100 cents, the non-pitch-related signifier `8'
will also be output, hence the value 82100 -- which will undoubtedly cause
confusion.
The
-x
option is useful for eliminating non-pitch-related signifiers from the output.
For most **kern inputs, the
-x
option is recommended.
**deg and **cocho) cannot be processed by
cents.
In addition, there are two non-pitch-related spines
(**embell and **metpos).
!! `cents' example.
**kern**pitch**MIDI**deg**metpos**cocho**Tonh**embell
*M2/4*M2/4*M2/4*M2/4*M2/4*M2/4*M2/4*M2/4
*****tb8***
=1=1=1=1=1=1=1=1
8ee-G#4foo/60/bar1foo1rGis2ct
../-60/.....
8ffA3/62/239.89H2upt
../-62/.....
8dd-Ab3/70/127.07B2ct
../-70/.....
8d-C#4/61/637.135Cis4sus
../-61/.....
=2=2=2=2=2=2=2=2
[4a-r.51rr.
...735.5Heses2ct
4a-]D4/48/ /52/128.11C3ct
../-48/.....
.D4 F4/-52/237.33 6.4C3 Es3ct
=3=3=3=3=3=3=3=3
rG4.r1rH2 D3.
========================
*-*-*-*-*-*-*-*-
Executing the command
cents -tx input > output.cnt
produces the following result:
Both processed and unprocessed spines are output.
Notice that the tied note at the beginning of measure 2 in the
!! `cents' example.
**cents**cents**cents**deg**metpos**cocho**cents**embell*M2/4*M2/4*M2/4*M2/4*M2/4*M2/4*M2/4*M2/4*****tb8***=1=1=1=1=1=1=1=1150080001foo1r-1600ct...... ..1700-300200239.89-1300upt...... ..1300-4001000127.07-1400ct...... ..100100100637.135100sus...... ..=2=2=2=2=2=2=2=2800r.51rr....735.5-1500ct.200-1200 -800128.11-1200ct.........200 500.237.33 6.4-1200 -900ct=3=3=3=3=3=3=3=3r700.r1r-1300 -1000.========================*-*-*-*-*-*-*-*-**kern
spine has been rendered as a single note rather than as two notes
(due to the
-t
option).
Also notice that the non-pitch-related signifiers (e.g. foo)
in the first notes of the **pitch, **MIDI, and **cocho
spines have been stripped away (due to the
-x
option).
x_option.awk
is used by this program when the
-x
option is invoked.
**cents (2),
**freq (2),
freq (4),
**fret (2),
**kern (2),
kern (4),
**MIDI (2),
midi (4),
**pitch (2),
pitch (4),
**semits (2),
semits (4),
**solfg (2),
solfg (4),
**specC (2),
specC (4),
**Tonh (2),
tonh (4)