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.

A124276 Terms k of A068563 such that k/2 is not a term of A068563.

This page as a plain text file.
%I A124276 #18 Jan 29 2023 19:43:39
%S A124276 1,6,18,20,42,54,60,100,126,136,156,162,180,220,294,300,342,378,408,
%T A124276 420,468,486,500,540,620,660,680,780,820,882,900,1026,1092,1100,1134,
%U A124276 1224,1260,1314,1332,1404,1458,1500,1620,1806,1860,1980,2028,2040,2058,2100
%N A124276 Terms k of A068563 such that k/2 is not a term of A068563.
%C A124276 A068563 are the numbers n such that 2^n (mod n) = 4^n (mod n). If k is in the sequence A068563 then 2k is also in the sequence A068563, but if 2m is in the sequence A068563 m is not necessarily a term of the sequence A068563.
%H A124276 Alois P. Heinz, <a href="/A124276/b124276.txt">Table of n, a(n) for n = 1..1000</a>
%e A124276 A068563 begins 1, 2, 4, 6, 8, 12, 16, 18, 20, 24, 32, 36, 40, 42, ... .
%e A124276 Thus a(0) = 1, a(1) = 6, a(2) = 18, a(3) = 20, a(4) = 42 because 1/2, 3, 9, 10, 21 are not the terms of A068563.
%p A124276 a:= proc(n) option remember; local k;
%p A124276       for k from `if`(n=1, 1, a(n-1)+1)
%p A124276       while (2&^k mod k <> 4&^k mod k) or
%p A124276          (irem(k, 2, 'r')=0 and (2&^r mod r = 4&^r mod r))
%p A124276       do od; k
%p A124276     end:
%p A124276 seq(a(n), n=1..50);  # _Alois P. Heinz_, May 16 2013
%t A124276 Prepend[Select[Range[2, 2100], (PowerMod[2, #, #] == PowerMod[4, #, #]) && ! (PowerMod[2, #/2, #/2] == PowerMod[4, #/2, #/2]) &], 1]
%Y A124276 Cf. A068563.
%K A124276 nonn
%O A124276 1,2
%A A124276 _Alexander Adamchuk_, Oct 23 2006