OFFSET
1,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..1000
MATHEMATICA
ok[n_] := And @@ (#1[[2]] == 1 && Mod[#1[[1]], 8] == 1 & ) /@ FactorInteger[n]; Select[ Range[2000], ok] (* Jean-François Alcover, Mar 09 2012 *)
PROG
(Magma) [n: n in [1..2000] | forall{d: d in PrimeDivisors(n) | d mod 8 eq 1}]; // Vincenzo Librandi, Aug 20 2012
(PARI) is(n)=is(n%8!=1, return(0)); my(f=factor(n)[, 1]); for(i=1, #f~, if(f[i]%8!=1, return(0))); 1 \\ Charles R Greathouse IV, Jul 02 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
Offset changed from 0 to 1 by Vincenzo Librandi, Aug 20 2012
STATUS
approved