@libraz/libcantus - v1.1.0
    Preparing search index...

    Type Alias TimeSignature

    A time signature as a numerator over a note-value denominator.

    type TimeSignature = {
        numerator: number;
        denominator: number;
        grouping?: number[];
    }
    Index
    numerator: number
    denominator: number
    grouping?: number[]

    Optional grouping of the bar into felt beats, as positive integers. The entries are group lengths, written either in the meter's main pulses — [2, 2, 3] for a 2+2+3 reading of 7/8, [3, 2] for 5/8 — or, for a compound numerator, in denominator units. They must sum to pulsesPerBar in the first spelling and to the numerator in the second; a pulse is one unit outside compound meters, where the two spellings coincide.

    A compound numerator accepts both readings, and the shape of the grouping says which is meant. Groups of nothing but threes spell the compound division itself, so 9/8 as [3, 3, 3] (equivalently [1, 1, 1]) is the ordinary three dotted-quarter pulses; any other grouping summing to the numerator reads additively, so 9/8 as [2, 2, 2, 3] is nine quaver pulses grouped aksak-fashion. pulsesPerBar, pulseBeats and isCompound follow whichever reading the grouping selects.

    The head pulse of each group other than the downbeat is a secondary strong pulse to metricWeight/isStrongBeat. A grouping whose groups are all the same length states no accent the meter does not already have, so it weighs exactly as an ungrouped bar does.