#N canvas 433 121 448 488 10;
#X obj 22 262 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 22 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 67 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 112 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X msg 22 388 1;
#X msg 67 388 2;
#X msg 112 388 3;
#X obj 22 428 s state;
#X obj 22 153 bng 20 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 56 153 r state;
#X obj 22 215 sel 1 2 3;
#X obj 164 262 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 164 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 209 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 254 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X msg 164 388 1;
#X msg 209 388 2;
#X msg 254 388 3;
#X obj 164 428 s state;
#X obj 311 262 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 311 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 356 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X obj 401 368 bng 15 250 50 0 empty empty empty 20 8 0 8 -262144 -1
-1;
#X msg 311 388 1;
#X msg 356 388 2;
#X msg 401 388 3;
#X obj 311 428 s state;
#X msg 145 153 \; state 1;
#X obj 22 189 f 1;
#X obj 22 287 random 100;
#X obj 22 314 moses 30;
#X obj 67 341 moses 60;
#X obj 164 286 random 100;
#X obj 164 314 moses 10;
#X obj 209 341 moses 60;
#X obj 311 286 random 100;
#X obj 311 314 moses 70;
#X obj 356 341 moses 80;
#X floatatom 56 178 3 0 0 0 - - -, f 3;
#X text 150 135 reset;
#X obj 1 1 cnv 15 445 20 empty \$0-pddp.cnv.header markov_chain 20
10 1 18 -261139 -33289 0;
#X obj 407 2 pddp/pddplink http://puredata.info/dev/pddp -text pddp
;
#X obj 1 466 cnv 15 445 20 empty \$0-pddp.cnv.footer empty 20 12 0
14 -233017 -33289 0;
#N canvas 190 254 494 284 META 0;
#X text 12 135 WEBSITE http://crca.ucsd.edu/~msp/;
#X text 12 115 AUTHOR Miller Puckette;
#X text 12 95 LIBRARY PDDP;
#X text 12 5 GENRE tutorial;
#X text 12 45 LICENSE SIBSD;
#X text 12 155 HELP_PATCH_AUTHORS Updated for release 0.35. Jonathan
Wilkes revised the patch to conform to the PDDP template for Pd version
0.42.;
#X text 12 25 KEYWORDS control;
#X text 12 65 DESCRIPTION how to construct a simple three-valued Markov
chain;
#X restore 382 468 pd META;
#X text 19 135 STEP;
#N canvas 13 392 428 143 References 0;
#X obj 1 1 cnv 15 425 20 empty \$0-pddp.cnv.subheading empty 3 12 0
14 -261139 -33289 0;
#X text 7 2 Markov_chain- Related Help Documents;
#X restore 103 468 pd References;
#X obj 6 468 pddp/pddplink ../5.reference/pddp/help.pd -text help;
#X text 19 37 Here is how to construct a simple \, three-valued Markov
chain using [random]. Each time you click on "step" the previous output
("state") determines which of three random networks to invoke \, each
having a different probability distribution for the next value of "state."
For instance if the state was 3 \, the next state will be 1 70% of
the time \, state 2 10% \, and state 3 20%.;
#X connect 0 0 29 0;
#X connect 1 0 4 0;
#X connect 2 0 5 0;
#X connect 3 0 6 0;
#X connect 4 0 7 0;
#X connect 5 0 7 0;
#X connect 6 0 7 0;
#X connect 8 0 28 0;
#X connect 9 0 28 1;
#X connect 9 0 38 0;
#X connect 10 0 0 0;
#X connect 10 1 11 0;
#X connect 10 2 19 0;
#X connect 11 0 32 0;
#X connect 12 0 15 0;
#X connect 13 0 16 0;
#X connect 14 0 17 0;
#X connect 15 0 18 0;
#X connect 16 0 18 0;
#X connect 17 0 18 0;
#X connect 19 0 35 0;
#X connect 20 0 23 0;
#X connect 21 0 24 0;
#X connect 22 0 25 0;
#X connect 23 0 26 0;
#X connect 24 0 26 0;
#X connect 25 0 26 0;
#X connect 28 0 10 0;
#X connect 29 0 30 0;
#X connect 30 0 1 0;
#X connect 30 1 31 0;
#X connect 31 0 2 0;
#X connect 31 1 3 0;
#X connect 32 0 33 0;
#X connect 33 0 12 0;
#X connect 33 1 34 0;
#X connect 34 0 13 0;
#X connect 34 1 14 0;
#X connect 35 0 36 0;
#X connect 36 0 20 0;
#X connect 36 1 37 0;
#X connect 37 0 21 0;
#X connect 37 1 22 0;
