Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

update a value entry following some rule

i have a vector $(x_1, \dots,x_n)$ where $x_i$ belongs to some set $E$ how can i assign randomly a letter $a,b,c$ to each vector than update it following some rule these vector ?

Example $E={ x_1, x_2,x_3 }$

$(x_1, x_2,x_3)=a$

$(x_2,x_3,x_1)=a$

$(x_3,x_1,x_2)=c$

$(x_3,x_2,x_1)=whatever$

$(x_1,x_1,x_1)=whatevre$ etc...

i have a rule that if $(x_1, x_2,x_3)=a$ and $(x_2,x_3,x_1)=a$ then $(x_3,x_1,x_2)$ must be equal to $a$