"tempo" question (object)

k9's icon

Hi there,
I am making a little sequencer patch with "tempo" (picked it up from a tutorial on vimeo).

I have a few questions about this object since I don't really understand it. It has four inputs:
on/off
BPM
Beat multiplier
Beat divisions of a whole note

My problem lies in their interaction. When I reduce the Beat divisions from 32 to 16 (to make my pattern shorter) everything gets slower too.
I thought to compensate for that I have to adjust the "Beat multiplier" but that only destroys the pattern, as it seems to jump around quite randomly -- I was trying numbers between 0. and 1 as ints above 1 make everything slower yet.

is this a completely flawed approach? am I dashing off in the wrong direction?

attached please find the part of the patch that should illustrate my problem.

Any help appreciated..!

K9

1566.k9.tempoquestion.maxpat
Max Patch
Christopher Dobrian's icon

Try thinking of it this way: The third and fourth inlets ("multiplier" and "divisions") are the numerator and denominator of the rhythmic value that the object will produce relative to the specified quarter note tempo ("BPM"). The object always sends out numbers 0 through one-less-than-"divisions". For example with tempo=60, multiplier=1, and divisions=4, the object will send out numbers 0-3 at the 1/4-note interval of 1000 ms. With tempo=60, beats=1, divisions=16, the object will send out numbers 0-15 at the 16th-note interval of 62.5 ms. With tempo=60, beats=2, divisions=32, the object will send out numbers 0-31 at the 16th-note interval of 62.5 ms (because 2/32 = 1/16). With tempo=60, beats=3, divisions=8, the object will send out numbers 0-7 at the dotted-quarter-note (3/8 of a whole note) interval of 1500 ms. Want triplet quarter notes? Well, there are six of those in a whole note, so beats=1 and divisions=6 will do the trick. And so on...

Max Patch
Copy patch and select New From Clipboard in Max.

With that in mind, try putting in different values for the tempo, multiplier, and divisions parameters, to see the time interval and numeric output that those parameters settings produce.

k9's icon

thank you very much, I will try that. currently I am revising my patch to try to make it run reliably at audiorate, so I am trying a different approach from tempo, but that is invaluable information and a very helpful examplepatch anyway!

Alex Lynch's icon

@Christopher Dobrian

Hi Christopher! I'm also trying to wrap my head around the tempo object. If I wanted to send out bangs in a 6/8 time signature at a rate of 60 BPM, does that mean my tempo object should have a denominator of 8 with a numerator of 2? I'm comparing the output with a metronome on my phone and the [tempo] object always seems a little off!

Thanks,

Alex

Christopher Dobrian's icon

I glanced briefly at your other thread about tempo and 6/8 meter, and am hesitant to get lured into that discussion, haha! If you don't like the way transport behaves, you really won't like the way tempo behaves.

Regarding the tempo object:

It always thinks of a measure as being one whole note (1/1) and it always thinks of the beat speed (the 'tempo') as referring to a quarter note (1/4). The numerator and denominator values I mentioned above describe a fraction of a whole note. So, if you bear that in mind, you can figure out (or experiment till you discover) what settings will give you the results you want. Here are a few examples to get you started.

Max Patch
Copy patch and select New From Clipboard in Max.

As for transport and the 6/8 time signature:

What I learned in school—and what I think is the generally accepted "truth" in the pre-computer Western music world—is that the Maelzel metronome marking (the "MM", which is understood to mean "beats per minute") refers to the denominator in so-called "simple" time signatures such as 4/4, 2/2, 3/8, etc., but in a triplet-feel "complex" time signature such as 6/8, 9/8, 12/8, etc. the MM "beat" is the dotted unit that represents a group of three of the denominator units (a dotted quarter note in the three cases I gave). At a very slow tempo a composer might write "eighth-note = 80" instead of "dotted eighth-note = 26.666667", of course, but in general the MM refers to the dotted quarter note.

In the computer music "industry", the words "quarter-note" and "beat" are usually considered synonymous, even when the meter changes to ¢ (2/2) or 6/8 (which one could just as well notate as 2/4 with triplet eighth notes), and "BPM" really stands for "quarter notes per minute", as annoying as that may be to trained instrumental musicians and to people who (rightly) insist that the beat is not always a quarter note. You can dislike that if you want (I do), but pragmatically it's best just to deal with it. I tend to agree that the transport object could (should) give you the option of specifying the unit that will be the B in BPM, but till that happens, just bear in mind that the "tempo" attribute refers to "quarter notes per minute".

Alex Lynch's icon

@ Christopher Dobrian

Excellent, thanks for giving me some closure on the whole thing! I've attached a (very) pedantic patch that tries to use the tempo object as a simple metronome. You can jump between time signatures of quarter note and eighth note subdivisions. I think its banging out in a correct fashion!

Best,

Alex

Time Signatures Tempo Object.maxpat
text/plain 19.04 KB

Roman Thilenius's icon

that is why i think one should always go and program your own code: if there is an complex external which does this for you, you _still have to understand what it does and how things are calculated, or you cant use it without braindamage (or performance interruptus)

in my custom abstractions i can freely choose what a "beat" is by setting an argument, for example - problem solved. :) and when i need it, i can also work in samples or milliseconds. "triplet" can be less descriptive than a millisecond value in some situations...

for those of you who are too lazy to find out all the relations between the units themselves there is the [translate] object since max 5.x ,which does all the conversions for you.

Roman Thilenius's icon

as we all know i am a complete ignorant but i only need to see this:

and i know that i will not start thinking or working in ticks or classic note length names.

it starts with the problem that every new layer introduces a bunch of new (possibly later required) rule of three calculations, and it does not end with the fact that the max timing system wont let me do 2/1 or 1/5 notes .

last but not least, while it can be great in some situations to have automatic cross-object constants such as "current tempo", all this stuff stops working when you want to have more than one master tempo at the same time, or when you want to change the master tempo between events of the current tempo.

plus, it does not make us younger when we reverse the timer; i am hoping for that for max 8.x

-110