Search NKS | Online

211 - 220 of 283 for Function
For any sequence s this can be done using Module[{c, m = 0}, Map[c[#] = {m, m += Count[s, #]/Length[s]} &, Union[s]]; Function[x, (First[RealDigits[2 # Ceiling[2 -# Min[x]], 2, -#, -1]] &)[Floor[Log[2, Max[x] - Min[x]]]]][ Fold[(Max[#1] - Min[#1]) c[#2] + Min[#1] &, {0, 1}, s]]] Huffman coding of a sequence containing a single 0 block together with n 1 blocks will yield output of length about n ; arithmetic coding will yield length about Log[n] .
For example, in a generalized Ising model (see page 944 ) for a spin system the undecidability of the tiling problem implies that it is undecidable whether a given energy function leads to a phase transition in the infinite size limit.
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.
But in Mathematica Integrate is now almost completely systematic, being based on structure theorems for finding general forms of integrals, and on general representations in terms of MeijerG and other functions.
Implementation [of proof example] Given the axioms in the form s[1] = (a_ ⊼ a_) ⊼ (a_ ⊼ b_)  a; s[2, x_] := b_  (b ⊼ b) ⊼ (b ⊼ x); s[3] = a_ ⊼ (a_ ⊼ b_)  a ⊼ (b ⊼ b); s[4] = a_ ⊼ (b_ ⊼ b_)  a ⊼ (a ⊼ b); s[5] = a_ ⊼ (a_ ⊼ (b_ ⊼ c_))  b ⊼ (b ⊼ (a ⊼ c)); the proof shown here can be represented by {{s[2, b], {2}}, {s[4], {}}, {s[2, (b ⊼ b) ⊼ ((a ⊼ a) ⊼ (b ⊼ b))], {2, 2}}, {s[1], {2, 2, 1}}, {s[2, b ⊼ b], {2, 2, 2, 2, 2, 2}], {s[5], {2, 2, 2}}, {s[2, b ⊼ b], {2, 2, 2, 2, 2, 1}}, {s[1], {2, 2, 2, 2, 2}}, {s[3], {2, 2, 2}}, {s[1], {2, 2, 2, 2}}, {s[4], {2, 2, 2}}, {s[5], {}}, {s[2, a], {2, 2, 1}}, {s[1], {2, 2}}, {s[3], {}}, {s[1], {2}}} and applied using FoldList[Function[{u, v}, MapAt[Replace[#, v 〚 1 〛 ] &, u, {v 〚 2 〛 }]], a ⊼ b, proof]
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 .
Instead, as discussed on page 940 , a PDE is essentially just a constraint on the values of a function at different times or different positions.
But other parts—often including sites important for function—seem more like random walks.
Many of the maps I will consider can be expressed in terms of standard mathematical functions, but in general all that is needed is that the map take any possible number between 0 and 1 and yield some definite number that is also between 0 and 1.
1 ... 19202122 ...