wire, an n-by-3 matrix
rule, an n-by-1 vector
nr, a scalar
ipr, a scalar
and displays the rule table in the command window
and plots nr runs, with ipr iterations
per run, of the gene network encoded in wire and
rule. Each run should commence from a random initial
state.
The rule table and plot (boxes and blanks) should be of the form
exhibited on our lecture page.
I would construct the rule table, one row at a time, by using a subfunction
of the form
function brule = rtrans(rnum)
that converts decimal
numbers to binary. I ask that you not use the builtin functions
bin2dec and dec2bin, for they are more trouble than they are worth.
Hint: b=floor(log2(r)), reset r, repeat.
Your work will be graded as follows:
First draft of gene3.m
2 pts for turning rule vector to rule table
2 pts for sequential application of rule table
2 pts for plot strategy
Final draft of gene3.m
10 pts for headers for gene3 and rtrans
8 pts for further comments in code
4 pts for indentation
9 pts for correct rule table
9 pts for correct application of rules
6 pts for two jpeg plots, and
4 pts for diary of two runs
4 points for jpeg drawing of custom gene net
associated with runs of two distinct networks.
In each case use nr = 10 and ipr = 50. In one
case use
wire = [4 2 3 and rule = [231
5 3 2 64
3 6 1 5
5 4 6 108
6 1 2 61
3 5 6] 62]
In the other case use a net of your own design and
include a jpeg drawing of its connectivity.