[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TimeSignature with note in denominator

From: Jean Abou Samra
Subject: Re: TimeSignature with note in denominator
Date: Fri, 12 Nov 2021 23:49:13 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.2.1

Le 12/11/2021 à 22:31, Kieren MacMillan a écrit :
Hi Jean,

A unified \time command is
not trivial to achieve from a parsing perspective. If the
syntax of the argument is "4/4.", there is work to be done
in the parser to let it accept it. "4 4." is feasible with
a separate function, but I am pretty sure it isn't with
a unified music function. Again, fiddling with the parser
would be required.
Currently, both

     \time 4/4


     \time #'(4 . 4)

are accepted, and return the same thing. So no parser-fiddling is required (I 
believe?), as long as you change \time so that it accepts a pair:

time =
#(define-music-function (beat-structure fraction)
   ((number-list? '()) pair?)

At that point, the only issue is to turn

     \time #'(4 . "4.")

into an number num and a *duration* (not number) denom… which again doesn’t 
required parser-fiddling, correct?

In that case, yes, though I am not entirely comfortable with

\time #'(4 . 4)


\time #'(4 . "4")

doing so different things. Also, how do you integrate
the functionality of \compoundMeter into this? Presumably
you might want the ability to write

\time #'("4" . ("4" "8"))

for what Elaine wrote as {4}/{4 8}, except that the
Scheme expressions

'("4" . ("4" "8"))


'("4" "4" "8")

are entirely equivalent, so this will conflict with
the \compoundMeter-like way of interpreting this as
({4} + {4})/{8}. It's not totally obvious to me how
to design a format that would be unambiguous and
intuitive enough to write.

I suspect they would have to be one function, because how else would you
combine the two?  Each denominator could be either a number or note.

4/4 + 3/4
6/8 + 1/{2}
1/{8.} + 2/4
2/{4} + 3/{8.}

I'm quite sure that this technically cannot be made
to work at least in lyric mode.

No, the point would be to first devise something that users can understand.

If users can understand it, it is possible to get the computer to do so.

Not the other way around.

Humans can tolerate ambiguity, computers can't.
Assuming that I am wrong and it could actually
work in lyric mode, how would you parse the

\lyrics { \time 4/4 + {4}/8 }

It is already valid syntax.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]