home/ atoms/ tidal-euclid-function

TidalCycles euclid k n places k onsets Euclideanly across n steps, the function form of the (k,n) mini-notation

euclid k n p gates pattern p with a Euclidean rhythm of k onsets distributed as evenly as possible across n steps — identical to writing p(k,n) in mini-notation. euclid 3 8 $ sound "cp" fires the clap on the tresillo x..x..x.. Both parameters accept patterns, so euclid "<3 5>" "[8 16]/4" $ s "bd" varies the onset count and step count across cycles. The function form is preferred when the number of onsets or steps is itself computed or patterned, or when composing with other transforms; the mini-notation (k,n) form is more concise inline. This is the Tidal realisation of the general Euclidean-rhythm concept.

Examples

d1 $ euclid 3 8 $ sound "cp"       -- same as sound "cp(3,8)"
d1 $ euclid "<3 5>" "[8 16]/4" $ s "bd"  -- patterned onsets and steps

Assessment

Write euclid 5 8 $ s "bd" in mini-notation form. When is the euclid function preferable to the (k,n) mini-notation? Predict the onset pattern of euclid 3 8.

“`euclid` creates a Euclidean rhythmic structure. It produces the same output as the Euclidean pattern string”
corpus · tidalcycles-conditions-reference-every-whenmod-mask-euclidin · chunk 3