Search NKS | Online

21 - 30 of 34 for Floor
(With If or Floor included there are at least complicated cases known where polynomial-like formulas can be set up whose evaluation corresponds to explicit prime-generating procedures—see page 1162 .)
Implementation [of 2D cellular automata] An n × n array of white squares with a single black square in the middle can be generated by PadLeft[{{1}}, {n, n}, 0, Floor[{n, n}/2]] For the 5-neighbor rules introduced on page 170 each step can be implemented by CAStep[rule_, a_] := Map[rule 〚 10 - # 〛 &, ListConvolve[{{0, 2, 0}, {2, 1, 2}, {0, 2, 0}}, a, 2], {2}] where rule is obtained from the code number by IntegerDigits[code, 2, 10] .
One example is finding buildings or machines from aerial reconnaissance images; another is finding boat or airplane wreckage on an ocean floor from sonar data.
Indeed, in general with operators Implies , And and Or one gets to 2 n - 1 elements, while with operators Xor and Equal one gets to 2^(2Floor[n/2]) elements.
However, the straightforward method for converting a t -digit number x to base k takes about t divisions, though this can be reduced to around Log[t] by using a recursive method such as FixedPoint[Flatten[Map[If[# < k, #, With[ {e = Ceiling[Log[k, #]/2]}, {Quotient[#, k e ], With[ {s = Mod[#, k e ]}, If[s  0, Table[0, {e}], {Table[0, {e - Floor[Log[k, s]] - 1}], s}]]}]] &, #]] &, {x}] The pictures below show stages in the computation of 3 20 (a) by a power tree in base 2 and (b) by conversion from base 3.
(Starting with initial condition x the digit sequence at step n is essentially IntegerDigits[Mod[2 n Floor[2 53 x], 2 53 ], 2, 53] on the computer, and Flatten[IntegerDigits[IntegerDigits[ Mod[2 n Floor[10 12 x], 10 12 ], 10, 12], 2, 4]] on the calculator.
, 2] + 1 (this satisfies h[1] = 2; h[m_] := h[Floor[m/2]] + m ).
The function at position 2/3 (1 + 4^-(Floor[s/2] + 1/2)) 2 s in basis (a), for example, is exactly the Thue–Morse sequence (with 0 replaced by -1) from page 83 .
There are Ceiling[a/2] + Ceiling[2 a/3] - (a + 1) solutions, the one with smallest x being {Mod[2 a + 2, 3] + 1, 2 Floor[(2a + 2)/3] - (a + 2)} .
The pattern—in either its square or rounded form—has appeared with remarkably little variation in a huge variety of places all over the world—from Cretan coins, to graffiti at Pompeii, to the floor of the cathedral at Chartres, to carvings in Peru, to logos for aboriginal tribes. … Marble mosaics on the floor of the cathedral at Anagni, Italy, made around 1226 AD by Cosmas of the Cosmati group.
123