# Tag Info

3

Let $t$ represent the imaginary part of a zeta zero on the critical line. The asymptotic expansion of RiemannSiegelTheta[t] for large $t$ is Simplify[Series[RiemannSiegelTheta[t], {t, Infinity, 2}]] the first term of which is $\frac{1}{2}{\rm Log}[\frac{t}{2\pi}]-\frac{1}{2}$. For large $t$, the phase of the zeta function on the critical line is ...

2

You could use the built-in function IntegerExponent as follows. EvenOddFactorsOf[n_?OddQ] := {{0, n}, Apply[CenterDot, {Superscript[2, 0], n}]} EvenOddFactorsOf[n_] := With[{e = IntegerExponent[n, 2]}, {{e, n/2^e}, Apply[CenterDot, {Superscript[2, e], n/2^e}]}] The function returns two formats. The first is a list of the exponent of 2 and the ...

1

Personally I think the neatest way is: powerOf2[x_Integer] := powerOf2[x/2] + {1, 0} powerOf2[x_] := {-1, 2 x} powerOf2[528]

3

CenterDot @@ (Superscript @@@ FactorInteger[528]) $2^4\cdot 3^1\cdot 11^1$ Or... if you don't like exponents of "1": CenterDot @@ (If[#[[2]] != 1, Superscript[#[[1]], #[[2]]], #[[1]]] & ) /@ FactorInteger[528] $2^4\cdot 3\cdot 11$

10

There are several problems with your code. The first one is that you are missing a couple of semicolons to suppress output and delineate substatements in a compound function. The second problem is that you are trying to assign a new value to x within the function definition. This doesn't work. x already has the value of whatever number you give. You need ...

5

Try this, just to get you started. Function arguments can't be modified in the module so I've used x0 to allow your code to run. prime[x0_] := Module[{a, i, y, x}, x = x0; a = x/2; i = 0 ; If[IntegerQ[x] == False, Print["Input integer."]; Return[]]; While[IntegerQ[x] == True, x = x/2; i = i + 1; ]; y = x/2^i; Return[{i, y}]]

1

After removing typos due to line breaks this code runs fine (for about 1 minute) and produces a nice Picture. For completeness: Version 10.1.0 Source: http://stackoverflow.com/questions/8934125/how-plot-the-riemann-zeta-zero-spectrum-with-the-fourier-transform-in-mathematic, user Heike, Jan 23 '12 at 17:15 Clear[f] scale = 1000000; f = ConstantArray[0, ...

9

Brute forcing it: (The edit at the end is a much faster alternative) n = 9; IntegerPartitions[n + 1, {3}] (* {{8, 1, 1}, {7, 2, 1}, {6, 3, 1}, {6, 2, 2}, {5, 4, 1}, {5, 3, 2}, {4, 4, 2}, {4, 3, 3}}*) are the ways to split ten digits. The numbers on the first row can't produce viable sums, so we need to check only the partitions on the bottom row. ...

Top 50 recent answers are included