< Back to IRCAM Forum

Transposition

Hello There!s there a possible to transpose diatonically a sequence of notes or a chord? I noticed that OM transposes (+) chormatically.
Thanks for the help!

Ismael

I

Dear Ismael,

addition transposes notes as it is, ie adds the amount of midicents you need. Diatonic transposition, is something else. I think you mean by that ā€œSHIFTINGā€ a scale or a mode. by a certain degree. No?

Best
K

hello,

yes, itā€™s a shifting. How can I do it?
Thanks for replyingā€¦
Ismael

Here is a clue:

and the patch:
Diatonic_transposition.omp (19.8 KB)

Best
K

thanks. I will try it here.

hello,

where you put the input 2, thereā€™s a lisp function with a 1- below. I didnā€™t know that it was possible. As I see, this function is linked with the lisp nth, right? can you please tell me how to do it?
Regards and thanks for helping meā€¦
Ismael

Dear Ismael,

This is a standard lisp expression. You can use most of them in om (at the exception of macros) by dble-clicking in the patch and typing the name of the functions. Works also for om functions.

Best
K

Hello Haddad,

I still cannot do it. I know how to call a function. In this case, if I call lisp, it shows me a lambda function. I can alter the name and put a 1- there. But a function like list, thatā€™s not possible to alter the name. I want to know the name of the function where you can alter the name, like you did it. Look at the image I am sendingā€¦
Regards,
Ismael

No you got this wrong:

  1. double click in the workspace:
    Screenshot_2022-06-28_15-05-19

  2. type the functionā€™s name
    Screenshot_2022-06-28_15-06-05

  3. type return:
    Screenshot_2022-06-28_15-06-20

It is as simple as thatā€¦ No need to call lispfunction object. This last one is for a custom lisp code you can write by yourself.

Hope this helps

Best
K

ah okā€¦rsrsā€¦thanks!

Hello again,

Sorry to take your time Haddad. Itā€™s a little more complicated. First, thereā€™s an error message appearing when I try to validate the diatonic patch, saying: in 1- of (nil) arguments should be of type number. In fact, the value of input 2 is nil, and also the same as input 0. Second, the shifting is within the same scale. In the example, the scale of C major turns D major. What I want is a scale with no alteration, only shifting the position of notes. So, D, E, ā€¦C, D.

Hi,

Yes as i understood you meant transposition. So if you input 2 in the second input, you will have a D major scale. Now shifting degrees is another operation. Can you be more specific? (ie a patch example will help )

Best
K

Hello Haddad,

thatā€™s why I opened this post. I want how to transpose diatonically, that is, according to the scale, not chromatically. I need it for an analysis. I think this is a tricky problem because in math we use steps to transpose but it doesnā€™t work in this situationā€¦hope you can help meā€¦
Regards,

Ismael

hello Haddad,

I wasnā€™t able to create a patch that can transpose degrees according to a specific scale. Can you help me do that?
Regards,

Ismael

Hi All,

I apologize for inserting myself in this discussion, but in past I have afforded a similar problem, I suppose. Perhaps something as this, even if a little rough?

Or something analog, using posn-match for shifting along a scale.

Ciao

fdsdb

Hello,

Thanks for this replying. I will try it hereā€¦
Regards,

Ismael

Dear Ismael,

I donā€™t know if this is what you are looking for, but here it is:
You can shift any notes in a given scale (here c major) by a given degree:


And here is the patch:
shift.omp (29.6 KB)

And yes it is ā€œtrickierā€ than a simple transposition.

best
K

hello,

Thanks! both methods are great for me!
Resolved!
Regards,

Ismael

Hello Haddad,

Thatā€™s the patch, but a little question about it. When I press to evaluate some functions inside the mode transposition, it returns the value nil. Itā€™s because inside the ā€˜inputā€™, the value is nil. So, some evaluations are not functioning or returning nil. Thatā€™s not normal right? Itā€™s like the scale or the ā€˜somethingā€™ is abstracted, not been used in the red patch ā€˜mode shiftingā€™;
Ismael

Yes this is normal. Unless you allocate values to the inputs (double-click on them), the red patch will evaluate the inputs as nil (default):


Best
K