cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A328618 Multiplicative with a(p^e) = p^e if p = 2 or e is a multiple of p, otherwise a(p^e) = p^((p*floor(e/p)) + (2e mod p)).

This page as a plain text file.
%I A328618 #11 Nov 21 2021 12:34:31
%S A328618 1,2,9,4,25,18,49,8,3,50,121,36,169,98,225,16,289,6,361,100,441,242,
%T A328618 529,72,625,338,27,196,841,450,961,32,1089,578,1225,12,1369,722,1521,
%U A328618 200,1681,882,1849,484,75,1058,2209,144,2401,1250,2601,676,2809,54,3025,392,3249,1682,3481,900,3721,1922,147,64,4225,2178,4489,1156,4761,2450,5041,24
%N A328618 Multiplicative with a(p^e) = p^e if p = 2 or e is a multiple of p, otherwise a(p^e) = p^((p*floor(e/p)) + (2e mod p)).
%H A328618 Antti Karttunen, <a href="/A328618/b328618.txt">Table of n, a(n) for n = 1..16384</a>
%H A328618 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>
%F A328618 For all n >= 0, A276085(a(A276086(n))) = A328622(n).
%t A328618 a[n_] := Product[{p, e} = pe; If[p == 2 || Divisible[e, p], p^e, p^((p*Floor[e/p]) + Mod[2e, p])], {pe, FactorInteger[n]}];
%t A328618 Array[a, 100] (* _Jean-François Alcover_, Nov 21 2021 *)
%o A328618 (PARI) A328618(n) = { my(f = factor(n), m, q); for(k=1, #f~, q = (f[k, 2]\f[k, 1]); m = (f[k, 2]%f[k, 1]); if(m&&(f[k,1]!=2), f[k, 2] = q*f[k, 1] + ((2*f[k, 2])%f[k, 1]))); factorback(f); };
%Y A328618 Cf. A328619 (inverse permutation).
%Y A328618 Cf. A327938, A328617, A328621, A328622.
%K A328618 nonn,mult
%O A328618 1,2
%A A328618 _Antti Karttunen_, Oct 23 2019