OFFSET
1,2
COMMENTS
For the definition of 'g-adic value of x', called |x|_g with g an integer >= 2, see the Mahler reference, p. 7. Sometimes also called g-adic absolute value of x. If g is not a prime then this is called a non-archimeden pseudo-valuation. See Mahler, p. 10.
REFERENCES
Kurt Mahler, p-adic numbers and their functions, second ed., Cambridge University Press, 1981.
FORMULA
EXAMPLE
a(6) = 6^max(1,1) = 6^1 = 6. a(12) = 6^max(2,1) = 6^2 = 36,
a(18) = 6^max(1,2) = 36, a(24) = 6^max(3,1) = 6^3 = 216, ...
a(2) = 6^1 = 6, a(8) = 6^3 = 216, a(14) = 6^1 = 6, ...
a(3) = 6^1 = 6, a(9) = 6^2 = 36, a(15) = 6^1 = 6, ...
a(4) = 6^2 = 36, a(10) = 6^1 = 6, a(16) = 6^4 = 1296, ...
MATHEMATICA
a[n_] := 6^Max[IntegerExponent[n, {2, 3}]]; Array[a, 100] (* Amiram Eldar, Aug 19 2024 *)
PROG
(PARI) a(n) = 6^max(valuation(n, 2), valuation(n, 3)); \\ Amiram Eldar, Aug 19 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Wolfdieter Lang, Jun 30 2014
STATUS
approved