Search NKS | Online

51 - 60 of 160 for Map
Note (b) for Iterated Maps and the Chaos Phenomenon
Note (c) for Iterated Maps and the Chaos Phenomenon
A single step in evolution of a general cellular automaton with state a and rule number num is then given by Map[IntegerDigits[num, k, k^Length[os]] 〚 -1 - # 〛 &, Apply[Plus, MapIndexed[k^(Length[os] - First[#2]) RotateLeft[a, #1] &, os]], {-1}] or equivalently by Map[IntegerDigits[num, k, k^Length[os]] 〚 -# - 1 〛 &, ListCorrelate[Fold[ReplacePart[k #1, 1, #2 + r + 1] &, Array[0 &, Table[2r + 1, {d}]], os], a, r + 1], {d}]
The program in the multiregister machine can be converted to a program for the 2-register machine according to RMToRM2[prog_] := Module[{segs, adrs}, segs = MapIndexed[seg, prog]; adrs = FoldList[Plus, 1, Map[Length, segs]]; MapIndexed[#1 /.
Implementation [of network cellular automata] Given a network represented as a list in which element i is {a, i , b } , where a is the node reached by the above connection from node i , and b is the node reached by the below connection, each step corresponds to NetCAStep[{rule_, net_}, list_] := Map[Replace[#, rule] &, list 〚 net 〛 ]
But for multiway systems where each rule p  q is accompanied by its reverse q  p , and such pairs are represented say by "AAB" ↔ "BBAA" , an equivalent operator system can immediately be obtained either from Apply[Equal, Map[Fold[#2[#1] &, x, Characters[#]] &, rules, {2}], {1}] or from (compare page 1172 ) Append[Apply[Equal, Map[(Fold[f, First[#], Rest[#]] &)[Characters[#]] &, rules, {2}], {1}], f[f[a, b], c]  f[a, f[b, c]]] where now objects like "A" and "B" are treated as constants—essentially functions with zero arguments.
If the coefficients inside all the sine functions are rational, then going from t = 0 to t = 2 π Apply[LCM, Map[Denominator, list]] yields a closed curve.
Given p = Array[Prime, Length[list], PrimePi[Max[list]] + 1] or any list of integers that are all relatively prime and above Max[list] (the integers in list are assumed positive) CRT[list_, p_] := With[{m = Apply[Times, p]}, Mod[Apply[Plus, MapThread[#1 (m/#2)^EulerPhi[#2] &, {list, p}]], m]] yields a number x such that Mod[x, p]  list . Based on this LE[list_] := Module[{n = Length[list], i = Max[MapIndexed[ #1 - #2 &, PrimePi[list]]] + 1}, CRT[PadRight[ list, n + i], Join[Array[Prime[i + #] &, n], Array[Prime, i]]]] will yield a number x that can be decoded into a list of length n using essentially the so-called Gödel β function Mod[x, Prime[Rest[NestList[NestWhile[# + 1 &, # + 1, Mod[x, Prime[#]]  0 &] &, 0, n]]]]
With this setup, the evolution of any register machine can be implemented using the functions (a typical initial condition is {1, {0, 0}} ) RMStep[prog_, {n_Integer, list_List}] := If[n > Length[prog], {n, list}, RMExecute[prog 〚 n 〛 , {n, list}]] RMExecute[i[r_], {n_, list_}] := {n + 1, MapAt[(# + 1)&, list, r]} RMExecute[d[r_, m_], {n_, list_}] := If[list 〚 r 〛 > 0, {m, MapAt[(# - 1)&, list, r]}, {n + 1, list}] RMEvolveList[prog_, init:{_Integer, _List}, t_Integer] := NestList[RMStep[prog, #]&, init, t] The total number of possible programs of length n using k registers is (k (1 + n)) n .
Representing the strings by lists, one can write rules in the form {{1, 1, s___}  {s, 1, 0}, {1, s___}  {s, 1, 0, 1}} so that the evolution is given by MWTSEvolve[rule_, list_, t_] := Nest[Flatten[Map[ReplaceList[#, rule] &, #], 1] &, list, t]
1 ... 3456 ...