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.

A240664 Least k such that 9^k == -1 (mod prime(n)), or 0 if no such k exists.

This page as a plain text file.
%I A240664 #4 Apr 15 2014 02:36:37
%S A240664 1,0,1,0,0,0,4,0,0,7,0,0,2,0,0,13,0,0,0,0,3,0,0,22,12,25,0,0,0,28,0,0,
%T A240664 34,0,37,0,0,0,0,43,0,0,0,4,49,0,0,0,0,0,58,0,30,0,64,0,67,0,0,70,0,
%U A240664 73,0,0,0,79,0,42,0,0,88,0,0,0,0,0,97,0,100,51,0
%N A240664 Least k such that 9^k == -1 (mod prime(n)), or 0 if no such k exists.
%C A240664 The least k, if it exists, such that prime(n) divides 9^k + 1.
%H A240664 T. D. Noe, <a href="/A240664/b240664.txt">Table of n, a(n) for n = 1..1000</a>
%F A240664 a(1) = 1; for n > 1, a(n) = A211245(n)/2 if A211245(n) is even, otherwise 0.
%t A240664 Table[p = Prime[n]; s = Select[Range[p/2], PowerMod[9, #, p] == p - 1 &, 1]; If[s == {}, 0, s[[1]]], {n, 100}]
%Y A240664 Cf. A211245 (order of 9 mod prime(n)).
%K A240664 nonn
%O A240664 1,7
%A A240664 _T. D. Noe_, Apr 14 2014