aboutsummaryrefslogtreecommitdiff
path: root/doc/help/cyclone/prob-help.pd
blob: 9417ae0941a22f9bb30c0e5717af21cdc3401eef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#N canvas 112 40 826 571 10;
#X obj 4 4 cnv 15 400 40 empty empty empty 20 12 0 14 -262130 -66577 0;
#X text 7 524 docs based on the MAX/MSP reference (c) cycling'74;
#X text 6 538 ___________________________________________________;
#X obj -2 21 prob;
#X text 137 23 weighted series of random numbers;
#X text 5 53 coll maintains a probability matrix a.k.a 1st order;
#X text 5 65 markov chain and outputs a number according to it.;
#X text 168 94 0 has a 80% chance to be followed by 1 \, and;
#X text 168 106 a 10% chance to be followed by 2 or 3;
#X obj 215 217 prob;
#X floatatom 215 251 5 0 0 0 - - -;
#X msg 201 128 0 1 80 \, 0 2 10 \, 0 3 10;
#X obj 215 164 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
-1;
#X msg 237 189 0;
#X text 235 163 puts out a number and sets prob to this value;
#X text 267 189 resets prob to 0;
#X text 181 132 1;
#X text 136 224;
#X text -3 164 2 try this a couple of times:;
#X msg 338 274 0 1 30 \, 0 2 30 \, 0 3 40;
#X msg 364 301 1 2 30 \, 1 0 70;
#X floatatom 271 472 5 0 0 0 - - -;
#X obj 294 451 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
-1;
#X text 334 253 load probabilities:;
#X text 315 448 bang when we reach a number for which we have no rule
;
#X obj 271 279 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
-1;
#X msg 178 397 reset 0;
#X obj 271 426 prob;
#X msg 197 337 clear;
#X text 102 339 clear matrix:;
#X text 14 380 when we get stuck reset to 0:;
#X msg 378 331 dump;
#X text 416 332 print out all rules;
#X msg 386 368 embed;
#X text 434 367 save matrix with the patch;
#X connect 9 0 10 0;
#X connect 11 0 9 0;
#X connect 12 0 9 0;
#X connect 12 0 13 0;
#X connect 13 0 9 0;
#X connect 19 0 27 0;
#X connect 20 0 27 0;
#X connect 25 0 27 0;
#X connect 26 0 27 0;
#X connect 27 0 21 0;
#X connect 27 1 22 0;
#X connect 28 0 27 0;
#X connect 31 0 27 0;
#X connect 33 0 27 0;