%I #23 Oct 22 2023 16:21:28
%S 1,2,3,6,4,3,10,14,5,18,10,6,21,26,9,30,6,11,9,15,27,4,11,5,24,50,6,
%T 18,14,6,55,50,7,9,34,23,14,74,12,26,33,10,78,86,29,90,18,9,48,98,33,
%U 10,45,35,15,12,30,38,29,39,12,42,41,55,8,42,26,134,6,46,35
%N Order of 4 mod 4n+1.
%H Muniru A Asiru, <a href="/A003573/b003573.txt">Table of n, a(n) for n = 0..10000</a>
%F a(n) = A053447(2*n) for n >= 0. - _Jianing Song_, Oct 03 2022
%p a := n -> `if`(n=0, 1, numtheory:-order(4, 4*n+1)): seq(a(n), n = 0..68);
%t Table[MultiplicativeOrder[4, 4*n + 1], {n, 0, 70}] (* _Arkadiusz Wesolowski_, Nov 27 2012 *)
%o (Sage)
%o def A003573(n):
%o s, m, N = 0, 1, 4*n + 1
%o while True:
%o k = N + m
%o v = valuation(k, 4)
%o s += v
%o m = k // 4^v
%o if m == 1: break
%o return s
%o print([A003573(n) for n in (0..70)]) # _Peter Luschny_, Oct 07 2017
%o (GAP) List([0..70],n->OrderMod(4,4*n+1)); # _Muniru A Asiru_, Feb 16 2019
%o (PARI) a(n) = znorder(Mod(4, 4*n+1)); \\ _Michel Marcus_, Feb 16 2019
%Y Cf. A003574. First bisection of A053447.
%Y Cf. A002326, A003571, A217469.
%K nonn
%O 0,2
%A _N. J. A. Sloane_
%E a(0) = 1 added by _Peter Luschny_, Oct 07 2017