[CHOP] Random numbers generator

Hi all,
I’m struggling a bit to find the simpliest way to generate random numbers everytime a ramp lfo object reach value 1.
Any idea?

Thanks!

here’s one option
button-random.toe (4.63 KB)

Here’s a way for CHOP result or DAT result. The LFO Ramp triggers Count when it goes On to Off as set on the Count page of parameters.
randRamp.tox (1.25 KB)

1 Like

thanks so much!

Hi @ben, sorry for unburrying this post but it answers to a previous one of mine, and I still don’t understand why you are using a null there ?
Why not using directly exporting the count channel value to the noise ?

(I’m sure there is a good reason !)

Hi @julien ,

using the null that way allows you to insert other chops between your output and the export target, without breaking the export process.

E.g. you want to offset the count, you just put a math between count1 and null1.
Without the null you should export the channel from math again.
If you do the reference instead of exporting, you can otherwise just change the op name in the param field.

2 Likes

Hello Franz!!
Thanks a lot, that’s perfectly clear!

Happy to see you here.
I’m very new to TD.

1 Like

@julien Exactly what Franz said, he beat me to it. While it is not required to use a Null CHOP for exporting and references, it is considered best practice and you’ll see most people doing this in their networks to make it easier to insert operators. No one is forcing you, but if you worked on a project with me I would force you to do it! :laughing:

1 Like

@ben, I understood the good reason, totally !

just for completeness’ sake,
this is the classic case where you build your “random generator” based on the previous patch,
and then add two maths in the middle of the chain, w/o breaking the export,
to process each channel differently thanks to the common/scope field.

RampRand2.tox (1.5 KB)

1 Like

I really get as I played a lot with these after your (@franzrosati + @ben) answers here.

I perfectly understand the thing.

It looks like I would end almost all my “chains” with a null, now.