%I #35 Sep 08 2022 08:46:09
%S 4,1,2,1,2,1,2,1,4,1,2,1,1,1,2,1,4,1,2,1,2,1,2,1,4,1,2,1,1,1,2,1,4,1,
%T 2,1,2,1,2,1,4,1,2,1,1,1,2,1,4,1,2,1,2,1,2,1,4,1,2,1,1,1,2,1,4,1,2,1,
%U 2,1,2,1,4,1,2,1,1,1,2,1,4,1,2,1,2,1,2,1,4,1,2,1,1,1,2,1,4,1,2,1,2
%N Denominator of (n+4)/gcd(n, 4)^2, a 16-periodic sequence that associates A061037 with A106617.
%C This sequence may also be defined as the denominators of A061037(n+3)/(n+1), or also as A060819 / A109008.
%C One can notice that the analog numerators [numerators of (n+4)/gcd(n, 4)^2] are A106617 left-shifted 4 places.
%H Antti Karttunen, <a href="/A247004/b247004.txt">Table of n, a(n) for n = 0..65537</a>
%H <a href="/index/Rec#order_16">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1).
%F A247004 = A060819 / A109008.
%F (n+4) / gcd(n, 4)^2 = A188134(n+4) / 4. - _Michael Somos_, Sep 12 2014
%F a(n) = a(n+16) = a(-n), a(2*n + 1) = 1 for all n in Z. - _Michael Somos_, Sep 13 2014
%e Fractions begin:
%e 1/4, 5, 3/2, 7, 1/2, 9, 5/2, 11, 3/4, 13, 7/2, 15, 1, 17, 9/2, 19,
%e 5/4, 21, 11/2, 23, 3/2, 25, 13/2, 27, 7/4, 29, 15/2, 31, 2, 33, 17/2, 35,
%e ...
%e Numerators begin:
%e 1, 5, 3, 7, 1, 9, 5, 11, 3, 13, 7, 15, 1, 17, 9, 19,
%e 5, 21, 11, 23, 3, 25, 13, 27, 7, 29, 15, 31, 2, 33, 17, 35,
%e ...
%e Periodic part = [4, 1, 2, 1, 2, 1, 2, 1, 4, 1, 2, 1, 1, 1, 2, 1];
%t a[n_] := (n+4)/GCD[n, 4]^2 // Denominator; Table[a[n], {n, 0, 100}]
%t (* or: *)
%t Table[{1, 2, 1, 2, 1, 2, 1, 4, 1, 2, 1, 1, 1, 2, 1, 4}[[Mod[n, 16, 1]]], {n, 0, 100}]
%o (PARI) for(n=0,100, print1(denominator((n+4)/gcd(n,4)^2), ", ")) \\ _G. C. Greubel_, Aug 05 2018
%o (Magma) [Denominator((n+4)/Gcd(n,4)^2): n in [0..100]]; // _G. C. Greubel_, Aug 05 2018
%Y Cf. A060819, A061037, A106617, A109008, A188134, A213268.
%K nonn,easy
%O 0,1
%A _Jean-François Alcover_ and _Paul Curtz_, Sep 09 2014